repull 0.2.56 → 0.2.58

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.
Files changed (69) hide show
  1. checksums.yaml +4 -4
  2. data/lib/repull/api/airbnb_api.rb +539 -2
  3. data/lib/repull/api/connect_api.rb +139 -8
  4. data/lib/repull/api/listings_api.rb +70 -0
  5. data/lib/repull/api/vrbo_api.rb +706 -0
  6. data/lib/repull/models/app_connection_health.rb +301 -0
  7. data/lib/repull/models/app_connection_health_recent_errors_inner.rb +184 -0
  8. data/lib/repull/models/app_connection_health_writes_per_day_inner.rb +156 -0
  9. data/lib/repull/models/connect_provider.rb +2 -2
  10. data/lib/repull/models/connect_status.rb +1 -1
  11. data/lib/repull/models/connection.rb +81 -5
  12. data/lib/repull/models/create_connection_request.rb +10 -1
  13. data/lib/repull/models/create_connection_request_workspace.rb +203 -0
  14. data/lib/repull/models/create_price_labs_key201_response.rb +399 -0
  15. data/lib/repull/models/create_price_labs_key201_response_all_of_instructions.rb +159 -0
  16. data/lib/repull/models/create_price_labs_key_request.rb +207 -0
  17. data/lib/repull/models/create_vrbo_offer201_response.rb +104 -0
  18. data/lib/repull/models/create_vrbo_offer201_response_one_of.rb +175 -0
  19. data/lib/repull/models/create_vrbo_offer_request.rb +320 -0
  20. data/lib/repull/models/create_vrbo_offer_request_fees_inner.rb +199 -0
  21. data/lib/repull/models/create_vrbo_offer_request_guest_details.rb +278 -0
  22. data/lib/repull/models/get_airbnb_house_rules200_response.rb +190 -0
  23. data/lib/repull/models/get_airbnb_house_rules200_response_data.rb +247 -0
  24. data/lib/repull/models/get_airbnb_house_rules200_response_data_children.rb +148 -0
  25. data/lib/repull/models/get_airbnb_house_rules200_response_data_house_rules_inner.rb +168 -0
  26. data/lib/repull/models/get_airbnb_listing_cancellation200_response.rb +190 -0
  27. data/lib/repull/models/get_airbnb_listing_cancellation200_response_data.rb +203 -0
  28. data/lib/repull/models/get_airbnb_listing_cancellation200_response_data_non_refundable.rb +192 -0
  29. data/lib/repull/models/get_airbnb_listing_fees200_response.rb +192 -0
  30. data/lib/repull/models/get_airbnb_listing_fees200_response_data_inner.rb +251 -0
  31. data/lib/repull/models/get_airbnb_listing_taxes200_response.rb +192 -0
  32. data/lib/repull/models/get_airbnb_listing_taxes200_response_data_inner.rb +181 -0
  33. data/lib/repull/models/get_airbnb_location200_response.rb +190 -0
  34. data/lib/repull/models/get_airbnb_location200_response_data.rb +197 -0
  35. data/lib/repull/models/get_airbnb_location200_response_data_address.rb +198 -0
  36. data/lib/repull/models/get_price_labs_session_status200_response.rb +192 -0
  37. data/lib/repull/models/get_vrbo_listing200_response_data_inner.rb +1 -1
  38. data/lib/repull/models/get_vrbo_listing_settings200_response.rb +217 -0
  39. data/lib/repull/models/get_vrbo_listing_settings200_response_data.rb +106 -0
  40. data/lib/repull/models/get_vrbo_listing_settings200_response_data_one_of.rb +149 -0
  41. data/lib/repull/models/get_vrbo_offer200_response.rb +290 -0
  42. data/lib/repull/models/get_vrbo_offer200_response_fees_inner.rb +166 -0
  43. data/lib/repull/models/get_vrbo_thread200_response.rb +159 -0
  44. data/lib/repull/models/list_vrbo_thread_messages200_response.rb +170 -0
  45. data/lib/repull/models/list_vrbo_thread_messages200_response_data_inner.rb +240 -0
  46. data/lib/repull/models/list_vrbo_threads200_response.rb +172 -0
  47. data/lib/repull/models/list_vrbo_threads200_response_data_inner.rb +219 -0
  48. data/lib/repull/models/map_vrbo_listing_request.rb +1 -1
  49. data/lib/repull/models/pull_listing_from_vrbo200_response.rb +273 -0
  50. data/lib/repull/models/pull_listing_from_vrbo_request.rb +149 -0
  51. data/lib/repull/models/send_vrbo_message_request.rb +186 -0
  52. data/lib/repull/models/submit_vrbo_guest_review200_response.rb +176 -0
  53. data/lib/repull/models/submit_vrbo_guest_review_request.rb +195 -0
  54. data/lib/repull/models/submit_vrbo_guest_review_request_category_ratings_inner.rb +218 -0
  55. data/lib/repull/models/update_airbnb_house_rules200_response.rb +187 -0
  56. data/lib/repull/models/update_airbnb_house_rules_request.rb +191 -0
  57. data/lib/repull/models/update_airbnb_listing_cancellation200_response.rb +147 -0
  58. data/lib/repull/models/update_airbnb_listing_cancellation200_response_data.rb +158 -0
  59. data/lib/repull/models/update_airbnb_listing_cancellation_request.rb +201 -0
  60. data/lib/repull/models/update_airbnb_listing_cancellation_request_non_refundable.rb +182 -0
  61. data/lib/repull/models/update_airbnb_listing_fees200_response.rb +150 -0
  62. data/lib/repull/models/update_airbnb_listing_fees_request.rb +175 -0
  63. data/lib/repull/models/vrbo_login200_response.rb +2 -2
  64. data/lib/repull/models/vrbo_login_request.rb +13 -3
  65. data/lib/repull/models/withdraw_vrbo_offer200_response.rb +165 -0
  66. data/lib/repull/version.rb +1 -1
  67. data/lib/repull.rb +52 -0
  68. data/openapi/v1.json +3348 -201
  69. metadata +54 -2
@@ -156,7 +156,7 @@ module Repull
156
156
  end
157
157
 
158
158
  # Connect to PMS/OTA provider
159
- # Establish a connection to a PMS or OTA platform. Credentials vary by provider — see docs for each provider. Airbnb-specific: pass `redirectUrl` (where to send the user after consent) and optionally `accessType`. Three tiers: `read_only` grants read-only scopes; `messaging` (shown to hosts as \"Messaging & reviews\") grants read scopes plus message read/send and review writes (reply to guest reviews, submit host reviews — Airbnb's `reviews_write`) but NOT property management, so it can coexist with another app (e.g. an existing PMS) that already holds property management on the same Airbnb account; `full_access` — the default — grants full host scopes including the exclusive property management (only one app per Airbnb account can hold it). The response returns a hosted `url` to redirect the user to. Booking.com: pass `redirectUrl` (no `accessType`). The response returns a hosted `url` — send the user there to select our connectivity provider in their Booking.com Extranet and paste their Hotel ID. Same response shape as Airbnb (`url`, `sessionId`, `expiresAt`). PMS providers are not connected by this call: send their credentials to `POST /v1/connect/{provider}/credentials`, or start a hosted session with `POST /v1/connect`.
159
+ # Establish a connection to a PMS or OTA platform. Credentials vary by provider — see docs for each provider. Airbnb-specific: pass `redirectUrl` (where to send the user after consent) and optionally `accessType`. Three tiers: `read_only` grants read-only scopes; `messaging` (shown to hosts as \"Messaging & reviews\") grants read scopes plus message read/send and review writes (reply to guest reviews, submit host reviews — Airbnb's `reviews_write`) but NOT property management, so it can coexist with another app (e.g. an existing PMS) that already holds property management on the same Airbnb account; `full_access` — the default — grants full host scopes including the exclusive property management (only one app per Airbnb account can hold it). The response returns a hosted `url` to redirect the user to. Booking.com: pass `redirectUrl` (no `accessType`). The response returns a hosted `url` — send the user there to select our connectivity provider in their Booking.com Extranet and paste their Hotel ID. Same response shape as Airbnb (`url`, `sessionId`, `expiresAt`). PMS providers are not connected by this call: send their credentials to `POST /v1/connect/{provider}/credentials`, or start a hosted session with `POST /v1/connect`. **PriceLabs (an app).** Pass `redirectUrl` (and optionally `state`, `locale`, `workspace`). The response returns a hosted `url` for the session's workspace: yours, the one `X-Workspace-Id` names, or a new sub-workspace when you send `workspace.name` (its id comes back as `workspaceId`). The page shows the host a key for **every listing of that workspace, including listings added later**, with the steps to paste it into PriceLabs, then waits for PriceLabs' first call and completes like every provider: redirect to `redirectUrl` (`status=connected&connectionId=…`) or the `repull:connect:completed` popup message, and `connect.session.completed`. When PriceLabs first uses the key, `account.created` is sent. To keep PriceLabs away from the rest of an account, put the listings it should price in a sub-workspace and connect PriceLabs there. To issue the key yourself (no hosted page, or only some listings) use `POST /v1/connect/pricelabs/key`.
160
160
  # @param provider [String] PMS provider slug (e.g., hostaway, guesty, ownerrez)
161
161
  # @param [Hash] opts the optional parameters
162
162
  # @option opts [CreateConnectionRequest] :create_connection_request
@@ -167,7 +167,7 @@ module Repull
167
167
  end
168
168
 
169
169
  # Connect to PMS/OTA provider
170
- # Establish a connection to a PMS or OTA platform. Credentials vary by provider — see docs for each provider. Airbnb-specific: pass `redirectUrl` (where to send the user after consent) and optionally `accessType`. Three tiers: `read_only` grants read-only scopes; `messaging` (shown to hosts as \"Messaging & reviews\") grants read scopes plus message read/send and review writes (reply to guest reviews, submit host reviews — Airbnb's `reviews_write`) but NOT property management, so it can coexist with another app (e.g. an existing PMS) that already holds property management on the same Airbnb account; `full_access` — the default — grants full host scopes including the exclusive property management (only one app per Airbnb account can hold it). The response returns a hosted `url` to redirect the user to. Booking.com: pass `redirectUrl` (no `accessType`). The response returns a hosted `url` — send the user there to select our connectivity provider in their Booking.com Extranet and paste their Hotel ID. Same response shape as Airbnb (`url`, `sessionId`, `expiresAt`). PMS providers are not connected by this call: send their credentials to `POST /v1/connect/{provider}/credentials`, or start a hosted session with `POST /v1/connect`.
170
+ # Establish a connection to a PMS or OTA platform. Credentials vary by provider — see docs for each provider. Airbnb-specific: pass `redirectUrl` (where to send the user after consent) and optionally `accessType`. Three tiers: `read_only` grants read-only scopes; `messaging` (shown to hosts as \"Messaging & reviews\") grants read scopes plus message read/send and review writes (reply to guest reviews, submit host reviews — Airbnb's `reviews_write`) but NOT property management, so it can coexist with another app (e.g. an existing PMS) that already holds property management on the same Airbnb account; `full_access` — the default — grants full host scopes including the exclusive property management (only one app per Airbnb account can hold it). The response returns a hosted `url` to redirect the user to. Booking.com: pass `redirectUrl` (no `accessType`). The response returns a hosted `url` — send the user there to select our connectivity provider in their Booking.com Extranet and paste their Hotel ID. Same response shape as Airbnb (`url`, `sessionId`, `expiresAt`). PMS providers are not connected by this call: send their credentials to `POST /v1/connect/{provider}/credentials`, or start a hosted session with `POST /v1/connect`. **PriceLabs (an app).** Pass `redirectUrl` (and optionally `state`, `locale`, `workspace`). The response returns a hosted `url` for the session's workspace: yours, the one `X-Workspace-Id` names, or a new sub-workspace when you send `workspace.name` (its id comes back as `workspaceId`). The page shows the host a key for **every listing of that workspace, including listings added later**, with the steps to paste it into PriceLabs, then waits for PriceLabs' first call and completes like every provider: redirect to `redirectUrl` (`status=connected&connectionId=…`) or the `repull:connect:completed` popup message, and `connect.session.completed`. When PriceLabs first uses the key, `account.created` is sent. To keep PriceLabs away from the rest of an account, put the listings it should price in a sub-workspace and connect PriceLabs there. To issue the key yourself (no hosted page, or only some listings) use `POST /v1/connect/pricelabs/key`.
171
171
  # @param provider [String] PMS provider slug (e.g., hostaway, guesty, ownerrez)
172
172
  # @param [Hash] opts the optional parameters
173
173
  # @option opts [CreateConnectionRequest] :create_connection_request
@@ -225,11 +225,76 @@ module Repull
225
225
  return data, status_code, headers
226
226
  end
227
227
 
228
+ # Create a PriceLabs key (headless)
229
+ # Issue a PriceLabs key without the hosted page, for platforms that show it in their own app. The key is for this workspace, or the one `X-Workspace-Id` names; it is returned once, in `key`, and the host pastes it into PriceLabs (add an integration, choose Repull). - No `listingIds`: every listing of the workspace, including listings added later. Recommended, with the listings PriceLabs should price in their own sub-workspace. - `listingIds`: only those listings (they must belong to the workspace). Listings added later are not included. The key works only inside PriceLabs; it is refused on every Repull API endpoint. The connection appears on `GET /v1/connect/pricelabs` with its `health`; `account.created` is sent when PriceLabs first uses the key. Revoke it with `DELETE /v1/connect/pricelabs?id=`.
230
+ # @param [Hash] opts the optional parameters
231
+ # @option opts [CreatePriceLabsKeyRequest] :create_price_labs_key_request
232
+ # @return [CreatePriceLabsKey201Response]
233
+ def create_price_labs_key(opts = {})
234
+ data, _status_code, _headers = create_price_labs_key_with_http_info(opts)
235
+ data
236
+ end
237
+
238
+ # Create a PriceLabs key (headless)
239
+ # Issue a PriceLabs key without the hosted page, for platforms that show it in their own app. The key is for this workspace, or the one `X-Workspace-Id` names; it is returned once, in `key`, and the host pastes it into PriceLabs (add an integration, choose Repull). - No `listingIds`: every listing of the workspace, including listings added later. Recommended, with the listings PriceLabs should price in their own sub-workspace. - `listingIds`: only those listings (they must belong to the workspace). Listings added later are not included. The key works only inside PriceLabs; it is refused on every Repull API endpoint. The connection appears on `GET /v1/connect/pricelabs` with its `health`; `account.created` is sent when PriceLabs first uses the key. Revoke it with `DELETE /v1/connect/pricelabs?id=`.
240
+ # @param [Hash] opts the optional parameters
241
+ # @option opts [CreatePriceLabsKeyRequest] :create_price_labs_key_request
242
+ # @return [Array<(CreatePriceLabsKey201Response, Integer, Hash)>] CreatePriceLabsKey201Response data, response status code and response headers
243
+ def create_price_labs_key_with_http_info(opts = {})
244
+ if @api_client.config.debugging
245
+ @api_client.config.logger.debug 'Calling API: ConnectApi.create_price_labs_key ...'
246
+ end
247
+ # resource path
248
+ local_var_path = '/v1/connect/pricelabs/key'
249
+
250
+ # query parameters
251
+ query_params = opts[:query_params] || {}
252
+
253
+ # header parameters
254
+ header_params = opts[:header_params] || {}
255
+ # HTTP header 'Accept' (if needed)
256
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
257
+ # HTTP header 'Content-Type'
258
+ content_type = @api_client.select_header_content_type(['application/json'])
259
+ if !content_type.nil?
260
+ header_params['Content-Type'] = content_type
261
+ end
262
+
263
+ # form parameters
264
+ form_params = opts[:form_params] || {}
265
+
266
+ # http body (model)
267
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'create_price_labs_key_request'])
268
+
269
+ # return_type
270
+ return_type = opts[:debug_return_type] || 'CreatePriceLabsKey201Response'
271
+
272
+ # auth_names
273
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
274
+
275
+ new_options = opts.merge(
276
+ :operation => :"ConnectApi.create_price_labs_key",
277
+ :header_params => header_params,
278
+ :query_params => query_params,
279
+ :form_params => form_params,
280
+ :body => post_body,
281
+ :auth_names => auth_names,
282
+ :return_type => return_type
283
+ )
284
+
285
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
286
+ if @api_client.config.debugging
287
+ @api_client.config.logger.debug "API called: ConnectApi#create_price_labs_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
288
+ end
289
+ return data, status_code, headers
290
+ end
291
+
228
292
  # Disconnect provider
229
- # Disconnect ONE connected account of a provider from this workspace. Supported for `airbnb`, `booking`, `vrbo-login` and every PMS (`guesty`, `hostaway`, `hospitable`, …). **Which account.** Pass `accountId` — for Airbnb the host id (`accounts[].externalAccountId` from `GET /v1/connect/airbnb`), for Booking.com the hotel id, for `vrbo-login` the sign-in's Vrbo account id (`accounts[].externalAccountId` from `GET /v1/connect/vrbo-login`; the old sign-in id still works until 2027-02-12). It is optional only when the workspace has exactly one account for the provider. With several and no `accountId`, the call returns `422` with the account ids in `valid_values` instead of guessing. An `accountId` that is not connected to this workspace returns `404`. Disconnecting one account leaves the others connected. **What happens.** The account's stored authorization is removed and it stops syncing. Its listings are **deactivated**, not deleted: they stop counting toward your plan's listing limit, their data is kept, and they are returned in `listingsDeactivated`. A listing that is still connected through another account or channel stays active. Reconnect the account, then activate the listings with `POST /v1/listings/status`. The change is all or nothing. For Airbnb, the host can also revoke access on Airbnb's side (Account → Privacy & sharing → Connected apps); that alone does not update this workspace, so call this endpoint as well. **PMS.** A workspace has one connection per PMS, so no `accountId` is needed. Disconnecting stops syncing, clears the stored credentials and deactivates the connection's listings; nothing is deleted, and reservations and messages stay. The response also carries `connectionId`. The PMS's own webhook subscription is left in place, because the same PMS account can be connected to another workspace (such as a Repull Migrate workspace). Reconnect with a new Connect session. Other providers return `501 not_implemented` with instructions for disconnecting on the provider's side. That answer depends only on the provider, not on your workspace: an unsupported provider returns `501` whether or not you have a connection to it. `404 not_found` on a supported provider means this workspace has no connection to it (or, with `accountId`, that the account is not connected here).
293
+ # Disconnect ONE connected account of a provider from this workspace. Supported for `airbnb`, `booking`, `vrbo-login` and every PMS (`guesty`, `hostaway`, `hospitable`, …). **Which account.** Pass `accountId` — for Airbnb the host id (`accounts[].externalAccountId` from `GET /v1/connect/airbnb`), for Booking.com the hotel id, for `vrbo-login` the sign-in's Vrbo account id (`accounts[].externalAccountId` from `GET /v1/connect/vrbo-login`; the old sign-in id still works until 2027-02-12). It is optional only when the workspace has exactly one account for the provider. With several and no `accountId`, the call returns `422` with the account ids in `valid_values` instead of guessing. An `accountId` that is not connected to this workspace returns `404`. Disconnecting one account leaves the others connected. **What happens.** The account's stored authorization is removed and it stops syncing. Its listings are **deactivated**, not deleted: they stop counting toward your plan's listing limit, their data is kept, and they are returned in `listingsDeactivated`. A listing that is still connected through another account or channel stays active. Reconnect the account, then activate the listings with `POST /v1/listings/status`. The change is all or nothing. For Airbnb, the host can also revoke access on Airbnb's side (Account → Privacy & sharing → Connected apps); that alone does not update this workspace, so call this endpoint as well. **PMS.** A workspace has one connection per PMS, so no `accountId` is needed. Disconnecting stops syncing, clears the stored credentials and deactivates the connection's listings; nothing is deleted, and reservations and messages stay. The response also carries `connectionId`. The PMS's own webhook subscription is left in place, because the same PMS account can be connected to another workspace (such as a Repull Migrate workspace). Reconnect with a new Connect session. Other providers return `501 not_implemented` with instructions for disconnecting on the provider's side. That answer depends only on the provider, not on your workspace: an unsupported provider returns `501` whether or not you have a connection to it. `404 not_found` on a supported provider means this workspace has no connection to it (or, with `accountId`, that the account is not connected here). **PriceLabs (an app).** Revokes one PriceLabs connection (its key): PriceLabs loses access at once; nothing it already pushed changes and no listing is deactivated. Pass `id` (an `accounts[].id` from `GET /v1/connect/pricelabs`); it is optional only when the workspace has one connected. Sends `account.disconnected` with reason `manual_disconnect`.
230
294
  # @param provider [String] PMS provider slug (e.g., hostaway, guesty, ownerrez)
231
295
  # @param [Hash] opts the optional parameters
232
296
  # @option opts [String] :account_id The account to disconnect: the Airbnb host id (&#x60;accounts[].externalAccountId&#x60; on &#x60;GET /v1/connect/airbnb&#x60;) or the Booking.com hotel id. Required when the workspace has more than one connected account for the provider. Not the same as the &#x60;X-Account-Id&#x60; header.
297
+ # @option opts [String] :id PriceLabs only: the connection to revoke (&#x60;accounts[].id&#x60; on &#x60;GET /v1/connect/pricelabs&#x60;). Required when the workspace has more than one.
233
298
  # @return [DeleteConnection200Response]
234
299
  def delete_connection(provider, opts = {})
235
300
  data, _status_code, _headers = delete_connection_with_http_info(provider, opts)
@@ -237,10 +302,11 @@ module Repull
237
302
  end
238
303
 
239
304
  # Disconnect provider
240
- # Disconnect ONE connected account of a provider from this workspace. Supported for &#x60;airbnb&#x60;, &#x60;booking&#x60;, &#x60;vrbo-login&#x60; and every PMS (&#x60;guesty&#x60;, &#x60;hostaway&#x60;, &#x60;hospitable&#x60;, …). **Which account.** Pass &#x60;accountId&#x60; — for Airbnb the host id (&#x60;accounts[].externalAccountId&#x60; from &#x60;GET /v1/connect/airbnb&#x60;), for Booking.com the hotel id, for &#x60;vrbo-login&#x60; the sign-in&#39;s Vrbo account id (&#x60;accounts[].externalAccountId&#x60; from &#x60;GET /v1/connect/vrbo-login&#x60;; the old sign-in id still works until 2027-02-12). It is optional only when the workspace has exactly one account for the provider. With several and no &#x60;accountId&#x60;, the call returns &#x60;422&#x60; with the account ids in &#x60;valid_values&#x60; instead of guessing. An &#x60;accountId&#x60; that is not connected to this workspace returns &#x60;404&#x60;. Disconnecting one account leaves the others connected. **What happens.** The account&#39;s stored authorization is removed and it stops syncing. Its listings are **deactivated**, not deleted: they stop counting toward your plan&#39;s listing limit, their data is kept, and they are returned in &#x60;listingsDeactivated&#x60;. A listing that is still connected through another account or channel stays active. Reconnect the account, then activate the listings with &#x60;POST /v1/listings/status&#x60;. The change is all or nothing. For Airbnb, the host can also revoke access on Airbnb&#39;s side (Account → Privacy &amp; sharing → Connected apps); that alone does not update this workspace, so call this endpoint as well. **PMS.** A workspace has one connection per PMS, so no &#x60;accountId&#x60; is needed. Disconnecting stops syncing, clears the stored credentials and deactivates the connection&#39;s listings; nothing is deleted, and reservations and messages stay. The response also carries &#x60;connectionId&#x60;. The PMS&#39;s own webhook subscription is left in place, because the same PMS account can be connected to another workspace (such as a Repull Migrate workspace). Reconnect with a new Connect session. Other providers return &#x60;501 not_implemented&#x60; with instructions for disconnecting on the provider&#39;s side. That answer depends only on the provider, not on your workspace: an unsupported provider returns &#x60;501&#x60; whether or not you have a connection to it. &#x60;404 not_found&#x60; on a supported provider means this workspace has no connection to it (or, with &#x60;accountId&#x60;, that the account is not connected here).
305
+ # Disconnect ONE connected account of a provider from this workspace. Supported for &#x60;airbnb&#x60;, &#x60;booking&#x60;, &#x60;vrbo-login&#x60; and every PMS (&#x60;guesty&#x60;, &#x60;hostaway&#x60;, &#x60;hospitable&#x60;, …). **Which account.** Pass &#x60;accountId&#x60; — for Airbnb the host id (&#x60;accounts[].externalAccountId&#x60; from &#x60;GET /v1/connect/airbnb&#x60;), for Booking.com the hotel id, for &#x60;vrbo-login&#x60; the sign-in&#39;s Vrbo account id (&#x60;accounts[].externalAccountId&#x60; from &#x60;GET /v1/connect/vrbo-login&#x60;; the old sign-in id still works until 2027-02-12). It is optional only when the workspace has exactly one account for the provider. With several and no &#x60;accountId&#x60;, the call returns &#x60;422&#x60; with the account ids in &#x60;valid_values&#x60; instead of guessing. An &#x60;accountId&#x60; that is not connected to this workspace returns &#x60;404&#x60;. Disconnecting one account leaves the others connected. **What happens.** The account&#39;s stored authorization is removed and it stops syncing. Its listings are **deactivated**, not deleted: they stop counting toward your plan&#39;s listing limit, their data is kept, and they are returned in &#x60;listingsDeactivated&#x60;. A listing that is still connected through another account or channel stays active. Reconnect the account, then activate the listings with &#x60;POST /v1/listings/status&#x60;. The change is all or nothing. For Airbnb, the host can also revoke access on Airbnb&#39;s side (Account → Privacy &amp; sharing → Connected apps); that alone does not update this workspace, so call this endpoint as well. **PMS.** A workspace has one connection per PMS, so no &#x60;accountId&#x60; is needed. Disconnecting stops syncing, clears the stored credentials and deactivates the connection&#39;s listings; nothing is deleted, and reservations and messages stay. The response also carries &#x60;connectionId&#x60;. The PMS&#39;s own webhook subscription is left in place, because the same PMS account can be connected to another workspace (such as a Repull Migrate workspace). Reconnect with a new Connect session. Other providers return &#x60;501 not_implemented&#x60; with instructions for disconnecting on the provider&#39;s side. That answer depends only on the provider, not on your workspace: an unsupported provider returns &#x60;501&#x60; whether or not you have a connection to it. &#x60;404 not_found&#x60; on a supported provider means this workspace has no connection to it (or, with &#x60;accountId&#x60;, that the account is not connected here). **PriceLabs (an app).** Revokes one PriceLabs connection (its key): PriceLabs loses access at once; nothing it already pushed changes and no listing is deactivated. Pass &#x60;id&#x60; (an &#x60;accounts[].id&#x60; from &#x60;GET /v1/connect/pricelabs&#x60;); it is optional only when the workspace has one connected. Sends &#x60;account.disconnected&#x60; with reason &#x60;manual_disconnect&#x60;.
241
306
  # @param provider [String] PMS provider slug (e.g., hostaway, guesty, ownerrez)
242
307
  # @param [Hash] opts the optional parameters
243
308
  # @option opts [String] :account_id The account to disconnect: the Airbnb host id (&#x60;accounts[].externalAccountId&#x60; on &#x60;GET /v1/connect/airbnb&#x60;) or the Booking.com hotel id. Required when the workspace has more than one connected account for the provider. Not the same as the &#x60;X-Account-Id&#x60; header.
309
+ # @option opts [String] :id PriceLabs only: the connection to revoke (&#x60;accounts[].id&#x60; on &#x60;GET /v1/connect/pricelabs&#x60;). Required when the workspace has more than one.
244
310
  # @return [Array<(DeleteConnection200Response, Integer, Hash)>] DeleteConnection200Response data, response status code and response headers
245
311
  def delete_connection_with_http_info(provider, opts = {})
246
312
  if @api_client.config.debugging
@@ -256,6 +322,7 @@ module Repull
256
322
  # query parameters
257
323
  query_params = opts[:query_params] || {}
258
324
  query_params[:'accountId'] = opts[:'account_id'] if !opts[:'account_id'].nil?
325
+ query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil?
259
326
 
260
327
  # header parameters
261
328
  header_params = opts[:header_params] || {}
@@ -427,7 +494,7 @@ module Repull
427
494
  end
428
495
 
429
496
  # Get connection status
430
- # Returns the current connection status for a provider, including host metadata (display name + avatar) for Airbnb so clients can render an account-level confirmation UI. **Access level.** `accessType` says what the connection may do: `read_only`, `messaging` or `full_access` (`null` when unknown). Airbnb reports it per host on `accounts[]` (the tier each host's token was granted with) and at the top level for the host in `externalAccountId`; Vrbo (`vrbo-login`) per account; Booking.com is always `full_access`, the Booking.com Extranet always `messaging`; a PMS is `read_only` when every `writePolicy` switch is off, else `full_access`. See the `ConnectionAccessType` schema for the meaning per provider.
497
+ # Returns the current connection status for a provider, including host metadata (display name + avatar) for Airbnb so clients can render an account-level confirmation UI. **Access level.** `accessType` says what the connection may do: `read_only`, `messaging` or `full_access` (`null` when unknown). Airbnb reports it per host on `accounts[]` (the tier each host's token was granted with) and at the top level for the host in `externalAccountId`; Vrbo (`vrbo-login`) per account; Booking.com is always `full_access`, the Booking.com Extranet always `messaging`; a PMS is `read_only` when every `writePolicy` switch is off, else `full_access`. See the `ConnectionAccessType` schema for the meaning per provider. **PriceLabs (an app).** `accounts[]` lists every PriceLabs connection of the workspace (each one key), with `scope`, `listingCount`, `keyMasked` and `health`: `status` (`active`, `idle`, `failing`, `never_connected`), last request, last successful price push, pushes per day for 7 days, error rates and the latest errors. Revoked ones stay listed as `disconnected` with `health: null`. `externalAccountId` is `null` (PriceLabs has no account id to give us); `id` is the connection.
431
498
  # @param provider [String] PMS provider slug (e.g., hostaway, guesty, ownerrez)
432
499
  # @param [Hash] opts the optional parameters
433
500
  # @return [ConnectStatus]
@@ -437,7 +504,7 @@ module Repull
437
504
  end
438
505
 
439
506
  # Get connection status
440
- # Returns the current connection status for a provider, including host metadata (display name + avatar) for Airbnb so clients can render an account-level confirmation UI. **Access level.** &#x60;accessType&#x60; says what the connection may do: &#x60;read_only&#x60;, &#x60;messaging&#x60; or &#x60;full_access&#x60; (&#x60;null&#x60; when unknown). Airbnb reports it per host on &#x60;accounts[]&#x60; (the tier each host&#39;s token was granted with) and at the top level for the host in &#x60;externalAccountId&#x60;; Vrbo (&#x60;vrbo-login&#x60;) per account; Booking.com is always &#x60;full_access&#x60;, the Booking.com Extranet always &#x60;messaging&#x60;; a PMS is &#x60;read_only&#x60; when every &#x60;writePolicy&#x60; switch is off, else &#x60;full_access&#x60;. See the &#x60;ConnectionAccessType&#x60; schema for the meaning per provider.
507
+ # Returns the current connection status for a provider, including host metadata (display name + avatar) for Airbnb so clients can render an account-level confirmation UI. **Access level.** &#x60;accessType&#x60; says what the connection may do: &#x60;read_only&#x60;, &#x60;messaging&#x60; or &#x60;full_access&#x60; (&#x60;null&#x60; when unknown). Airbnb reports it per host on &#x60;accounts[]&#x60; (the tier each host&#39;s token was granted with) and at the top level for the host in &#x60;externalAccountId&#x60;; Vrbo (&#x60;vrbo-login&#x60;) per account; Booking.com is always &#x60;full_access&#x60;, the Booking.com Extranet always &#x60;messaging&#x60;; a PMS is &#x60;read_only&#x60; when every &#x60;writePolicy&#x60; switch is off, else &#x60;full_access&#x60;. See the &#x60;ConnectionAccessType&#x60; schema for the meaning per provider. **PriceLabs (an app).** &#x60;accounts[]&#x60; lists every PriceLabs connection of the workspace (each one key), with &#x60;scope&#x60;, &#x60;listingCount&#x60;, &#x60;keyMasked&#x60; and &#x60;health&#x60;: &#x60;status&#x60; (&#x60;active&#x60;, &#x60;idle&#x60;, &#x60;failing&#x60;, &#x60;never_connected&#x60;), last request, last successful price push, pushes per day for 7 days, error rates and the latest errors. Revoked ones stay listed as &#x60;disconnected&#x60; with &#x60;health: null&#x60;. &#x60;externalAccountId&#x60; is &#x60;null&#x60; (PriceLabs has no account id to give us); &#x60;id&#x60; is the connection.
441
508
  # @param provider [String] PMS provider slug (e.g., hostaway, guesty, ownerrez)
442
509
  # @param [Hash] opts the optional parameters
443
510
  # @return [Array<(ConnectStatus, Integer, Hash)>] ConnectStatus data, response status code and response headers
@@ -552,6 +619,70 @@ module Repull
552
619
  return data, status_code, headers
553
620
  end
554
621
 
622
+ # PriceLabs session status
623
+ # Where a hosted PriceLabs session stands: `pending` (no key issued yet), `waiting` (the key is shown, PriceLabs has not called yet), `connected` (PriceLabs has called with the key; the session is complete) or `expired`. Called by the hosted Connect page while it waits. No API key — the session ID is the capability token.
624
+ # @param session_id [String]
625
+ # @param [Hash] opts the optional parameters
626
+ # @return [GetPriceLabsSessionStatus200Response]
627
+ def get_price_labs_session_status(session_id, opts = {})
628
+ data, _status_code, _headers = get_price_labs_session_status_with_http_info(session_id, opts)
629
+ data
630
+ end
631
+
632
+ # PriceLabs session status
633
+ # Where a hosted PriceLabs session stands: &#x60;pending&#x60; (no key issued yet), &#x60;waiting&#x60; (the key is shown, PriceLabs has not called yet), &#x60;connected&#x60; (PriceLabs has called with the key; the session is complete) or &#x60;expired&#x60;. Called by the hosted Connect page while it waits. No API key — the session ID is the capability token.
634
+ # @param session_id [String]
635
+ # @param [Hash] opts the optional parameters
636
+ # @return [Array<(GetPriceLabsSessionStatus200Response, Integer, Hash)>] GetPriceLabsSessionStatus200Response data, response status code and response headers
637
+ def get_price_labs_session_status_with_http_info(session_id, opts = {})
638
+ if @api_client.config.debugging
639
+ @api_client.config.logger.debug 'Calling API: ConnectApi.get_price_labs_session_status ...'
640
+ end
641
+ # verify the required parameter 'session_id' is set
642
+ if @api_client.config.client_side_validation && session_id.nil?
643
+ fail ArgumentError, "Missing the required parameter 'session_id' when calling ConnectApi.get_price_labs_session_status"
644
+ end
645
+ # resource path
646
+ local_var_path = '/v1/connect/pricelabs/session'
647
+
648
+ # query parameters
649
+ query_params = opts[:query_params] || {}
650
+ query_params[:'sessionId'] = session_id
651
+
652
+ # header parameters
653
+ header_params = opts[:header_params] || {}
654
+ # HTTP header 'Accept' (if needed)
655
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
656
+
657
+ # form parameters
658
+ form_params = opts[:form_params] || {}
659
+
660
+ # http body (model)
661
+ post_body = opts[:debug_body]
662
+
663
+ # return_type
664
+ return_type = opts[:debug_return_type] || 'GetPriceLabsSessionStatus200Response'
665
+
666
+ # auth_names
667
+ auth_names = opts[:debug_auth_names] || []
668
+
669
+ new_options = opts.merge(
670
+ :operation => :"ConnectApi.get_price_labs_session_status",
671
+ :header_params => header_params,
672
+ :query_params => query_params,
673
+ :form_params => form_params,
674
+ :body => post_body,
675
+ :auth_names => auth_names,
676
+ :return_type => return_type
677
+ )
678
+
679
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
680
+ if @api_client.config.debugging
681
+ @api_client.config.logger.debug "API called: ConnectApi#get_price_labs_session_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
682
+ end
683
+ return data, status_code, headers
684
+ end
685
+
555
686
  # Import progress of the session's Vrbo account
556
687
  # After the mapping is confirmed: `importing` (upcoming bookings and the last 30 days of messages) → `importing_history` (the rest of the account, in the background) → `imported`. Called by the hosted Connect page. No API key — the session ID is the capability token.
557
688
  # @param session_id [String]
@@ -2447,7 +2578,7 @@ module Repull
2447
2578
  end
2448
2579
 
2449
2580
  # Sign in with a Vrbo host account
2450
- # `action: login` checks the email and password and answers in seconds: `connected`, `otp_required` (Vrbo sent a code to `destination`) or `failed` with a `reason` (`bad_credentials`, `blocked`, …). `action: otp` submits the code; a refused code comes back as `otp_required` with `reason: bad_code`. `action: resend` (with `accountId`) signs in again with the details already given, so Vrbo sends a new code. Signing in imports nothing. `accessType` (`full_access` or `messaging`, when the session did not lock it) is the host's choice of whether mapped listings push the calendar. The import starts when the mapping is confirmed. Called by the hosted Connect page. No API key — the session ID is the capability token.
2581
+ # `action: login` checks the email and password and answers in seconds: `connected`, `otp_required` (Vrbo sent a code to `destination`) or `failed` with a `reason` (`bad_credentials`, `blocked`, …). `action: otp` submits the code; a refused code comes back as `otp_required` with `reason: bad_code`. `action: resend` (with `accountId`) signs in again with the details already given, so Vrbo sends a new code. `phone_required` means Vrbo accepted the login and its \"complete your profile\" step wants a contact phone: `action: phone` (with `accountId` and `phone`, international format with the country code, any country) fills it in, then answers like the others (`otp_required` when Vrbo texts a code to that number; `phone_required` with `reason: bad_phone` when Vrbo refuses it). Signing in imports nothing. `accessType` (`full_access` or `messaging`, when the session did not lock it) is the host's choice of whether mapped listings push the calendar. The import starts when the mapping is confirmed. Called by the hosted Connect page. No API key — the session ID is the capability token.
2451
2582
  # @param vrbo_login_request [VrboLoginRequest]
2452
2583
  # @param [Hash] opts the optional parameters
2453
2584
  # @return [VrboLogin200Response]
@@ -2457,7 +2588,7 @@ module Repull
2457
2588
  end
2458
2589
 
2459
2590
  # Sign in with a Vrbo host account
2460
- # &#x60;action: login&#x60; checks the email and password and answers in seconds: &#x60;connected&#x60;, &#x60;otp_required&#x60; (Vrbo sent a code to &#x60;destination&#x60;) or &#x60;failed&#x60; with a &#x60;reason&#x60; (&#x60;bad_credentials&#x60;, &#x60;blocked&#x60;, …). &#x60;action: otp&#x60; submits the code; a refused code comes back as &#x60;otp_required&#x60; with &#x60;reason: bad_code&#x60;. &#x60;action: resend&#x60; (with &#x60;accountId&#x60;) signs in again with the details already given, so Vrbo sends a new code. Signing in imports nothing. &#x60;accessType&#x60; (&#x60;full_access&#x60; or &#x60;messaging&#x60;, when the session did not lock it) is the host&#39;s choice of whether mapped listings push the calendar. The import starts when the mapping is confirmed. Called by the hosted Connect page. No API key — the session ID is the capability token.
2591
+ # &#x60;action: login&#x60; checks the email and password and answers in seconds: &#x60;connected&#x60;, &#x60;otp_required&#x60; (Vrbo sent a code to &#x60;destination&#x60;) or &#x60;failed&#x60; with a &#x60;reason&#x60; (&#x60;bad_credentials&#x60;, &#x60;blocked&#x60;, …). &#x60;action: otp&#x60; submits the code; a refused code comes back as &#x60;otp_required&#x60; with &#x60;reason: bad_code&#x60;. &#x60;action: resend&#x60; (with &#x60;accountId&#x60;) signs in again with the details already given, so Vrbo sends a new code. &#x60;phone_required&#x60; means Vrbo accepted the login and its \&quot;complete your profile\&quot; step wants a contact phone: &#x60;action: phone&#x60; (with &#x60;accountId&#x60; and &#x60;phone&#x60;, international format with the country code, any country) fills it in, then answers like the others (&#x60;otp_required&#x60; when Vrbo texts a code to that number; &#x60;phone_required&#x60; with &#x60;reason: bad_phone&#x60; when Vrbo refuses it). Signing in imports nothing. &#x60;accessType&#x60; (&#x60;full_access&#x60; or &#x60;messaging&#x60;, when the session did not lock it) is the host&#39;s choice of whether mapped listings push the calendar. The import starts when the mapping is confirmed. Called by the hosted Connect page. No API key — the session ID is the capability token.
2461
2592
  # @param vrbo_login_request [VrboLoginRequest]
2462
2593
  # @param [Hash] opts the optional parameters
2463
2594
  # @return [Array<(VrboLogin200Response, Integer, Hash)>] VrboLogin200Response data, response status code and response headers
@@ -1276,6 +1276,76 @@ module Repull
1276
1276
  return data, status_code, headers
1277
1277
  end
1278
1278
 
1279
+ # Refresh a listing from Vrbo
1280
+ # Re-read every content section of the listing's Vrbo listing from Vrbo and keep it as Repull's copy, then report what was refreshed and when — the counterpart of `POST /v1/listings/{id}/pull/airbnb`. Use it after the host changed something on Vrbo, so the `/v1/channels/vrbo/listings/{id}/…` reads answer with what Vrbo holds now. **What it refreshes:** descriptions, details, story, additional-info, photos, amenities, rooms, location, house-rules, booking-settings, cancellation, fees, pricing, payment-terms, protection, taxes, permits, checkin-guide, videos. **Not** the calendar, rates per night, bookings, messages, reviews or payouts — those arrive through the channel's own sync. **Runs synchronously:** about 45 Vrbo calls spaced ~3 s apart per account, **around 2.5 minutes**. A section Vrbo fails to return is listed in `failedSections`; the others are refreshed. **One pull per listing per 15 minutes**, as on Airbnb: a second call inside the window returns `429 rate_limit_exceeded` with `Retry-After` and `nextPullAvailableAt`, and makes no Vrbo calls. Works with messaging or full access. Returns `404` when the listing is not linked to Vrbo, and `403 listing_inactive` when the listing is inactive.
1281
+ # @param id [String] Repull listing id (numeric string) of a listing linked to Vrbo.
1282
+ # @param [Hash] opts the optional parameters
1283
+ # @option opts [PullListingFromVrboRequest] :pull_listing_from_vrbo_request
1284
+ # @return [PullListingFromVrbo200Response]
1285
+ def pull_listing_from_vrbo(id, opts = {})
1286
+ data, _status_code, _headers = pull_listing_from_vrbo_with_http_info(id, opts)
1287
+ data
1288
+ end
1289
+
1290
+ # Refresh a listing from Vrbo
1291
+ # Re-read every content section of the listing&#39;s Vrbo listing from Vrbo and keep it as Repull&#39;s copy, then report what was refreshed and when — the counterpart of &#x60;POST /v1/listings/{id}/pull/airbnb&#x60;. Use it after the host changed something on Vrbo, so the &#x60;/v1/channels/vrbo/listings/{id}/…&#x60; reads answer with what Vrbo holds now. **What it refreshes:** descriptions, details, story, additional-info, photos, amenities, rooms, location, house-rules, booking-settings, cancellation, fees, pricing, payment-terms, protection, taxes, permits, checkin-guide, videos. **Not** the calendar, rates per night, bookings, messages, reviews or payouts — those arrive through the channel&#39;s own sync. **Runs synchronously:** about 45 Vrbo calls spaced ~3 s apart per account, **around 2.5 minutes**. A section Vrbo fails to return is listed in &#x60;failedSections&#x60;; the others are refreshed. **One pull per listing per 15 minutes**, as on Airbnb: a second call inside the window returns &#x60;429 rate_limit_exceeded&#x60; with &#x60;Retry-After&#x60; and &#x60;nextPullAvailableAt&#x60;, and makes no Vrbo calls. Works with messaging or full access. Returns &#x60;404&#x60; when the listing is not linked to Vrbo, and &#x60;403 listing_inactive&#x60; when the listing is inactive.
1292
+ # @param id [String] Repull listing id (numeric string) of a listing linked to Vrbo.
1293
+ # @param [Hash] opts the optional parameters
1294
+ # @option opts [PullListingFromVrboRequest] :pull_listing_from_vrbo_request
1295
+ # @return [Array<(PullListingFromVrbo200Response, Integer, Hash)>] PullListingFromVrbo200Response data, response status code and response headers
1296
+ def pull_listing_from_vrbo_with_http_info(id, opts = {})
1297
+ if @api_client.config.debugging
1298
+ @api_client.config.logger.debug 'Calling API: ListingsApi.pull_listing_from_vrbo ...'
1299
+ end
1300
+ # verify the required parameter 'id' is set
1301
+ if @api_client.config.client_side_validation && id.nil?
1302
+ fail ArgumentError, "Missing the required parameter 'id' when calling ListingsApi.pull_listing_from_vrbo"
1303
+ end
1304
+ # resource path
1305
+ local_var_path = '/v1/listings/{id}/pull/vrbo'.sub('{id}', CGI.escape(id.to_s))
1306
+
1307
+ # query parameters
1308
+ query_params = opts[:query_params] || {}
1309
+
1310
+ # header parameters
1311
+ header_params = opts[:header_params] || {}
1312
+ # HTTP header 'Accept' (if needed)
1313
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1314
+ # HTTP header 'Content-Type'
1315
+ content_type = @api_client.select_header_content_type(['application/json'])
1316
+ if !content_type.nil?
1317
+ header_params['Content-Type'] = content_type
1318
+ end
1319
+
1320
+ # form parameters
1321
+ form_params = opts[:form_params] || {}
1322
+
1323
+ # http body (model)
1324
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'pull_listing_from_vrbo_request'])
1325
+
1326
+ # return_type
1327
+ return_type = opts[:debug_return_type] || 'PullListingFromVrbo200Response'
1328
+
1329
+ # auth_names
1330
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
1331
+
1332
+ new_options = opts.merge(
1333
+ :operation => :"ListingsApi.pull_listing_from_vrbo",
1334
+ :header_params => header_params,
1335
+ :query_params => query_params,
1336
+ :form_params => form_params,
1337
+ :body => post_body,
1338
+ :auth_names => auth_names,
1339
+ :return_type => return_type
1340
+ )
1341
+
1342
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1343
+ if @api_client.config.debugging
1344
+ @api_client.config.logger.debug "API called: ListingsApi#pull_listing_from_vrbo\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1345
+ end
1346
+ return data, status_code, headers
1347
+ end
1348
+
1279
1349
  # Set a listing's markup on a channel
1280
1350
  # Set the markup one channel adds to this listing's price. When the value changes, the affected listings' prices are re-sent to that channel straight away (`pricesResent`); nothing else is sent. A listing's price on a channel is its own nightly price plus the channel's markup: a $200 night with a 35% Airbnb markup is sent to Airbnb as $270. The calendar keeps the listing's own price (`GET /v1/availability/{propertyId}` returns it); the markup is added only when a price is sent to the channel. - **Airbnb** — one markup per listing. - **Booking.com** — one markup per **property**, shared by every listing priced through it (`listingIds` names them). - **Vrbo** — one markup per connected **Vrbo account**, shared by every listing linked on it (`listingIds` names them). Prices reach Vrbo through its calendar queue. Returns `404 not_found` for a listing that does not exist or is not in this workspace, and `403 listing_inactive` for an inactive one. On Booking.com the markup belongs to the property, so setting it reprices every listing on that property (`affectedListingIds`). A listing on more than one property must name one with `hotelId`; without it the request is refused with `409 ambiguous_booking_mapping` listing the candidates, rather than repricing a property it guessed. On Vrbo the markup belongs to the connected Vrbo account, so setting it reprices every listing linked on that account (`affectedListingIds`). A listing linked on more than one account names one with `accountId`, else `409 ambiguous_vrbo_account`; a listing not linked to Vrbo is `409 listing_not_on_vrbo`. `markupPercent` is a percentage — `15` for 15%. A value between 0 and 1 is refused as a probable fraction, with the number to send instead.
1281
1351
  # @param id [String] Repull listing id.