{"openapi":"3.1.0","info":{"title":"Tripadvisor API (Bowmark)","version":"e833508f87ff","description":"Travel data worldwide — find a city, hotel, restaurant or attraction by name; list and read hotels and restaurants with ratings, review counts, and booking prices.\n\nEvery function Bowmark has for Tripadvisor (tripadvisor.com) as one HTTP call. Each runs on Bowmark's infrastructure with the same billing, rules and response envelope as `POST /v1/run`. The whole API: https://api.bowmark.ai/openapi.json. Guide: https://bowmark.ai/docs/api.","contact":{"email":"support@bowmark.ai","url":"https://bowmark.ai/docs/api"}},"servers":[{"url":"https://api.bowmark.ai"}],"security":[{"bearer":[]},{"apiKeyHeader":[]}],"paths":{"/v1/sites/tripadvisor/search":{"post":{"operationId":"search","summary":"Finds places by query — a city or region, hotel, restaurant, attraction, tour or airline name — returning each match's id, type, name, parent place hierarchy and url.","description":"Finds places by query — a city or region, hotel, restaurant, attraction, tour or airline name — returning each match's id, type, name, parent place hierarchy and url. A city/region/country match has placeType \"CITY\", \"STATE\" or \"COUNTRY\" (never \"GEO\"); pick one of those three to get a geoId for searchHotels/searchRestaurants/searchAttractions/getDestination.\n\nCalls `bowmark.providers.tripadvisor.search`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<SearchResult>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/SearchArgs","description":"TypeScript: `SearchArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/searchHotels":{"post":{"operationId":"searchHotels","summary":"Lists the hotels in a city or region, in Tripadvisor's ranking, with each hotel's id, name, rating, review count, address, coordinates and 'from' price, paginated 30 at a time.","description":"Lists the hotels in a city or region, in Tripadvisor's ranking, with each hotel's id, name, rating, review count, address, coordinates and 'from' price, paginated 30 at a time.\n\nCalls `bowmark.providers.tripadvisor.searchHotels`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<SearchHotelsResult>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/SearchHotelsArgs","description":"TypeScript: `SearchHotelsArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getHotel":{"post":{"operationId":"getHotel","summary":"Reads one hotel in full: name, address, phone, star class, rating and sub-ratings, review count, amenities, room features, nearby places and headline price.","description":"Reads one hotel in full: name, address, phone, star class, rating and sub-ratings, review count, amenities, room features, nearby places and headline price.\n\nCalls `bowmark.providers.tripadvisor.getHotel`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<TripadvisorHotelDetail>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/GetHotelArgs","description":"TypeScript: `GetHotelArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getHotelPrices":{"post":{"operationId":"getHotelPrices","summary":"Reads the booking partners' live prices for one hotel for given check-in/check-out dates, each offer's partner name, nightly price, total and booking url.","description":"Reads the booking partners' live prices for one hotel for given check-in/check-out dates, each offer's partner name, nightly price, total and booking url.\n\nCalls `bowmark.providers.tripadvisor.getHotelPrices`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<TripadvisorHotelPrices>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/GetHotelPricesArgs","description":"TypeScript: `GetHotelPricesArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getRestaurant":{"post":{"operationId":"getRestaurant","summary":"Reads one restaurant in full: name, address, phone, cuisines, price range, opening hours, rating, review count and Tripadvisor rank — taking a restaurant id or url.","description":"Reads one restaurant in full: name, address, phone, cuisines, price range, opening hours, rating, review count and Tripadvisor rank — taking a restaurant id or url. Menu link and food/service/value/atmosphere sub-ratings are not yet extracted.\n\nCalls `bowmark.providers.tripadvisor.getRestaurant`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<TripadvisorRestaurantDetail>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/GetRestaurantArgs","description":"TypeScript: `GetRestaurantArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/searchRestaurants":{"post":{"operationId":"searchRestaurants","summary":"Lists the restaurants in a city or region in Tripadvisor's ranking, with id, name, rating, review count, cuisines, price level and url, paginated 30 at a time.","description":"Lists the restaurants in a city or region in Tripadvisor's ranking, with id, name, rating, review count, cuisines, price level and url, paginated 30 at a time.\n\nCalls `bowmark.providers.tripadvisor.searchRestaurants`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<SearchRestaurantsResult>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/SearchRestaurantsArgs","description":"TypeScript: `SearchRestaurantsArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getAttraction":{"post":{"operationId":"getAttraction","summary":"Reads one attraction in full: name, description, address, phone, website, opening hours, coordinates, rating, review count and Tripadvisor rank — taking an attraction id or url.","description":"Reads one attraction in full: name, description, address, phone, website, opening hours, coordinates, rating, review count and Tripadvisor rank — taking an attraction id or url. Suggested duration and the tours sold for it are not yet extracted.\n\nCalls `bowmark.providers.tripadvisor.getAttraction`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<TripadvisorAttractionDetail>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/GetAttractionArgs","description":"TypeScript: `GetAttractionArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/searchAttractions":{"post":{"operationId":"searchAttractions","summary":"Lists the top things to do, sights and attractions in a city or region in Tripadvisor's ranking — id, name, rank, rating, review count, categories, neighborhood, blurb and url — optionally filtered to","description":"Lists the top things to do, sights and attractions in a city or region in Tripadvisor's ranking — id, name, rank, rating, review count, categories, neighborhood, blurb and url — optionally filtered to one category (the c<id> in the site's own url), paginated 30 at a time.\n\nCalls `bowmark.providers.tripadvisor.searchAttractions`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<SearchAttractionsResult>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/SearchAttractionsArgs","description":"TypeScript: `SearchAttractionsArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getReviews":{"post":{"operationId":"getReviews","summary":"Reads one page of a hotel's, restaurant's or attraction's reviews in the site's own order — each review's id, rating, title, text, date of visit, trip type, date written, author handle, helpful votes ","description":"Reads one page of a hotel's, restaurant's or attraction's reviews in the site's own order — each review's id, rating, title, text, date of visit, trip type, date written, author handle, helpful votes and (hotels) sub-ratings — taking a listing url, or an id plus its type, and an offset to page (10 a page on hotels and attractions, 15 on restaurants).\n\nCalls `bowmark.providers.tripadvisor.getReviews`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<TripadvisorReviews>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"$ref":"#/components/schemas/GetReviewsArgs","description":"TypeScript: `GetReviewsArgs`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getDestination":{"post":{"operationId":"getDestination","summary":"Reads a city or region's overview page: its name, parent places, the site's review total, and the hotels, restaurants, attractions and tours it features, each with id, name, rating, review count and u","description":"Reads a city or region's overview page: its name, parent places, the site's review total, and the hotels, restaurants, attractions and tours it features, each with id, name, rating, review count and url — taking a geo id from search or a /Tourism-g<geoId>- url.\n\nCalls `bowmark.providers.tripadvisor.getDestination`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<TripadvisorDestination>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"type":"object","properties":{"geoId":{"type":"string"},"url":{"type":"string"}},"additionalProperties":true,"description":"TypeScript: `{ geoId?: string; url?: string }`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getReview":{"post":{"operationId":"getReview","summary":"Reads one review on its own page — rating, title, full text, date of visit, date written, author handle and name, the listing it is about, and the owner's response — taking a review url, or the review","description":"Reads one review on its own page — rating, title, full text, date of visit, date written, author handle and name, the listing it is about, and the owner's response — taking a review url, or the review id plus locationId and geoId from getReviews.\n\nCalls `bowmark.providers.tripadvisor.getReview`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<TripadvisorReviewDetail>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"type":"object","properties":{"url":{"type":"string"},"id":{"type":"string"},"locationId":{"type":"string"},"geoId":{"type":"string"}},"additionalProperties":true,"description":"TypeScript: `{ url?: string; id?: string; locationId?: string; geoId?: string }`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getQuestions":{"post":{"operationId":"getQuestions","summary":"Reads a listing's travellers' Q&A questions, newest first — each question's id, text, language, answer count, date and asker's member id — taking a location id, with offset and limit (up to 50) to pag","description":"Reads a listing's travellers' Q&A questions, newest first — each question's id, text, language, answer count, date and asker's member id — taking a location id, with offset and limit (up to 50) to page. The answers themselves are not yet extracted.\n\nCalls `bowmark.providers.tripadvisor.getQuestions`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<{ locationId: string; offset: number; questions: TripadvisorQuestion[]; hasMore: boolean }>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"type":"object","properties":{"locationId":{"type":"string"},"offset":{"type":"number"},"limit":{"type":"number"}},"required":["locationId"],"additionalProperties":true,"description":"TypeScript: `{ locationId: string; offset?: number; limit?: number }`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getPhotos":{"post":{"operationId":"getPhotos","summary":"Lists a listing's photos — the gallery's albums (all photos, traveller, dining, rooms…) with their photo counts, and the first page of photos with caption, a sized image url and a resizable url templa","description":"Lists a listing's photos — the gallery's albums (all photos, traveller, dining, rooms…) with their photo counts, and the first page of photos with caption, a sized image url and a resizable url template — taking a location id.\n\nCalls `bowmark.providers.tripadvisor.getPhotos`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<{ locationId: string; totalCount: number; albums: TripadvisorPhotoAlbum[]; photos: TripadvisorPhoto[] }>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"type":"object","properties":{"locationId":{"type":"string"}},"required":["locationId"],"additionalProperties":true,"description":"TypeScript: `{ locationId: string }`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}},"/v1/sites/tripadvisor/getNearby":{"post":{"operationId":"getNearby","summary":"Lists the hotels, restaurants or attractions near a listing — each with id, name, the page's rank, rating, review count, distance, address (hotels and attractions), a sponsored flag and url — taking k","description":"Lists the hotels, restaurants or attractions near a listing — each with id, name, the page's rank, rating, review count, distance, address (hotels and attractions), a sponsored flag and url — taking kind plus a listing url, or its locationId and geoId.\n\nCalls `bowmark.providers.tripadvisor.getNearby`. The body is the function's arguments, keyed by parameter name. `result` in the response is what it returns: `Promise<{ locationId: string; geoId: string; kind: string; listings: TripadvisorNearbyListing[]; url: string }>`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"args":{"type":"object","properties":{"kind":{"anyOf":[{"const":"hotels"},{"const":"restaurants"},{"const":"attractions"}]},"url":{"type":"string"},"locationId":{"type":"string"},"geoId":{"type":"string"}},"required":["kind"],"additionalProperties":true,"description":"TypeScript: `{ kind: \"hotels\" | \"restaurants\" | \"attractions\"; url?: string; locationId?: string; geoId?: string }`"}},"required":["args"],"additionalProperties":false}}}},"responses":{"200":{"description":"The call ran. That includes a call that failed (`status: error`) or paused for a sign-in (`status: needs_user`), so branch on `status`.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RunEnvelope"},{"type":"object","properties":{"result":{}}}]}}}},"400":{"description":"The body was malformed. `error` says what to send.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"401":{"description":"No API key, or a key that was refused.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"402":{"description":"The account is out of free usage, at its spend cap, or its card was declined. Fix billing at https://bowmark.ai/dashboard/billing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}},"404":{"$ref":"#/components/responses/NotFound"},"429":{"description":"Too many runs in flight on this account. Nothing was started or charged.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."}}},"503":{"description":"A failure on Bowmark's side. Retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}}}}},"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Your Bowmark API key."},"apiKeyHeader":{"type":"apiKey","in":"header","name":"X-Bowmark-Key"}},"responses":{"NotFound":{"description":"No such site or function.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunEnvelope"}}}}},"schemas":{"RunEnvelope":{"type":"object","description":"What a run returns. `status` says whether the SCRIPT succeeded. A script that threw or paused for a login is still HTTP 200. Branch on `status`, not on the HTTP code.","required":["ok","status","result","logs","error","ms"],"properties":{"runId":{"type":"string","description":"Stable id for this run. Quote it in a support or `report` message."},"ok":{"type":"boolean","description":"False only when the run produced nothing usable."},"status":{"type":"string","enum":["ok","error","partial","needs_user"],"description":"`partial`: the result is real but some calls failed (see `incomplete`); `ok` stays true. `needs_user`: a person must sign in to a site first. Relay `meta.handoff.url` to them, then run again."},"egress":{"type":"string","enum":["default","link"],"description":"The egress the run was given, present only when the request asked for one. `link`: every request went through the caller's own Chrome (Bowmark Buddy)."},"result":{"description":"Whatever the script `return`ed. Any JSON value."},"logs":{"type":"array","items":{"type":"string"},"description":"Lines the script wrote with `log(...)`."},"error":{"type":["string","null"],"description":"Why the run failed, in plain words. Null on success."},"ms":{"type":"integer","description":"How long the script itself ran, in milliseconds."},"queuedMs":{"type":"integer","description":"How long the run waited for a worker before starting. Present only when it was a second or more."},"needs":{"type":"array","description":"The sign-ins this script is waiting on. Present when `status` is `needs_user`.","items":{"type":"object","required":["capability","provider","providerTitle","kind"],"properties":{"capability":{"type":"string"},"provider":{"type":"string"},"providerTitle":{"type":"string","description":"The site's name, to show a person."},"kind":{"type":"string"}}}},"incomplete":{"type":"object","description":"Present only when `status` is `partial`: which calls did not answer.","properties":{"summary":{"type":"string"},"totalCalls":{"type":"integer"}},"additionalProperties":true},"emptyHanded":{"type":"object","description":"Present when the script returned nothing while its calls returned rows, usually a filter that matched none of the site's own labels. Lists the label values the calls actually returned.","additionalProperties":true},"notes":{"type":"array","description":"Caveats a call attached to a complete answer. Never changes `status`.","items":{"type":"object","properties":{"path":{"type":"string"},"notes":{"type":"array","items":{"type":"string"}}}}},"meta":{"type":"object","properties":{"handoff":{"type":"object","description":"A single-use sign-in link for a person to open. Expires at `expiresAt`.","properties":{"ref":{"type":"string"},"url":{"type":"string","format":"uri"},"expiresAt":{"type":"string","format":"date-time"}}},"concurrency":{"type":"object","description":"On a 429: how many runs are in flight and when to retry.","properties":{"limit":{"type":"integer"},"inFlight":{"type":"integer"},"retryAfterSeconds":{"type":"integer"}}}},"additionalProperties":true},"notice":{"type":"object","description":"Set when the account owner has not accepted the current Terms. Relay it to them.","additionalProperties":true}}},"GetAttractionArgs":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string"}},"additionalProperties":true},"GetHotelArgs":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string"}},"additionalProperties":true},"GetHotelPricesArgs":{"type":"object","properties":{"hotelId":{"type":"string"},"checkIn":{"type":"string"},"checkOut":{"type":"string"},"guests":{"type":"number"},"rooms":{"type":"number"}},"required":["hotelId","checkIn","checkOut"],"additionalProperties":true},"GetRestaurantArgs":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string"}},"additionalProperties":true},"GetReviewsArgs":{"type":"object","properties":{"id":{"type":"string"},"type":{"anyOf":[{"const":"hotel"},{"const":"restaurant"},{"const":"attraction"}]},"url":{"type":"string"},"offset":{"type":"number"}},"additionalProperties":true},"SearchArgs":{"type":"object","properties":{"query":{"type":"string"}},"required":["query"],"additionalProperties":true},"SearchAttractionsArgs":{"type":"object","properties":{"geoId":{"type":"string"},"categoryId":{"type":"string"},"offset":{"type":"number"}},"required":["geoId"],"additionalProperties":true},"SearchHotelsArgs":{"type":"object","properties":{"geoId":{"type":"string"},"offset":{"type":"number"}},"required":["geoId"],"additionalProperties":true},"SearchRestaurantsArgs":{"type":"object","properties":{"geoId":{"type":"string"},"offset":{"type":"number"}},"required":["geoId"],"additionalProperties":true}}}}