repull 0.2.17 → 0.2.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/repull/api/airbnb_api.rb +4 -4
- data/lib/repull/api/booking_com_api.rb +113 -17
- data/lib/repull/api/health_api.rb +0 -57
- data/lib/repull/api/migrate_api.rb +552 -0
- data/lib/repull/api/reservations_api.rb +2 -2
- data/lib/repull/models/airbnb_permits_response.rb +1 -1
- data/lib/repull/models/airbnb_permits_write_request.rb +1 -1
- data/lib/repull/models/airbnb_permits_write_request_permits_inner.rb +43 -4
- data/lib/repull/models/{airbnb_permits_write_request_permits_inner_answers_inner.rb → airbnb_permits_write_request_permits_inner_answers_value.rb} +22 -34
- data/lib/repull/models/check_migration_cutover200_response.rb +147 -0
- data/lib/repull/models/check_migration_cutover_request.rb +175 -0
- data/lib/repull/models/check_migration_cutover_request_reservations_inner.rb +216 -0
- data/lib/repull/models/connect_provider.rb +18 -5
- data/lib/repull/models/connect_session.rb +25 -5
- data/lib/repull/models/create_connect_session_request.rb +81 -5
- data/lib/repull/models/create_connect_session_request_copy.rb +251 -0
- data/lib/repull/models/create_connect_session_request_workspace.rb +196 -0
- data/lib/repull/models/delete_migration200_response.rb +147 -0
- data/lib/repull/models/delete_migration200_response_data.rb +165 -0
- data/lib/repull/models/get_migration200_response.rb +147 -0
- data/lib/repull/models/get_migration_channel_map200_response.rb +147 -0
- data/lib/repull/models/get_migration_report200_response.rb +147 -0
- data/lib/repull/models/list_migrations200_response.rb +158 -0
- data/lib/repull/models/listing_content_update_request.rb +36 -1
- data/lib/repull/models/listing_content_update_request_checkout_tasks_inner.rb +210 -0
- data/lib/repull/models/listing_content_update_request_pricing.rb +283 -0
- data/lib/repull/models/listing_content_update_request_rooms_inner.rb +225 -0
- data/lib/repull/models/listing_content_update_request_rooms_inner_beds_inner.rb +209 -0
- data/lib/repull/models/listing_content_update_response.rb +1 -1
- data/lib/repull/models/listing_create_request.rb +24 -1
- data/lib/repull/models/listing_create_response.rb +14 -4
- data/lib/repull/models/map_booking_room_request.rb +201 -0
- data/lib/repull/models/map_booking_room_response.rb +315 -0
- data/lib/repull/models/migration.rb +303 -0
- data/lib/repull/models/migration_channel_map.rb +169 -0
- data/lib/repull/models/migration_channel_map_listings_inner.rb +208 -0
- data/lib/repull/models/migration_channel_map_listings_inner_airbnb.rb +156 -0
- data/lib/repull/models/migration_channel_map_listings_inner_booking.rb +156 -0
- data/lib/repull/models/migration_channel_map_sources_inner.rb +167 -0
- data/lib/repull/models/migration_completed_event.rb +309 -0
- data/lib/repull/models/migration_connections_inner.rb +195 -0
- data/lib/repull/models/migration_counts.rb +183 -0
- data/lib/repull/models/migration_cutover_check.rb +200 -0
- data/lib/repull/models/migration_cutover_check_mismatched_inner.rb +156 -0
- data/lib/repull/models/migration_failed_event.rb +309 -0
- data/lib/repull/models/migration_import_payload.rb +225 -0
- data/lib/repull/models/migration_import_payload_results_inner.rb +165 -0
- data/lib/repull/models/migration_import_run.rb +202 -0
- data/lib/repull/models/migration_import_run_results_inner.rb +165 -0
- data/lib/repull/models/migration_report.rb +179 -0
- data/lib/repull/models/migration_report_issues_inner.rb +229 -0
- data/lib/repull/models/migration_reservation_ref.rb +184 -0
- data/lib/repull/models/reservation.rb +12 -2
- data/lib/repull/models/run_migration_import202_response.rb +147 -0
- data/lib/repull/models/run_migration_import202_response_data.rb +158 -0
- data/lib/repull/models/run_migration_import202_response_data_queued_inner.rb +174 -0
- data/lib/repull/models/run_migration_import_request.rb +182 -0
- data/lib/repull/models/update_booking_content_request.rb +359 -0
- data/lib/repull/models/update_booking_content_request_content_data_inner.rb +156 -0
- data/lib/repull/models/update_booking_content_request_photos_inner.rb +164 -0
- data/lib/repull/models/webhook_event.rb +4 -0
- data/lib/repull/models/webhook_event_type.rb +3 -1
- data/lib/repull/version.rb +1 -1
- data/lib/repull.rb +45 -1
- data/openapi/v1.json +3855 -2272
- metadata +47 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 15403dd52cdecbf29d07692c41b91b6b3b52f305b42217c3efd4921bd2aaf739
|
|
4
|
+
data.tar.gz: 3d7f250db469714186c929035e61717ef62e4c53d8b5979f7a05141c135bc6ef
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 51b184c8b51787aa6696489f016a8aa01f96e212f4b64530b9717b3f32f5506652240d631d19ba6ad308c92eab7ca3d38d8a9329b94a554b1041b3f7fefb8e58
|
|
7
|
+
data.tar.gz: dc48f72c12261d1fbf453fd674a39d8f985f46bf9ab0d2b3757056987b4012195cd4d68a8db1d3c3aa56c421dd71ee0f0a2509e573192f6fd60d6e1bf5a7a55e
|
|
@@ -1918,7 +1918,7 @@ module Repull
|
|
|
1918
1918
|
end
|
|
1919
1919
|
|
|
1920
1920
|
# List Airbnb permits and licences
|
|
1921
|
-
# The regulatory permits, licences and registration numbers attached to an Airbnb listing. **DB-only by default.** `?source=cache` (the default) returns the permits as last mirrored by the sync worker — regulatory body, regulation type, status, permit number — with no upstream call. **`?source=live` also returns the QUESTIONS.** The mirror stores the RESULT of a permit, not what Airbnb asks for it, so a caller that is about to write needs `?source=live` once: it returns each permit
|
|
1921
|
+
# The regulatory permits, licences and registration numbers attached to an Airbnb listing. **DB-only by default.** `?source=cache` (the default) returns the permits as last mirrored by the sync worker — regulatory body, regulation type, status, permit number — with no upstream call. **`?source=live` also returns the QUESTIONS.** The mirror stores the RESULT of a permit, not what Airbnb asks for it, so a caller that is about to write needs `?source=live` once: it returns each permit's `flows[]` with the `answer_key`, `type` and `choices` of every question, and the answers already on file. Airbnb refuses an `answer_key` it did not ask for on this listing, so this is not optional guesswork you can skip. Returns `404` when the listing has no Airbnb connection in this workspace, and `403 listing_inactive` when the listing is inactive.
|
|
1922
1922
|
# @param id [String] Repull listing id (numeric string).
|
|
1923
1923
|
# @param [Hash] opts the optional parameters
|
|
1924
1924
|
# @option opts [String] :source `cache` (default) reads the local mirror only. `live` additionally asks Airbnb for the permit questions. (default to 'cache')
|
|
@@ -1929,7 +1929,7 @@ module Repull
|
|
|
1929
1929
|
end
|
|
1930
1930
|
|
|
1931
1931
|
# List Airbnb permits and licences
|
|
1932
|
-
# The regulatory permits, licences and registration numbers attached to an Airbnb listing. **DB-only by default.** `?source=cache` (the default) returns the permits as last mirrored by the sync worker — regulatory body, regulation type, status, permit number — with no upstream call. **`?source=live` also returns the QUESTIONS.** The mirror stores the RESULT of a permit, not what Airbnb asks for it, so a caller that is about to write needs `?source=live` once: it returns each permit
|
|
1932
|
+
# The regulatory permits, licences and registration numbers attached to an Airbnb listing. **DB-only by default.** `?source=cache` (the default) returns the permits as last mirrored by the sync worker — regulatory body, regulation type, status, permit number — with no upstream call. **`?source=live` also returns the QUESTIONS.** The mirror stores the RESULT of a permit, not what Airbnb asks for it, so a caller that is about to write needs `?source=live` once: it returns each permit's `flows[]` with the `answer_key`, `type` and `choices` of every question, and the answers already on file. Airbnb refuses an `answer_key` it did not ask for on this listing, so this is not optional guesswork you can skip. Returns `404` when the listing has no Airbnb connection in this workspace, and `403 listing_inactive` when the listing is inactive.
|
|
1933
1933
|
# @param id [String] Repull listing id (numeric string).
|
|
1934
1934
|
# @param [Hash] opts the optional parameters
|
|
1935
1935
|
# @option opts [String] :source `cache` (default) reads the local mirror only. `live` additionally asks Airbnb for the permit questions. (default to 'cache')
|
|
@@ -3528,7 +3528,7 @@ module Repull
|
|
|
3528
3528
|
end
|
|
3529
3529
|
|
|
3530
3530
|
# Answer Airbnb permit questions
|
|
3531
|
-
# Answer the regulatory permit questions for a listing — the licence or registration number a city requires to keep the listing up. Read the questions first with `GET …/permits?source=live
|
|
3531
|
+
# Answer the regulatory permit questions for a listing — the licence or registration number a city requires to keep the listing up. Read the questions first with `GET …/permits?source=live`. For each permit, pick one of its `flows[]` and send its `slug` as `flow_slug`; key every answer by the question's `answer_key`, and let the question's `type` decide the value field (`text_value`, `attestation_value`, `radio_value`, `date_value` or `selected_options_value`). Answers are forwarded verbatim — nothing is defaulted or inferred, because a wrong licence number can take a listing down in a regulated city. Send `Idempotency-Key`: a timeout here leaves you unable to tell \"never arrived\" from \"arrived, response lost\", and this is a compliance filing. Airbnb refusing the answers (an unknown `answer_key`, a malformed licence number) is `422 airbnb_rejected` carrying Airbnb's own reason. An expired or revoked Airbnb connection is `403 connection_reauth_required`.
|
|
3532
3532
|
# @param id [String] Repull listing id (numeric string).
|
|
3533
3533
|
# @param airbnb_permits_write_request [AirbnbPermitsWriteRequest]
|
|
3534
3534
|
# @param [Hash] opts the optional parameters
|
|
@@ -3540,7 +3540,7 @@ module Repull
|
|
|
3540
3540
|
end
|
|
3541
3541
|
|
|
3542
3542
|
# Answer Airbnb permit questions
|
|
3543
|
-
# Answer the regulatory permit questions for a listing — the licence or registration number a city requires to keep the listing up. Read the questions first with `GET …/permits?source=live`
|
|
3543
|
+
# Answer the regulatory permit questions for a listing — the licence or registration number a city requires to keep the listing up. Read the questions first with `GET …/permits?source=live`. For each permit, pick one of its `flows[]` and send its `slug` as `flow_slug`; key every answer by the question's `answer_key`, and let the question's `type` decide the value field (`text_value`, `attestation_value`, `radio_value`, `date_value` or `selected_options_value`). Answers are forwarded verbatim — nothing is defaulted or inferred, because a wrong licence number can take a listing down in a regulated city. Send `Idempotency-Key`: a timeout here leaves you unable to tell \"never arrived\" from \"arrived, response lost\", and this is a compliance filing. Airbnb refusing the answers (an unknown `answer_key`, a malformed licence number) is `422 airbnb_rejected` carrying Airbnb's own reason. An expired or revoked Airbnb connection is `403 connection_reauth_required`.
|
|
3544
3544
|
# @param id [String] Repull listing id (numeric string).
|
|
3545
3545
|
# @param airbnb_permits_write_request [AirbnbPermitsWriteRequest]
|
|
3546
3546
|
# @param [Hash] opts the optional parameters
|
|
@@ -172,7 +172,7 @@ module Repull
|
|
|
172
172
|
end
|
|
173
173
|
|
|
174
174
|
# Booking.com property setup actions
|
|
175
|
-
# Action-router for putting a property onto Booking.com — including building one from nothing. Select the step with `action`. ## Opening a property - `create-property` — create a NEW Booking.com property for a Repull listing (`listing_id`). Creates the property, its first room, a rate plan and the room-rate product that makes the room sellable, seeds availability and rates, syncs the calendar, then
|
|
175
|
+
# Action-router for putting a property onto Booking.com — including building one from nothing. Select the step with `action`. ## Opening a property - `create-property` — create a NEW Booking.com property for a Repull listing (`listing_id`). Creates the property, its first room with the listing's beds, a rate plan and the room-rate product that makes the room sellable (under the listing's cancellation policy), sets the contact and invoice details and the facilities, seeds availability and rates, syncs the calendar, then runs Booking.com's readiness check and reports what still blocks opening in `warnings`. Send `contact` (`name`, `email`, `phone` in international form); without it the workspace owner is used, and a workspace with no usable contact is refused before anything is created. Returns 201. - `add-room` — add another room type (and its sellable product) to a property (`listing_id`, `property_id`). Returns 201. - `add-unit` — raise the number of identical units on an existing room (`listing_id`, `property_id`, `room_id`). - `advance` — run Booking.com's readiness check for a property (`property_id`) and, when it passes, open it. Returns `checked`, `opened`, `sellable` and `blockers` — Booking.com's own reasons it cannot open yet. ## Account and policy steps - `create-legal-entity` — register a legal entity directly (returns 201). Not normally needed: see the legal-entity rules below. - `check-legal-status` — always `404`. A legal entity's details are readable for any id on the connectivity-provider credentials every workspace shares, and nothing records which workspace registered which entity, so no entity can be shown to be yours. `create-property` resolves it for you. - `check-readiness` — whether a property is ready to open (`property_id`): `ready` and `blockers`, without trying to open it. - `open-property` — open the property for sale (`property_id`). Refused with `422 booking_rejected` naming the blockers when it is not ready. - `set-contacts` — set property contacts (`property_id`, `contacts` in Booking.com's Contacts API shape; at most one carries the `general` profile). - `set-policies` — add a cancellation policy (`property_id`, `policyCode`, optional `prepaymentRequired`). House rules, pets, children and the damage deposit are `POST /v1/channels/booking/content` with `type: \"settings\"`. ## Three things about Booking.com that cost real money **A newly created property is NOT sellable.** Booking.com opens it only when its readiness check passes, and the check names what is missing — a main photo still processing, no availability, a licence the region requires. The response always reports `status: \"being_built\"` and `sellable: false`, never a guess, with the reasons in `warnings`. Resolve them, then `advance`. **A room with no ACTIVE rate plan is invisible.** Booking only renders rooms that have at least one active product linkage (room × rate plan). A room can be created successfully, return a `roomId`, and never appear on the property page. If `rateId` comes back `null` from `create-property` or `add-room`, that is exactly what happened: activate a rate plan on the property in the Extranet, then add the room again. **Room names are Booking.com's.** Travellers see one of Booking.com's standard names (\"Two-Bedroom Apartment\"), chosen from the listing's bedrooms. The listing's own name is kept as the operator-side reference, never shown to guests. ## The legal entity is resolved, not asked for A property is created against the legal entity Booking.com contracts with, invoices and pays. You do not normally send one: 1. If this workspace already creates properties under a legal entity, that one is reused. A second is never registered. 2. If it has none and the request carries `legal_entity` (`company_name`, `legal_contact_name`, `legal_contact_email`), one is registered and used. Booking.com emails the legal contact a contract; creation only succeeds once it is signed. 3. If it has none and no `legal_entity`, the request is refused with `422 legal_entity_required` naming the fields — a contracted company is never invented. `legal_entity_id` overrides all of that. An id that already carries another workspace's properties is refused with `403 legal_entity_not_yours` before anything is created. ## What you do not control Properties are created against Booking's **production** target only. A test-target property cannot be sold through and there is no route back from one, so `target` is not a parameter — sending it changes nothing. The property category comes from the listing's property type (Apartment when it has none; Holiday home, Villa or Chalet when it says so). The initial room count is 1. Latitude and longitude come from the listing and are adjusted slightly to clear Booking.com's duplicate detection — send the property's true position on the listing and do not pre-adjust it yourself. The listing's name, check-in/check-out times, currency, capacity and price come from the listing. Its postal code is taken from the listing's own `postalCode`; when the listing has none, it falls back to a connected Airbnb listing. A listing with neither is created without a postal code, so set `postalCode` on the listing first. ## Guards Every action that takes a `property_id` requires a property connected to this workspace; any other id returns `404 not_found`. Every action that takes a `listing_id` requires a listing in this workspace; any other id returns `404 not_found`. `create-property` refuses a listing with no coordinates (`422 missing_coordinates`) before anything is created — creating a Booking.com property cannot be undone. `create-property` is subject to the same published-listing gate as the dashboard: no plan, or the plan's listing limit reached, returns `403 billing_error` with `used` and `limit`, and nothing is created. Returns `403 listing_inactive` when the listing — or any listing mapped to the Booking.com property — is inactive. An inactive listing keeps syncing, but cannot be read or changed through the API until it is activated. If a property is created and a later step fails, the response is `422 booking_create_partial` carrying `property_id`. The property EXISTS. Do not retry `create-property`, which would open a second one — continue with `add-room` and `advance`.
|
|
176
176
|
# @param booking_setup_request [BookingSetupRequest]
|
|
177
177
|
# @param [Hash] opts the optional parameters
|
|
178
178
|
# @return [nil]
|
|
@@ -182,7 +182,7 @@ module Repull
|
|
|
182
182
|
end
|
|
183
183
|
|
|
184
184
|
# Booking.com property setup actions
|
|
185
|
-
# Action-router for putting a property onto Booking.com — including building one from nothing. Select the step with `action`. ## Opening a property - `create-property` — create a NEW Booking.com property for a Repull listing (`listing_id`). Creates the property, its first room, a rate plan and the room-rate product that makes the room sellable, seeds availability and rates, syncs the calendar, then
|
|
185
|
+
# Action-router for putting a property onto Booking.com — including building one from nothing. Select the step with `action`. ## Opening a property - `create-property` — create a NEW Booking.com property for a Repull listing (`listing_id`). Creates the property, its first room with the listing's beds, a rate plan and the room-rate product that makes the room sellable (under the listing's cancellation policy), sets the contact and invoice details and the facilities, seeds availability and rates, syncs the calendar, then runs Booking.com's readiness check and reports what still blocks opening in `warnings`. Send `contact` (`name`, `email`, `phone` in international form); without it the workspace owner is used, and a workspace with no usable contact is refused before anything is created. Returns 201. - `add-room` — add another room type (and its sellable product) to a property (`listing_id`, `property_id`). Returns 201. - `add-unit` — raise the number of identical units on an existing room (`listing_id`, `property_id`, `room_id`). - `advance` — run Booking.com's readiness check for a property (`property_id`) and, when it passes, open it. Returns `checked`, `opened`, `sellable` and `blockers` — Booking.com's own reasons it cannot open yet. ## Account and policy steps - `create-legal-entity` — register a legal entity directly (returns 201). Not normally needed: see the legal-entity rules below. - `check-legal-status` — always `404`. A legal entity's details are readable for any id on the connectivity-provider credentials every workspace shares, and nothing records which workspace registered which entity, so no entity can be shown to be yours. `create-property` resolves it for you. - `check-readiness` — whether a property is ready to open (`property_id`): `ready` and `blockers`, without trying to open it. - `open-property` — open the property for sale (`property_id`). Refused with `422 booking_rejected` naming the blockers when it is not ready. - `set-contacts` — set property contacts (`property_id`, `contacts` in Booking.com's Contacts API shape; at most one carries the `general` profile). - `set-policies` — add a cancellation policy (`property_id`, `policyCode`, optional `prepaymentRequired`). House rules, pets, children and the damage deposit are `POST /v1/channels/booking/content` with `type: \"settings\"`. ## Three things about Booking.com that cost real money **A newly created property is NOT sellable.** Booking.com opens it only when its readiness check passes, and the check names what is missing — a main photo still processing, no availability, a licence the region requires. The response always reports `status: \"being_built\"` and `sellable: false`, never a guess, with the reasons in `warnings`. Resolve them, then `advance`. **A room with no ACTIVE rate plan is invisible.** Booking only renders rooms that have at least one active product linkage (room × rate plan). A room can be created successfully, return a `roomId`, and never appear on the property page. If `rateId` comes back `null` from `create-property` or `add-room`, that is exactly what happened: activate a rate plan on the property in the Extranet, then add the room again. **Room names are Booking.com's.** Travellers see one of Booking.com's standard names (\"Two-Bedroom Apartment\"), chosen from the listing's bedrooms. The listing's own name is kept as the operator-side reference, never shown to guests. ## The legal entity is resolved, not asked for A property is created against the legal entity Booking.com contracts with, invoices and pays. You do not normally send one: 1. If this workspace already creates properties under a legal entity, that one is reused. A second is never registered. 2. If it has none and the request carries `legal_entity` (`company_name`, `legal_contact_name`, `legal_contact_email`), one is registered and used. Booking.com emails the legal contact a contract; creation only succeeds once it is signed. 3. If it has none and no `legal_entity`, the request is refused with `422 legal_entity_required` naming the fields — a contracted company is never invented. `legal_entity_id` overrides all of that. An id that already carries another workspace's properties is refused with `403 legal_entity_not_yours` before anything is created. ## What you do not control Properties are created against Booking's **production** target only. A test-target property cannot be sold through and there is no route back from one, so `target` is not a parameter — sending it changes nothing. The property category comes from the listing's property type (Apartment when it has none; Holiday home, Villa or Chalet when it says so). The initial room count is 1. Latitude and longitude come from the listing and are adjusted slightly to clear Booking.com's duplicate detection — send the property's true position on the listing and do not pre-adjust it yourself. The listing's name, check-in/check-out times, currency, capacity and price come from the listing. Its postal code is taken from the listing's own `postalCode`; when the listing has none, it falls back to a connected Airbnb listing. A listing with neither is created without a postal code, so set `postalCode` on the listing first. ## Guards Every action that takes a `property_id` requires a property connected to this workspace; any other id returns `404 not_found`. Every action that takes a `listing_id` requires a listing in this workspace; any other id returns `404 not_found`. `create-property` refuses a listing with no coordinates (`422 missing_coordinates`) before anything is created — creating a Booking.com property cannot be undone. `create-property` is subject to the same published-listing gate as the dashboard: no plan, or the plan's listing limit reached, returns `403 billing_error` with `used` and `limit`, and nothing is created. Returns `403 listing_inactive` when the listing — or any listing mapped to the Booking.com property — is inactive. An inactive listing keeps syncing, but cannot be read or changed through the API until it is activated. If a property is created and a later step fails, the response is `422 booking_create_partial` carrying `property_id`. The property EXISTS. Do not retry `create-property`, which would open a second one — continue with `add-room` and `advance`.
|
|
186
186
|
# @param booking_setup_request [BookingSetupRequest]
|
|
187
187
|
# @param [Hash] opts the optional parameters
|
|
188
188
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
@@ -378,7 +378,7 @@ module Repull
|
|
|
378
378
|
# @option opts [Date] :start_date Window start (ISO YYYY-MM-DD).
|
|
379
379
|
# @option opts [Integer] :number_of_days Window length in days.
|
|
380
380
|
# @option opts [String] :room_id Restrict to a single Booking.com room id.
|
|
381
|
-
# @option opts [Boolean] :room_level
|
|
381
|
+
# @option opts [Boolean] :room_level Defaults to `true`: availability per room, which is how Booking.com keeps inventory and how Vanio reads it. Send `false` for the per-rate read — its `roomsToSell` is often 0 for rooms that are on sale.
|
|
382
382
|
# @return [BookingAvailabilityStateResponse]
|
|
383
383
|
def get_booking_availability(property_id, opts = {})
|
|
384
384
|
data, _status_code, _headers = get_booking_availability_with_http_info(property_id, opts)
|
|
@@ -392,7 +392,7 @@ module Repull
|
|
|
392
392
|
# @option opts [Date] :start_date Window start (ISO YYYY-MM-DD).
|
|
393
393
|
# @option opts [Integer] :number_of_days Window length in days.
|
|
394
394
|
# @option opts [String] :room_id Restrict to a single Booking.com room id.
|
|
395
|
-
# @option opts [Boolean] :room_level
|
|
395
|
+
# @option opts [Boolean] :room_level Defaults to `true`: availability per room, which is how Booking.com keeps inventory and how Vanio reads it. Send `false` for the per-rate read — its `roomsToSell` is often 0 for rooms that are on sale.
|
|
396
396
|
# @return [Array<(BookingAvailabilityStateResponse, Integer, Hash)>] BookingAvailabilityStateResponse data, response status code and response headers
|
|
397
397
|
def get_booking_availability_with_http_info(property_id, opts = {})
|
|
398
398
|
if @api_client.config.debugging
|
|
@@ -512,27 +512,44 @@ module Repull
|
|
|
512
512
|
end
|
|
513
513
|
|
|
514
514
|
# Get Booking.com content
|
|
515
|
-
#
|
|
515
|
+
# Read one kind of content for a Booking.com property, straight from Booking.com. | `type` | What it is | |---|---| | `photos` | The property's photos. Add `room_id` to read one room's gallery. | | `facilities` | Property facilities, or a room's with `room_id` (Booking.com's ids — `GET` returns them). | | `description` | The property description. Booking.com rewrites what you send into its own multilingual copy; allow about 3 hours to appear. | | `settings` | House rules, pets, children, damage deposit, invoice recipient, booking model. | | `policies` | Cancellation and prepayment policies. | | `licences` | The region's licence rules and the licence on file. | | `checkin_methods` | How guests get in (holiday homes). | | `contacts` | Who Booking.com contacts about the property. | `amenities` is accepted as another name for `facilities`, and `descriptions` for `description`. `property_id` must be a Booking.com property connected to this workspace (`GET /v1/channels/booking/properties` lists them). Any other id — including one connected to a different workspace — returns `404 not_found`, the same answer as an id that does not exist. Returns `403 listing_inactive` when any listing mapped to the Booking.com property is inactive. An inactive listing keeps syncing, but cannot be read or changed through the API until it is activated.
|
|
516
|
+
# @param property_id [String] Booking.com property id.
|
|
516
517
|
# @param [Hash] opts the optional parameters
|
|
518
|
+
# @option opts [String] :type Which content to read. (default to 'photos')
|
|
519
|
+
# @option opts [String] :room_id A Booking.com room id, for `photos`, `facilities` and `licences`.
|
|
517
520
|
# @return [nil]
|
|
518
|
-
def get_booking_content(opts = {})
|
|
519
|
-
get_booking_content_with_http_info(opts)
|
|
521
|
+
def get_booking_content(property_id, opts = {})
|
|
522
|
+
get_booking_content_with_http_info(property_id, opts)
|
|
520
523
|
nil
|
|
521
524
|
end
|
|
522
525
|
|
|
523
526
|
# Get Booking.com content
|
|
524
|
-
#
|
|
527
|
+
# Read one kind of content for a Booking.com property, straight from Booking.com. | `type` | What it is | |---|---| | `photos` | The property's photos. Add `room_id` to read one room's gallery. | | `facilities` | Property facilities, or a room's with `room_id` (Booking.com's ids — `GET` returns them). | | `description` | The property description. Booking.com rewrites what you send into its own multilingual copy; allow about 3 hours to appear. | | `settings` | House rules, pets, children, damage deposit, invoice recipient, booking model. | | `policies` | Cancellation and prepayment policies. | | `licences` | The region's licence rules and the licence on file. | | `checkin_methods` | How guests get in (holiday homes). | | `contacts` | Who Booking.com contacts about the property. | `amenities` is accepted as another name for `facilities`, and `descriptions` for `description`. `property_id` must be a Booking.com property connected to this workspace (`GET /v1/channels/booking/properties` lists them). Any other id — including one connected to a different workspace — returns `404 not_found`, the same answer as an id that does not exist. Returns `403 listing_inactive` when any listing mapped to the Booking.com property is inactive. An inactive listing keeps syncing, but cannot be read or changed through the API until it is activated.
|
|
528
|
+
# @param property_id [String] Booking.com property id.
|
|
525
529
|
# @param [Hash] opts the optional parameters
|
|
530
|
+
# @option opts [String] :type Which content to read. (default to 'photos')
|
|
531
|
+
# @option opts [String] :room_id A Booking.com room id, for `photos`, `facilities` and `licences`.
|
|
526
532
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
527
|
-
def get_booking_content_with_http_info(opts = {})
|
|
533
|
+
def get_booking_content_with_http_info(property_id, opts = {})
|
|
528
534
|
if @api_client.config.debugging
|
|
529
535
|
@api_client.config.logger.debug 'Calling API: BookingComApi.get_booking_content ...'
|
|
530
536
|
end
|
|
537
|
+
# verify the required parameter 'property_id' is set
|
|
538
|
+
if @api_client.config.client_side_validation && property_id.nil?
|
|
539
|
+
fail ArgumentError, "Missing the required parameter 'property_id' when calling BookingComApi.get_booking_content"
|
|
540
|
+
end
|
|
541
|
+
allowable_values = ["photos", "facilities", "description", "settings", "policies", "licences", "checkin_methods", "contacts"]
|
|
542
|
+
if @api_client.config.client_side_validation && opts[:'type'] && !allowable_values.include?(opts[:'type'])
|
|
543
|
+
fail ArgumentError, "invalid value for \"type\", must be one of #{allowable_values}"
|
|
544
|
+
end
|
|
531
545
|
# resource path
|
|
532
546
|
local_var_path = '/v1/channels/booking/content'
|
|
533
547
|
|
|
534
548
|
# query parameters
|
|
535
549
|
query_params = opts[:query_params] || {}
|
|
550
|
+
query_params[:'property_id'] = property_id
|
|
551
|
+
query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
|
|
552
|
+
query_params[:'room_id'] = opts[:'room_id'] if !opts[:'room_id'].nil?
|
|
536
553
|
|
|
537
554
|
# header parameters
|
|
538
555
|
header_params = opts[:header_params] || {}
|
|
@@ -575,7 +592,7 @@ module Repull
|
|
|
575
592
|
# @option opts [Date] :start_date
|
|
576
593
|
# @option opts [Integer] :number_of_days
|
|
577
594
|
# @option opts [String] :room_id
|
|
578
|
-
# @option opts [Boolean] :room_level
|
|
595
|
+
# @option opts [Boolean] :room_level Defaults to `true`: availability per room, which is how Booking.com keeps inventory and how Vanio reads it. Send `false` for the per-rate read — its `roomsToSell` is often 0 for rooms that are on sale.
|
|
579
596
|
# @option opts [String] :hotel_id Booking.com hotel id, when this listing is published under more than one property. Omit it and a read uses the oldest mapping (reporting the rest in `otherHotelIds`), while a write is refused with `409 ambiguous_booking_mapping` rather than guess. `GET /v1/channels/booking/properties` lists the valid ids.
|
|
580
597
|
# @return [BookingPricingResponse]
|
|
581
598
|
def get_booking_listing_pricing(id, opts = {})
|
|
@@ -590,7 +607,7 @@ module Repull
|
|
|
590
607
|
# @option opts [Date] :start_date
|
|
591
608
|
# @option opts [Integer] :number_of_days
|
|
592
609
|
# @option opts [String] :room_id
|
|
593
|
-
# @option opts [Boolean] :room_level
|
|
610
|
+
# @option opts [Boolean] :room_level Defaults to `true`: availability per room, which is how Booking.com keeps inventory and how Vanio reads it. Send `false` for the per-rate read — its `roomsToSell` is often 0 for rooms that are on sale.
|
|
594
611
|
# @option opts [String] :hotel_id Booking.com hotel id, when this listing is published under more than one property. Omit it and a read uses the oldest mapping (reporting the rest in `otherHotelIds`), while a write is refused with `409 ambiguous_booking_mapping` rather than guess. `GET /v1/channels/booking/properties` lists the valid ids.
|
|
595
612
|
# @return [Array<(BookingPricingResponse, Integer, Hash)>] BookingPricingResponse data, response status code and response headers
|
|
596
613
|
def get_booking_listing_pricing_with_http_info(id, opts = {})
|
|
@@ -1080,6 +1097,74 @@ module Repull
|
|
|
1080
1097
|
return data, status_code, headers
|
|
1081
1098
|
end
|
|
1082
1099
|
|
|
1100
|
+
# Map a Booking.com room to a Repull listing
|
|
1101
|
+
# Link a Booking.com room to a canonical Repull listing — the API-key equivalent of the room mapping the hosted Connect flow performs, and the counterpart of `POST /v1/channels/airbnb/listings/map`. Discover `roomBookingId` with `GET /v1/channels/booking/properties/{id}/rooms`, which returns every room of a property with the `roomId` this route takes. Booking.com attaches at the ROOM level: a property is a building and its rooms are what a guest books, so each room maps to one listing. Pass `listingId: null` to unmap a room and remove its channel link. The room mapping and its channel link are repointed together in one transaction, so a link can never outlive the mapping it describes — a stale link keeps routing that room's reservations to the previous listing. Re-sending a mapping that is already in place writes nothing (`alreadyMapped: true`). **The property's reservations are pulled as part of the call.** Once the room is mapped, every active reservation Booking.com holds for the property is imported and attached to its listing — `reservationsImported` says how many were processed. One already present is left as it is, so re-sending never duplicates. You do not need a follow-up call: reservations that arrived before the room was mapped are never picked up by the regular sync, so this is the moment they are brought in. It runs on every successful map, including a re-send, so re-sending retries an import that did not run. If the import cannot run, the mapping still stands and `reservationsImported` is `null`. A property with a long booking history can take tens of seconds. Unmapping pulls nothing. Unlike the Airbnb route, there is no conflict when the target listing already carries another Booking.com room: one listing served by several rooms is a normal arrangement and is not refused. Scope is enforced on both sides against your workspace — the room's property and the target listing. A room or listing belonging to another workspace returns the same 404 as one that does not exist. Returns `403 listing_inactive` when the target listing, or the listing the room is mapped to now, is inactive; nothing is changed.
|
|
1102
|
+
# @param map_booking_room_request [MapBookingRoomRequest]
|
|
1103
|
+
# @param [Hash] opts the optional parameters
|
|
1104
|
+
# @return [MapBookingRoomResponse]
|
|
1105
|
+
def map_booking_room(map_booking_room_request, opts = {})
|
|
1106
|
+
data, _status_code, _headers = map_booking_room_with_http_info(map_booking_room_request, opts)
|
|
1107
|
+
data
|
|
1108
|
+
end
|
|
1109
|
+
|
|
1110
|
+
# Map a Booking.com room to a Repull listing
|
|
1111
|
+
# Link a Booking.com room to a canonical Repull listing — the API-key equivalent of the room mapping the hosted Connect flow performs, and the counterpart of `POST /v1/channels/airbnb/listings/map`. Discover `roomBookingId` with `GET /v1/channels/booking/properties/{id}/rooms`, which returns every room of a property with the `roomId` this route takes. Booking.com attaches at the ROOM level: a property is a building and its rooms are what a guest books, so each room maps to one listing. Pass `listingId: null` to unmap a room and remove its channel link. The room mapping and its channel link are repointed together in one transaction, so a link can never outlive the mapping it describes — a stale link keeps routing that room's reservations to the previous listing. Re-sending a mapping that is already in place writes nothing (`alreadyMapped: true`). **The property's reservations are pulled as part of the call.** Once the room is mapped, every active reservation Booking.com holds for the property is imported and attached to its listing — `reservationsImported` says how many were processed. One already present is left as it is, so re-sending never duplicates. You do not need a follow-up call: reservations that arrived before the room was mapped are never picked up by the regular sync, so this is the moment they are brought in. It runs on every successful map, including a re-send, so re-sending retries an import that did not run. If the import cannot run, the mapping still stands and `reservationsImported` is `null`. A property with a long booking history can take tens of seconds. Unmapping pulls nothing. Unlike the Airbnb route, there is no conflict when the target listing already carries another Booking.com room: one listing served by several rooms is a normal arrangement and is not refused. Scope is enforced on both sides against your workspace — the room's property and the target listing. A room or listing belonging to another workspace returns the same 404 as one that does not exist. Returns `403 listing_inactive` when the target listing, or the listing the room is mapped to now, is inactive; nothing is changed.
|
|
1112
|
+
# @param map_booking_room_request [MapBookingRoomRequest]
|
|
1113
|
+
# @param [Hash] opts the optional parameters
|
|
1114
|
+
# @return [Array<(MapBookingRoomResponse, Integer, Hash)>] MapBookingRoomResponse data, response status code and response headers
|
|
1115
|
+
def map_booking_room_with_http_info(map_booking_room_request, opts = {})
|
|
1116
|
+
if @api_client.config.debugging
|
|
1117
|
+
@api_client.config.logger.debug 'Calling API: BookingComApi.map_booking_room ...'
|
|
1118
|
+
end
|
|
1119
|
+
# verify the required parameter 'map_booking_room_request' is set
|
|
1120
|
+
if @api_client.config.client_side_validation && map_booking_room_request.nil?
|
|
1121
|
+
fail ArgumentError, "Missing the required parameter 'map_booking_room_request' when calling BookingComApi.map_booking_room"
|
|
1122
|
+
end
|
|
1123
|
+
# resource path
|
|
1124
|
+
local_var_path = '/v1/channels/booking/listings/map'
|
|
1125
|
+
|
|
1126
|
+
# query parameters
|
|
1127
|
+
query_params = opts[:query_params] || {}
|
|
1128
|
+
|
|
1129
|
+
# header parameters
|
|
1130
|
+
header_params = opts[:header_params] || {}
|
|
1131
|
+
# HTTP header 'Accept' (if needed)
|
|
1132
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1133
|
+
# HTTP header 'Content-Type'
|
|
1134
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1135
|
+
if !content_type.nil?
|
|
1136
|
+
header_params['Content-Type'] = content_type
|
|
1137
|
+
end
|
|
1138
|
+
|
|
1139
|
+
# form parameters
|
|
1140
|
+
form_params = opts[:form_params] || {}
|
|
1141
|
+
|
|
1142
|
+
# http body (model)
|
|
1143
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(map_booking_room_request)
|
|
1144
|
+
|
|
1145
|
+
# return_type
|
|
1146
|
+
return_type = opts[:debug_return_type] || 'MapBookingRoomResponse'
|
|
1147
|
+
|
|
1148
|
+
# auth_names
|
|
1149
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
1150
|
+
|
|
1151
|
+
new_options = opts.merge(
|
|
1152
|
+
:operation => :"BookingComApi.map_booking_room",
|
|
1153
|
+
:header_params => header_params,
|
|
1154
|
+
:query_params => query_params,
|
|
1155
|
+
:form_params => form_params,
|
|
1156
|
+
:body => post_body,
|
|
1157
|
+
:auth_names => auth_names,
|
|
1158
|
+
:return_type => return_type
|
|
1159
|
+
)
|
|
1160
|
+
|
|
1161
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
1162
|
+
if @api_client.config.debugging
|
|
1163
|
+
@api_client.config.logger.debug "API called: BookingComApi#map_booking_room\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1164
|
+
end
|
|
1165
|
+
return data, status_code, headers
|
|
1166
|
+
end
|
|
1167
|
+
|
|
1083
1168
|
# Reply to Booking.com review
|
|
1084
1169
|
# Post a public host reply to a guest review on Booking.com. Booking allows one host reply per review — repeated POSTs are rejected by upstream. Booking.com does NOT support host-authored reviews of guests via the API (platform-level limitation), so this endpoint is reply-only. `property_id` must be a Booking.com property connected to this workspace (`GET /v1/channels/booking/properties` lists them). Any other id — including one connected to a different workspace — returns `404 not_found`, the same answer as an id that does not exist. Returns `403 listing_inactive` when any listing mapped to the Booking.com property is inactive. An inactive listing keeps syncing, but cannot be read or changed through the API until it is activated.
|
|
1085
1170
|
# @param reply_booking_review_request [ReplyBookingReviewRequest]
|
|
@@ -1353,22 +1438,28 @@ module Repull
|
|
|
1353
1438
|
end
|
|
1354
1439
|
|
|
1355
1440
|
# Update Booking.com content
|
|
1356
|
-
#
|
|
1441
|
+
# Write one kind of content to a Booking.com property only. Nothing on the canonical listing or on Airbnb changes. To send the listing's own content to every channel instead, use `PUT /v1/listings/{id}/content` and publish. | `type` | What it is | |---|---| | `photos` | The property's photos. Add `room_id` to read one room's gallery. | | `facilities` | Property facilities, or a room's with `room_id` (Booking.com's ids — `GET` returns them). | | `description` | The property description. Booking.com rewrites what you send into its own multilingual copy; allow about 3 hours to appear. | | `settings` | House rules, pets, children, damage deposit, invoice recipient, booking model. | | `policies` | Cancellation and prepayment policies. | | `licences` | The region's licence rules and the licence on file. | | `checkin_methods` | How guests get in (holiday homes). | | `contacts` | Who Booking.com contacts about the property. | `amenities` is accepted as another name for `facilities`, and `descriptions` for `description`. What each `type` takes: - `description`: `text`, optional `language` (default `en`). - `facilities`: `facilities: [{ facility_id | room_facility_id, state: \"PRESENT\" | \"MISSING\", instances? }]`. Facilities you do not send stay as they are. - `photos`: `photos: [{ url }]`, uploaded in the background. With `room_id`, send `photo_ids` instead to add photos that have finished processing to that room. - `settings`: `settings: { <block>: {…} }`, for example `{ \"pets\": { \"pets_allowed\": \"PETS_ALLOWED\" } }`. Each block is written separately and reported in `results`. - `policies`: `policyCode` (152 = free cancellation at any time, 1 = non-refundable, …), optional `prepaymentRequired`; add `policyId` to change an existing policy. A property holds at most 7 policies and none can be deleted. - `licences`: `variantId` and `contentData: [{ name, value }]`, from the rules `GET ?type=licences` returns; optional `room_id`. - `checkin_methods`: `methods: [{ checkin_method }]`, using a name from `GET ?type=checkin_methods` `available`. - `contacts`: `contacts: [...]` in Booking.com's contact shape. If Booking.com refuses the write, the response is `422 booking_rejected` with Booking.com's reason, even when Booking.com answered HTTP 200. Resending the same body will be refused again. `property_id` must be a Booking.com property connected to this workspace (`GET /v1/channels/booking/properties` lists them). Any other id — including one connected to a different workspace — returns `404 not_found`, the same answer as an id that does not exist. Returns `403 listing_inactive` when any listing mapped to the Booking.com property is inactive. An inactive listing keeps syncing, but cannot be read or changed through the API until it is activated.
|
|
1442
|
+
# @param update_booking_content_request [UpdateBookingContentRequest]
|
|
1357
1443
|
# @param [Hash] opts the optional parameters
|
|
1358
1444
|
# @return [nil]
|
|
1359
|
-
def update_booking_content(opts = {})
|
|
1360
|
-
update_booking_content_with_http_info(opts)
|
|
1445
|
+
def update_booking_content(update_booking_content_request, opts = {})
|
|
1446
|
+
update_booking_content_with_http_info(update_booking_content_request, opts)
|
|
1361
1447
|
nil
|
|
1362
1448
|
end
|
|
1363
1449
|
|
|
1364
1450
|
# Update Booking.com content
|
|
1365
|
-
#
|
|
1451
|
+
# Write one kind of content to a Booking.com property only. Nothing on the canonical listing or on Airbnb changes. To send the listing's own content to every channel instead, use `PUT /v1/listings/{id}/content` and publish. | `type` | What it is | |---|---| | `photos` | The property's photos. Add `room_id` to read one room's gallery. | | `facilities` | Property facilities, or a room's with `room_id` (Booking.com's ids — `GET` returns them). | | `description` | The property description. Booking.com rewrites what you send into its own multilingual copy; allow about 3 hours to appear. | | `settings` | House rules, pets, children, damage deposit, invoice recipient, booking model. | | `policies` | Cancellation and prepayment policies. | | `licences` | The region's licence rules and the licence on file. | | `checkin_methods` | How guests get in (holiday homes). | | `contacts` | Who Booking.com contacts about the property. | `amenities` is accepted as another name for `facilities`, and `descriptions` for `description`. What each `type` takes: - `description`: `text`, optional `language` (default `en`). - `facilities`: `facilities: [{ facility_id | room_facility_id, state: \"PRESENT\" | \"MISSING\", instances? }]`. Facilities you do not send stay as they are. - `photos`: `photos: [{ url }]`, uploaded in the background. With `room_id`, send `photo_ids` instead to add photos that have finished processing to that room. - `settings`: `settings: { <block>: {…} }`, for example `{ \"pets\": { \"pets_allowed\": \"PETS_ALLOWED\" } }`. Each block is written separately and reported in `results`. - `policies`: `policyCode` (152 = free cancellation at any time, 1 = non-refundable, …), optional `prepaymentRequired`; add `policyId` to change an existing policy. A property holds at most 7 policies and none can be deleted. - `licences`: `variantId` and `contentData: [{ name, value }]`, from the rules `GET ?type=licences` returns; optional `room_id`. - `checkin_methods`: `methods: [{ checkin_method }]`, using a name from `GET ?type=checkin_methods` `available`. - `contacts`: `contacts: [...]` in Booking.com's contact shape. If Booking.com refuses the write, the response is `422 booking_rejected` with Booking.com's reason, even when Booking.com answered HTTP 200. Resending the same body will be refused again. `property_id` must be a Booking.com property connected to this workspace (`GET /v1/channels/booking/properties` lists them). Any other id — including one connected to a different workspace — returns `404 not_found`, the same answer as an id that does not exist. Returns `403 listing_inactive` when any listing mapped to the Booking.com property is inactive. An inactive listing keeps syncing, but cannot be read or changed through the API until it is activated.
|
|
1452
|
+
# @param update_booking_content_request [UpdateBookingContentRequest]
|
|
1366
1453
|
# @param [Hash] opts the optional parameters
|
|
1367
1454
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
1368
|
-
def update_booking_content_with_http_info(opts = {})
|
|
1455
|
+
def update_booking_content_with_http_info(update_booking_content_request, opts = {})
|
|
1369
1456
|
if @api_client.config.debugging
|
|
1370
1457
|
@api_client.config.logger.debug 'Calling API: BookingComApi.update_booking_content ...'
|
|
1371
1458
|
end
|
|
1459
|
+
# verify the required parameter 'update_booking_content_request' is set
|
|
1460
|
+
if @api_client.config.client_side_validation && update_booking_content_request.nil?
|
|
1461
|
+
fail ArgumentError, "Missing the required parameter 'update_booking_content_request' when calling BookingComApi.update_booking_content"
|
|
1462
|
+
end
|
|
1372
1463
|
# resource path
|
|
1373
1464
|
local_var_path = '/v1/channels/booking/content'
|
|
1374
1465
|
|
|
@@ -1379,12 +1470,17 @@ module Repull
|
|
|
1379
1470
|
header_params = opts[:header_params] || {}
|
|
1380
1471
|
# HTTP header 'Accept' (if needed)
|
|
1381
1472
|
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1473
|
+
# HTTP header 'Content-Type'
|
|
1474
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1475
|
+
if !content_type.nil?
|
|
1476
|
+
header_params['Content-Type'] = content_type
|
|
1477
|
+
end
|
|
1382
1478
|
|
|
1383
1479
|
# form parameters
|
|
1384
1480
|
form_params = opts[:form_params] || {}
|
|
1385
1481
|
|
|
1386
1482
|
# http body (model)
|
|
1387
|
-
post_body = opts[:debug_body]
|
|
1483
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(update_booking_content_request)
|
|
1388
1484
|
|
|
1389
1485
|
# return_type
|
|
1390
1486
|
return_type = opts[:debug_return_type]
|
|
@@ -19,63 +19,6 @@ module Repull
|
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
|
20
20
|
@api_client = api_client
|
|
21
21
|
end
|
|
22
|
-
# Atlas market-intelligence backend health
|
|
23
|
-
# Component-level probe. `GET /v1/health` reports the API as a whole; this reports one dependency so an incident can be localised without guessing.
|
|
24
|
-
# @param [Hash] opts the optional parameters
|
|
25
|
-
# @return [Hash<String, Object>]
|
|
26
|
-
def get_atlas_health(opts = {})
|
|
27
|
-
data, _status_code, _headers = get_atlas_health_with_http_info(opts)
|
|
28
|
-
data
|
|
29
|
-
end
|
|
30
|
-
|
|
31
|
-
# Atlas market-intelligence backend health
|
|
32
|
-
# Component-level probe. `GET /v1/health` reports the API as a whole; this reports one dependency so an incident can be localised without guessing.
|
|
33
|
-
# @param [Hash] opts the optional parameters
|
|
34
|
-
# @return [Array<(Hash<String, Object>, Integer, Hash)>] Hash<String, Object> data, response status code and response headers
|
|
35
|
-
def get_atlas_health_with_http_info(opts = {})
|
|
36
|
-
if @api_client.config.debugging
|
|
37
|
-
@api_client.config.logger.debug 'Calling API: HealthApi.get_atlas_health ...'
|
|
38
|
-
end
|
|
39
|
-
# resource path
|
|
40
|
-
local_var_path = '/v1/health/atlas'
|
|
41
|
-
|
|
42
|
-
# query parameters
|
|
43
|
-
query_params = opts[:query_params] || {}
|
|
44
|
-
|
|
45
|
-
# header parameters
|
|
46
|
-
header_params = opts[:header_params] || {}
|
|
47
|
-
# HTTP header 'Accept' (if needed)
|
|
48
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
49
|
-
|
|
50
|
-
# form parameters
|
|
51
|
-
form_params = opts[:form_params] || {}
|
|
52
|
-
|
|
53
|
-
# http body (model)
|
|
54
|
-
post_body = opts[:debug_body]
|
|
55
|
-
|
|
56
|
-
# return_type
|
|
57
|
-
return_type = opts[:debug_return_type] || 'Hash<String, Object>'
|
|
58
|
-
|
|
59
|
-
# auth_names
|
|
60
|
-
auth_names = opts[:debug_auth_names] || []
|
|
61
|
-
|
|
62
|
-
new_options = opts.merge(
|
|
63
|
-
:operation => :"HealthApi.get_atlas_health",
|
|
64
|
-
:header_params => header_params,
|
|
65
|
-
:query_params => query_params,
|
|
66
|
-
:form_params => form_params,
|
|
67
|
-
:body => post_body,
|
|
68
|
-
:auth_names => auth_names,
|
|
69
|
-
:return_type => return_type
|
|
70
|
-
)
|
|
71
|
-
|
|
72
|
-
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
73
|
-
if @api_client.config.debugging
|
|
74
|
-
@api_client.config.logger.debug "API called: HealthApi#get_atlas_health\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
75
|
-
end
|
|
76
|
-
return data, status_code, headers
|
|
77
|
-
end
|
|
78
|
-
|
|
79
22
|
# API-key authentication path health
|
|
80
23
|
# Component-level probe. `GET /v1/health` reports the API as a whole; this reports one dependency so an incident can be localised without guessing.
|
|
81
24
|
# @param [Hash] opts the optional parameters
|