1 credit per call20 endpoints27 datapointsChecked working 6 Dec 2026
Trip.com API
Trip.com API for hotels, rooms, reviews, flights, trains, buses, car rental, cruises, packages and attractions as JSON, from 1 credit per call.
{
"success": true,
"data": {
"city_id": "192",
"check_in": "2027-03-14",
"check_out": "2027-03-16",
"adults": 2,
"currency": "USD",
"locale": "en",
"sort": "popularity",
"page": 1,
"total": 2413,
"count": 12,
"hotels": [
{
"position": 1,
"hotel_id": "718146",
"name": "Hotel Régence Etoile",
"name_en": "Hotel Régence Etoile",
"category": "Hotel",
"stars": 4,
"guest_score": 9.2,
"guest_score_label": "Great",
"review_count": 564,
"city": "Paris",
"city_id": "192",
"address": "Champs Elysées",
"zone": "Champs Elysées",
"location_hint": "Near Arc de Triomphe de l’Etoile | Charles de Gaulle - étoile Metro Station",
"latitude": 48.876537,
"longitude": 2.292983,
"price_per_night": 221,
"original_price_per_night": 367,
"total_price": 524.39,
"currency": "USD",
"nights": 2,
"room_name": "Classic Room",
"bed": "1 queen bed",
"free_cancellation": true,
"is_ad": false,
"images": [
"https://ak-d.tripcdn.com/images/0582t12000jbiuxe0A6C0_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/200v11000000rkn07BFC6_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc3s12000dtpdp508E3C_R_600_600_R5_D.jpg_.webp"
],
"url": "https://www.trip.com/hotels/detail/?hotelId=718146"
},
{
"position": 2,
"hotel_id": "730417",
"name": "Hotel des Comédies",
"name_en": "Hotel des Comédies",
"category": "Hotel",
"stars": 4,
"guest_score": 9.2,
"guest_score_label": "Great",
"review_count": 130,
"city": "Paris",
"city_id": "192",
"zone": "Near Palais Garnier|Le Marais",
"location_hint": "Near Palais Garnier | Le Marais",
"latitude": 48.871065,
"longitude": 2.34991,
"price_per_night": 98,
"original_price_per_night": 156,
"total_price": 253.94,
"currency": "USD",
"nights": 2,
"room_name": "Standard Double Room",
"bed": "1 queen bed or 2 single beds",
"free_cancellation": false,
"is_ad": false,
"images": [
"https://ak-d.tripcdn.com/images/1mc1g12000u940tbi281D_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc3l12000u94061pE573_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc3i12000u93zg02CF6E_R_600_600_R5_D.jpg_.webp"
],
"url": "https://www.trip.com/hotels/detail/?hotelId=730417"
},
{
"position": 3,
"hotel_id": "717730",
"name": "Norman Paris Hôtel & Spa",
"name_en": "Norman Paris Hôtel & Spa",
"category": "Hotel",
"stars": 5,
"guest_score": 9.3,
"guest_score_label": "Great",
"review_count": 55,
"city": "Paris",
"city_id": "192",
"address": "Champs Elysées",
"zone": "Champs Elysées",
"location_hint": "Champs Elysées | Near Arc de Triomphe de l’Etoile",
"latitude": 48.873745,
"longitude": 2.300357,
"price_per_night": 373,
"original_price_per_night": 410,
"total_price": 798.04,
"currency": "USD",
"nights": 2,
"room_name": "Cozy Room",
"bed": "1 queen bed",
"free_cancellation": false,
"is_ad": false,
"images": [
"https://ak-d.tripcdn.com/images/1mc5d12000dpe7bqtEEDB_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc5612000cfah2ml7B51_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc6912000c4abom9EC13_R_600_600_R5_D.jpg_.webp"
],
"url": "https://www.trip.com/hotels/detail/?hotelId=717730"
}
]
},
"meta": {
"endpoint_family": "hotel_search",
"request_id": "req_c053a719c0d3413799df9eff810fba17",
"credits_charged": 1,
"credits_remaining": 1793
}
}Sample data
What one call returns
A recorded run of hotels-search: the fields and shapes you will get, shortened to 3 items.
| # | positioninteger | hotel_idstring | namestring | name_enstring | categorystring | starsinteger | guest_scorenumber | guest_score_labelstring | review_countinteger | citystring | city_idstring | addressstring | zonestring | location_hintstring | latitudenumber | longitudenumber | price_per_nightinteger | original_price_per_nightinteger | total_pricenumber | currencystring | nightsinteger | room_namestring | bedstring | free_cancellationboolean | is_adboolean | imagesstring[] | urlurl |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 1 | 718146 | Hotel Régence Etoile | Hotel Régence Etoile | Hotel | 4 | 9.2 | Great | 564 | Paris | 192 | Champs Elysées | Champs Elysées | Near Arc de Triomphe de l’Etoile | Charles de Gaulle - étoile Metro Station | 48.876537 | 2.292983 | 221 | 367 | 524.39 | USD | 2 | Classic Room | 1 queen bed | true | false | [3 items] | https://www.trip.com/hotels/detail/?hotelId=718146 |
| 2 | 2 | 730417 | Hotel des Comédies | Hotel des Comédies | Hotel | 4 | 9.2 | Great | 130 | Paris | 192 | — | Near Palais Garnier|Le Marais | Near Palais Garnier | Le Marais | 48.871065 | 2.34991 | 98 | 156 | 253.94 | USD | 2 | Standard Double Room | 1 queen bed or 2 single beds | false | false | [3 items] | https://www.trip.com/hotels/detail/?hotelId=730417 |
| 3 | 3 | 717730 | Norman Paris Hôtel & Spa | Norman Paris Hôtel & Spa | Hotel | 5 | 9.3 | Great | 55 | Paris | 192 | Champs Elysées | Champs Elysées | Champs Elysées | Near Arc de Triomphe de l’Etoile | 48.873745 | 2.300357 | 373 | 410 | 798.04 | USD | 2 | Cozy Room | 1 queen bed | false | false | [3 items] | https://www.trip.com/hotels/detail/?hotelId=717730 |
[
{
"position": 1,
"hotel_id": "718146",
"name": "Hotel Régence Etoile",
"name_en": "Hotel Régence Etoile",
"category": "Hotel",
"stars": 4,
"guest_score": 9.2,
"guest_score_label": "Great",
"review_count": 564,
"city": "Paris",
"city_id": "192",
"address": "Champs Elysées",
"zone": "Champs Elysées",
"location_hint": "Near Arc de Triomphe de l’Etoile | Charles de Gaulle - étoile Metro Station",
"latitude": 48.876537,
"longitude": 2.292983,
"price_per_night": 221,
"original_price_per_night": 367,
"total_price": 524.39,
"currency": "USD",
"nights": 2,
"room_name": "Classic Room",
"bed": "1 queen bed",
"free_cancellation": true,
"is_ad": false,
"images": [
"https://ak-d.tripcdn.com/images/0582t12000jbiuxe0A6C0_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/200v11000000rkn07BFC6_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc3s12000dtpdp508E3C_R_600_600_R5_D.jpg_.webp"
],
"url": "https://www.trip.com/hotels/detail/?hotelId=718146"
},
{
"position": 2,
"hotel_id": "730417",
"name": "Hotel des Comédies",
"name_en": "Hotel des Comédies",
"category": "Hotel",
"stars": 4,
"guest_score": 9.2,
"guest_score_label": "Great",
"review_count": 130,
"city": "Paris",
"city_id": "192",
"zone": "Near Palais Garnier|Le Marais",
"location_hint": "Near Palais Garnier | Le Marais",
"latitude": 48.871065,
"longitude": 2.34991,
"price_per_night": 98,
"original_price_per_night": 156,
"total_price": 253.94,
"currency": "USD",
"nights": 2,
"room_name": "Standard Double Room",
"bed": "1 queen bed or 2 single beds",
"free_cancellation": false,
"is_ad": false,
"images": [
"https://ak-d.tripcdn.com/images/1mc1g12000u940tbi281D_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc3l12000u94061pE573_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc3i12000u93zg02CF6E_R_600_600_R5_D.jpg_.webp"
],
"url": "https://www.trip.com/hotels/detail/?hotelId=730417"
},
{
"position": 3,
"hotel_id": "717730",
"name": "Norman Paris Hôtel & Spa",
"name_en": "Norman Paris Hôtel & Spa",
"category": "Hotel",
"stars": 5,
"guest_score": 9.3,
"guest_score_label": "Great",
"review_count": 55,
"city": "Paris",
"city_id": "192",
"address": "Champs Elysées",
"zone": "Champs Elysées",
"location_hint": "Champs Elysées | Near Arc de Triomphe de l’Etoile",
"latitude": 48.873745,
"longitude": 2.300357,
"price_per_night": 373,
"original_price_per_night": 410,
"total_price": 798.04,
"currency": "USD",
"nights": 2,
"room_name": "Cozy Room",
"bed": "1 queen bed",
"free_cancellation": false,
"is_ad": false,
"images": [
"https://ak-d.tripcdn.com/images/1mc5d12000dpe7bqtEEDB_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc5612000cfah2ml7B51_R_600_600_R5_D.jpg_.webp",
"https://ak-d.tripcdn.com/images/1mc6912000c4abom9EC13_R_600_600_R5_D.jpg_.webp"
],
"url": "https://www.trip.com/hotels/detail/?hotelId=717730"
}
]position,hotel_id,name,name_en,category,stars,guest_score,guest_score_label,review_count,city,city_id,address,zone,location_hint,latitude,longitude,price_per_night,original_price_per_night,total_price,currency,nights,room_name,bed,free_cancellation,is_ad,images,url 1,718146,Hotel Régence Etoile,Hotel Régence Etoile,Hotel,4,9.2,Great,564,Paris,192,Champs Elysées,Champs Elysées,Near Arc de Triomphe de l’Etoile | Charles de Gaulle - étoile Metro Station,48.876537,2.292983,221,367,524.39,USD,2,Classic Room,1 queen bed,true,false,"[""https://ak-d.tripcdn.com/images/0582t12000jbiuxe0A6C0_R_600_600_R5_D.jpg_.webp"",""https://ak-d.tripcdn.com/images/200v11000000rkn07BFC6_R_600_600_R5_D.jpg_.webp"",""https://ak-d.tripcdn.com/images/1mc3s12000dtpdp508E3C_R_600_600_R5_D.jpg_.webp""]",https://www.trip.com/hotels/detail/?hotelId=718146 2,730417,Hotel des Comédies,Hotel des Comédies,Hotel,4,9.2,Great,130,Paris,192,,Near Palais Garnier|Le Marais,Near Palais Garnier | Le Marais,48.871065,2.34991,98,156,253.94,USD,2,Standard Double Room,1 queen bed or 2 single beds,false,false,"[""https://ak-d.tripcdn.com/images/1mc1g12000u940tbi281D_R_600_600_R5_D.jpg_.webp"",""https://ak-d.tripcdn.com/images/1mc3l12000u94061pE573_R_600_600_R5_D.jpg_.webp"",""https://ak-d.tripcdn.com/images/1mc3i12000u93zg02CF6E_R_600_600_R5_D.jpg_.webp""]",https://www.trip.com/hotels/detail/?hotelId=730417 3,717730,Norman Paris Hôtel & Spa,Norman Paris Hôtel & Spa,Hotel,5,9.3,Great,55,Paris,192,Champs Elysées,Champs Elysées,Champs Elysées | Near Arc de Triomphe de l’Etoile,48.873745,2.300357,373,410,798.04,USD,2,Cozy Room,1 queen bed,false,false,"[""https://ak-d.tripcdn.com/images/1mc5d12000dpe7bqtEEDB_R_600_600_R5_D.jpg_.webp"",""https://ak-d.tripcdn.com/images/1mc5612000cfah2ml7B51_R_600_600_R5_D.jpg_.webp"",""https://ak-d.tripcdn.com/images/1mc6912000c4abom9EC13_R_600_600_R5_D.jpg_.webp""]",https://www.trip.com/hotels/detail/?hotelId=717730
Recorded from our API · 3 items shown · 27 datapoints per itemGET /v1/trip-com/hotels-search?city_id=192&check_in=2027-03-14&check_out=2027-03-16&adults=2&stars[]=4&stars[]=5¤cy=USD
27 datapoints
Identity
- hotel_idstring
- namestring
- name_enstring
- categorystring
- room_namestring
Contact
- urlurl
Location
- citystring
- city_idstring
- addressstring
- location_hintstring
- latitudenumber
- longitudenumber
- free_cancellationboolean
Reputation
- starsinteger
- guest_scorenumber
- guest_score_labelstring
- review_countinteger
- imagesstring[]
Price
- price_per_nightinteger
- original_price_per_nightinteger
- total_pricenumber
- currencystring
Other
- positioninteger
- zonestring
- nightsinteger
- bedstring
- is_adboolean
Playground
Run this API
curl "https://api.perceptlayer.com/v1/trip-com/hotels-search?city_id=192&check_in=2027-03-14&check_out=2027-03-16&adults=2&stars[]=4&stars[]=5¤cy=USD" \
-H "X-API-Key: $API_KEY"Trip.com · 20 endpoints
Endpoints
Every endpoint takes the same key. Open one for its parameters, the fields it returns and an example request.
| Endpoint | Required parameters | Returns | Cost |
|---|---|---|---|
GET/v1/trip-com/attractions-detail | none+4 optional | JSON | 1 credit |
GET/v1/trip-com/attractions-reviews | id+3 optional | JSON | 1 credit |
GET/v1/trip-com/attractions-search | query+4 optional | JSON | 1 credit |
GET/v1/trip-com/buses-search | fromtodate+2 optional | JSON | 1 credit |
GET/v1/trip-com/cars-locations | query+1 optional | JSON | 1 credit |
GET/v1/trip-com/cars-search | pickup_locationpickup_city_idpickup_location_namepickup_latitudepickup_longitudepickup_datetimedropoff_datetime+14 optional | JSON | 10 credits |
GET/v1/trip-com/cruises-detail | id+3 optional | JSON | 1 credit |
GET/v1/trip-com/cruises-search | none+8 optional | JSON | 1 credit |
GET/v1/trip-com/flights-calendar | fromtodate+2 optional | JSON | 1 credit |
GET/v1/trip-com/flights-search | fromtodate+5 optional | JSON | 1–3 credits |
GET/v1/trip-com/hotels-detail | none+3 optional | JSON | 1 credit |
GET/v1/trip-com/hotels-filters | city_idcheck_incheck_out+2 optional | JSON | 1 credit |
GET/v1/trip-com/hotels-reviews | hotel_id+3 optional | JSON | 1 credit |
GET/v1/trip-com/hotels-rooms | hotel_idcheck_incheck_out+4 optional | JSON | 10 credits |
GET/v1/trip-com/hotels-search | city_idcheck_incheck_out+14 optional | city_idcheck_incheck_outadultscurrencylocale+1 more | 1–18 credits |
GET/v1/trip-com/packages-search | fromtocity_iddatereturn_date+3 optional | JSON | 3 credits |
GET/v1/trip-com/suggest | query+2 optional | JSON | 1 credit |
GET/v1/trip-com/trains-calendar | fromtodate+2 optional | JSON | 1 credit |
GET/v1/trip-com/trains-search | fromtodate+3 optional | JSON | 3 credits |
GET/v1/trip-com/trains-stations | none+3 optional | JSON | 1 credit |
Overview
About the Trip.com API
What you can get
The Trip.com API returns Trip.com travel data as JSON through 20 endpoints. Most take a currency (USD, EUR, GBP, JPY or KRW) and a locale (en, en-gb, de, fr, ja, ko or zh-hk).
- Hotels:
hotels-searchtakes acity_id,check_inandcheck_out, withadults,children_ages[],rooms,page,pages,guest_score_min,free_cancellation,breakfast,stars[],min_price,max_priceandsort(popularity, price_asc, price_desc, top_reviewed, stars or distance).hotels-filterstakes the samecity_id,check_inandcheck_out.hotels-detailtakes ahotel_idor aurl;hotels-reviewstakes ahotel_id, withpage,page_sizeandsort(relevant, recent, rating_desc or rating_asc);hotels-roomstakes ahotel_id,check_inandcheck_out, withadultsandchildren_ages. - Flights:
flights-searchtakesfrom,toanddate, withreturn_date,adults,cabin_class(economy, premium_economy or business) andpolicy_id.flights-calendartakesfrom,toanddate, withreturn_date. - Packages:
packages-searchtakesfrom,to,city_id,dateandreturn_date, withadultsandpage. - Trains and buses:
trains-stationstakes aquery, withcountryandmode(search or recommend).trains-searchtakesfrom,toanddate, withadults;trains-calendartakesfrom,toanddate.buses-searchtakesfrom,toanddate. - Car rental:
cars-locationstakes aquery.cars-searchtakes apickup_location,pickup_city_id,pickup_location_name,pickup_latitude,pickup_longitude,pickup_datetimeanddropoff_datetime, with the matching dropoff fields,driver_age,page,page_size,car_class,supplier,transmission(automatic or manual) andfree_cancellation. - Cruises:
cruises-searchtakes adestination, withmonth,start_date,end_date,pageandsort(recommended, sales, reviews, price_asc or price_desc);cruises-detailtakes anid, withdeparture_date. - Attractions:
attractions-searchtakes aquery, withpageandsort(recommended, price_asc or price_desc);attractions-detailtakes anidor aurl;attractions-reviewstakes anid, withpageandpage_size. - Suggest:
suggesttakes aquery, withtype(all, city, hotel or airport).
The recorded hotels-search for city_id 192 (Paris), 14 to 16 March 2027, 2 adults, 4 and 5 stars, in USD returns total (2413 in that recording), count, page, sort and hotels, each with position, hotel_id, name, stars, guest_score, guest_score_label, review_count, zone, latitude, longitude, price_per_night, original_price_per_night, total_price, nights, room_name, bed, free_cancellation, is_ad, images and url.
How a call works
Search a city, then look up a hotel: GET /v1/trip-com/hotels-search?city_id=192&check_in=2027-03-14&check_out=2027-03-16&adults=2¤cy=USD with your key in the X-API-Key header. Each hotel carries a hotel_id, which hotels-detail, hotels-reviews and hotels-rooms take. Most calls cost 1 credit. hotels-search costs 1 credit for the first page in the default order, and 3 credits per page from page 2, for each page read with pages, or with guest_score_min, free_cancellation, breakfast or another sort, up to 18. flights-search costs 1 credit one way and 3 with return_date. trains-search and packages-search cost 3, and hotels-rooms and cars-search cost 10. Failed calls cost nothing.
More travel APIs
Use cases
Track nightly hotel prices and discounts for a city and date range
Use the Trip.com API to track nightly hotel prices and discounts for a city and date rangeCompare room rates for a hotel across dates with `hotels-rooms`
Use the Trip.com API to compare room rates for a hotel across dates with `hotels-rooms`Find the cheapest travel dates with `flights-calendar` and `trains-calendar`
Use the Trip.com API to find the cheapest travel dates with `flights-calendar` and `trains-calendar`Compare flight, train and bus options on the same route
Use the Trip.com API to compare flight, train and bus options on the same routeFAQ
Questions
How much does the Trip.com API cost?
Most calls cost one credit. `hotels-search` costs 1 credit for the first page in the default order and 3 per page after that, or with `pages`, filters such as `guest_score_min`, `free_cancellation` and `breakfast`, or another sort, up to 18. `flights-search` costs 1 credit one way and 3 with `return_date`; `trains-search` and `packages-search` cost 3; `hotels-rooms` and `cars-search` cost 10. Failed calls cost nothing. New accounts get free credits to start, and credit packs bring the price down as you scale.
Can I filter hotels by stars, price or guest score?
Yes. `hotels-search` takes `stars[]`, `min_price`, `max_price`, `guest_score_min`, `free_cancellation` and `breakfast`. Filtering by stars or price keeps the first page at 1 credit; the other three filters cost 3 credits per page.
What format are responses in?
Every endpoint returns JSON, with no HTML parsing on your side.
Do I need a Trip.com account?
No. You call this Trip.com API with your Perceptlayer key in the `X-API-Key` header, with no Trip.com login.
Is this the official Trip.com API?
No. Perceptlayer is an independent service and is not affiliated with Trip.com. It returns Trip.com data as JSON with a Perceptlayer key, so there is no Trip.com developer account, app review or partner approval to get first. It only reads data: if Trip.com has an official API and you need to act on your own Trip.com account, such as posting, managing orders or reading private data, use that one.
Should I build a Trip.com scraper instead?
You can, but a Trip.com scraper is code you maintain: page changes break it, requests get blocked, and Trip.com's terms govern how you collect data. The Trip.com API gives you 20 endpoints of named JSON fields for 1 credit per successful call, and failed calls cost nothing. A scraper makes sense only for data these endpoints don't return, so check the response in the playground on this page first.
Try the Trip.com API with 100 free credits
No credit card. Failed calls are never billed.