repull 0.2.35 → 0.2.36

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 (46) hide show
  1. checksums.yaml +4 -4
  2. data/lib/repull/api/connect_api.rb +2 -2
  3. data/lib/repull/api/listings_api.rb +8 -8
  4. data/lib/repull/api/migrate_api.rb +68 -0
  5. data/lib/repull/models/booking_unacknowledged_event.rb +281 -0
  6. data/lib/repull/models/booking_unacknowledged_payload.rb +229 -0
  7. data/lib/repull/models/channel_degraded_event.rb +279 -0
  8. data/lib/repull/models/channel_degraded_payload.rb +174 -0
  9. data/lib/repull/models/channel_degraded_payload_object.rb +262 -0
  10. data/lib/repull/models/channel_sync_failed_event.rb +280 -0
  11. data/lib/repull/models/channel_sync_failure_payload.rb +214 -0
  12. data/lib/repull/models/channel_sync_failure_payload_failures_inner.rb +213 -0
  13. data/lib/repull/models/channel_sync_failure_payload_object.rb +289 -0
  14. data/lib/repull/models/charge_per.rb +42 -0
  15. data/lib/repull/models/create_connect_session_request.rb +2 -2
  16. data/lib/repull/models/create_connection_request.rb +1 -1
  17. data/lib/repull/models/import_from_channex200_response.rb +147 -0
  18. data/lib/repull/models/import_from_channex200_response_data.rb +324 -0
  19. data/lib/repull/models/import_from_channex200_response_data_channels_inner.rb +263 -0
  20. data/lib/repull/models/import_from_channex200_response_data_properties_inner.rb +222 -0
  21. data/lib/repull/models/import_from_channex200_response_data_summary.rb +201 -0
  22. data/lib/repull/models/import_from_channex200_response_data_summary_bookings.rb +165 -0
  23. data/lib/repull/models/import_from_channex200_response_data_summary_properties.rb +165 -0
  24. data/lib/repull/models/import_from_channex_request.rb +223 -0
  25. data/lib/repull/models/listing.rb +82 -1
  26. data/lib/repull/models/listing_content_photo.rb +206 -0
  27. data/lib/repull/models/listing_fee.rb +229 -0
  28. data/lib/repull/models/listing_policies.rb +257 -0
  29. data/lib/repull/models/listing_policies_check_in.rb +179 -0
  30. data/lib/repull/models/listing_policies_check_out.rb +148 -0
  31. data/lib/repull/models/listing_policies_quiet_hours.rb +156 -0
  32. data/lib/repull/models/listing_pricing_settings.rb +233 -0
  33. data/lib/repull/models/listing_room.rb +190 -0
  34. data/lib/repull/models/listing_room_beds_inner.rb +156 -0
  35. data/lib/repull/models/listing_rules.rb +212 -0
  36. data/lib/repull/models/listing_tax.rb +241 -0
  37. data/lib/repull/models/reservation_thread_assigned_event.rb +279 -0
  38. data/lib/repull/models/reservation_thread_assigned_payload.rb +174 -0
  39. data/lib/repull/models/reservation_thread_assigned_payload_object.rb +249 -0
  40. data/lib/repull/models/webhook_event.rb +8 -0
  41. data/lib/repull/models/webhook_event_type.rb +5 -1
  42. data/lib/repull/version.rb +1 -1
  43. data/lib/repull.rb +32 -0
  44. data/openapi/v1.json +1591 -8
  45. metadata +34 -4
  46. data/spec/api/plumguide_api_spec.rb +0 -85
@@ -0,0 +1,174 @@
1
+ =begin
2
+ #Repull API
3
+
4
+ #The unified API for vacation rental tech. Connect to 50+ PMS platforms and 4 OTA channels through one REST API. Built-in AI operations for guest communication, pricing, and listing optimization. ## Designed for AI agents Every error response on this API includes machine-parseable fields so an LLM (Claude in MCP, Cursor, Cline, GPT, etc.) can self-recover without escalating to a human: - `error.code` — stable string identifier (e.g. `invalid_params`, `rate_limit_exceeded`) - `error.message` — human-readable cause - `error.fix` — exact recovery steps (e.g. \"Pass `check_in_after` as ISO 8601: `?check_in_after=2026-01-15`\") - `error.docs_url` — link to the canonical write-up at `https://repull.dev/docs/errors/{code}` - `error.request_id` — id to correlate with server-side logs - `error.field` / `error.value_received` / `error.valid_values` / `error.did_you_mean` — when the error is parameter-specific - `error.retry_after` — seconds to wait before retrying (rate-limit + transient upstream) `Access-Control-Expose-Headers` lists `x-request-id` and the `X-RateLimit-*` family so browsers can read them on cross-origin responses. ## Quick Start 1. Get an API key at https://repull.dev/dashboard 2. Connect a PMS: `POST /v1/connect/{provider}` 3. List properties: `GET /v1/properties` 4. Get reservations: `GET /v1/reservations` ## Authentication All requests require a Bearer token: ``` Authorization: Bearer sk_live_YOUR_API_KEY ``` ## Request Correlation (X-Request-ID) Every response carries an `X-Request-ID` header, e.g. `X-Request-ID: req_01HXY...`. Include this id in support tickets and bug reports — we can trace the full request lifecycle (auth, rate limit, handler, downstream calls, log row) from a single id. You may set the header on the inbound request to forward your own trace id; we will echo it back instead of generating a new one. Accepted format: `^[\\\\w.-]{1,128}$`. The id is also embedded in error envelopes as `request_id` so server-side log diffs work even when the response headers are stripped by an intermediate proxy. ## Rate Limits The public API enforces a per-API-key sliding-window rate limit on top of the per-tier monthly + daily-AI quotas. **Default policy:** 600 requests per 60 seconds, per API key. Sliding window — there is no fixed-minute boundary you can burst across. Every response includes: | Header | Meaning | |---|---| | `X-RateLimit-Limit` | Requests permitted in the current window. | | `X-RateLimit-Remaining` | Requests left in the current window after this call. | | `X-RateLimit-Reset` | Unix epoch (seconds) when the next slot opens. | | `X-RateLimit-Policy` | Machine-readable policy descriptor, e.g. `600;w=60`. | | `Retry-After` | Seconds to wait before retrying. **Only present on 429 responses.** | **On 429 (rate_limit_exceeded):** the response body matches the standard error envelope with `code: \"rate_limit_exceeded\"`, plus `limit`, `window_seconds`, `retry_after`, and `request_id` fields. SDKs MUST honor `Retry-After` and use exponential backoff with jitter on subsequent retries — never a tight loop. Recommended backoff: ``` sleep_ms = (Retry-After * 1000) + random(0..250) ``` Monthly + daily-AI tier quotas (`free`, `starter`, `custom`) are enforced separately and also surface as 429s; they include `tier`, `scope`, and `resetsAt` fields. ## Plan Limits (402 — `listings_limit_exceeded`) The Repull API also enforces a per-tier cap on **active listings**: | Tier | Active listings cap | |---|---| | `free` | 3 | | `starter` | unlimited (10 included, then billed per listing) | | `custom` | unlimited | When a customer's active-listing count is above their tier cap, the API returns **`402 Payment Required`** with `error.code = \"listings_limit_exceeded\"` on every route EXCEPT: - `/v1/health` — uptime probes are never gated. - `/v1/usage/*` — so dashboards can render the over-cap state. - Any `DELETE` — so the customer can trim listings to get back under the cap without paying. Unlike 429, 402 is NOT a \"wait and retry\" condition — `Retry-After` is not set. The only paths back to 200 are: 1. `DELETE` enough listings to come back under the cap, or 2. Upgrade at `https://repull.dev/dashboard/billing`. The server-side usage cache is 60s, so the first 200 after an upgrade may take up to a minute. The envelope mirrors `rate_limit_exceeded` for SDK ergonomics: `tier`, `limit`, `active_listings`, `upgrade_url`, plus the standard `code` / `message` / `fix` / `docs_url` / `request_id`.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.22.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Repull
17
+ # Payload for `reservation.thread.assigned`. A message thread was attached to a booking. Threads are often born orphaned — a guest messages about a booking whose import has not landed — and adopted when the reservation arrives.
18
+ class ReservationThreadAssignedPayload < ApiModelBase
19
+ attr_accessor :object
20
+
21
+ attr_accessor :occurred_at
22
+
23
+ # Attribute mapping from ruby-style variable name to JSON key.
24
+ def self.attribute_map
25
+ {
26
+ :'object' => :'object',
27
+ :'occurred_at' => :'occurredAt'
28
+ }
29
+ end
30
+
31
+ # Returns attribute mapping this model knows about
32
+ def self.acceptable_attribute_map
33
+ attribute_map
34
+ end
35
+
36
+ # Returns all the JSON keys this model knows about
37
+ def self.acceptable_attributes
38
+ acceptable_attribute_map.values
39
+ end
40
+
41
+ # Attribute type mapping.
42
+ def self.openapi_types
43
+ {
44
+ :'object' => :'ReservationThreadAssignedPayloadObject',
45
+ :'occurred_at' => :'Time'
46
+ }
47
+ end
48
+
49
+ # List of attributes with nullable: true
50
+ def self.openapi_nullable
51
+ Set.new([
52
+ ])
53
+ end
54
+
55
+ # Initializes the object
56
+ # @param [Hash] attributes Model attributes in the form of hash
57
+ def initialize(attributes = {})
58
+ if (!attributes.is_a?(Hash))
59
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::ReservationThreadAssignedPayload` initialize method"
60
+ end
61
+
62
+ # check to see if the attribute exists and convert string to symbol for hash key
63
+ acceptable_attribute_map = self.class.acceptable_attribute_map
64
+ attributes = attributes.each_with_object({}) { |(k, v), h|
65
+ if (!acceptable_attribute_map.key?(k.to_sym))
66
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::ReservationThreadAssignedPayload`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
67
+ end
68
+ h[k.to_sym] = v
69
+ }
70
+
71
+ if attributes.key?(:'object')
72
+ self.object = attributes[:'object']
73
+ else
74
+ self.object = nil
75
+ end
76
+
77
+ if attributes.key?(:'occurred_at')
78
+ self.occurred_at = attributes[:'occurred_at']
79
+ end
80
+ end
81
+
82
+ # Show invalid properties with the reasons. Usually used together with valid?
83
+ # @return Array for valid properties with the reasons
84
+ def list_invalid_properties
85
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
86
+ invalid_properties = Array.new
87
+ if @object.nil?
88
+ invalid_properties.push('invalid value for "object", object cannot be nil.')
89
+ end
90
+
91
+ invalid_properties
92
+ end
93
+
94
+ # Check to see if the all the properties in the model are valid
95
+ # @return true if the model is valid
96
+ def valid?
97
+ warn '[DEPRECATED] the `valid?` method is obsolete'
98
+ return false if @object.nil?
99
+ true
100
+ end
101
+
102
+ # Custom attribute writer method with validation
103
+ # @param [Object] object Value to be assigned
104
+ def object=(object)
105
+ if object.nil?
106
+ fail ArgumentError, 'object cannot be nil'
107
+ end
108
+
109
+ @object = object
110
+ end
111
+
112
+ # Checks equality by comparing each attribute.
113
+ # @param [Object] Object to be compared
114
+ def ==(o)
115
+ return true if self.equal?(o)
116
+ self.class == o.class &&
117
+ object == o.object &&
118
+ occurred_at == o.occurred_at
119
+ end
120
+
121
+ # @see the `==` method
122
+ # @param [Object] Object to be compared
123
+ def eql?(o)
124
+ self == o
125
+ end
126
+
127
+ # Calculates hash code according to all attributes.
128
+ # @return [Integer] Hash code
129
+ def hash
130
+ [object, occurred_at].hash
131
+ end
132
+
133
+ # Builds the object from hash
134
+ # @param [Hash] attributes Model attributes in the form of hash
135
+ # @return [Object] Returns the model itself
136
+ def self.build_from_hash(attributes)
137
+ return nil unless attributes.is_a?(Hash)
138
+ attributes = attributes.transform_keys(&:to_sym)
139
+ transformed_hash = {}
140
+ openapi_types.each_pair do |key, type|
141
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
142
+ transformed_hash["#{key}"] = nil
143
+ elsif type =~ /\AArray<(.*)>/i
144
+ # check to ensure the input is an array given that the attribute
145
+ # is documented as an array but the input is not
146
+ if attributes[attribute_map[key]].is_a?(Array)
147
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
148
+ end
149
+ elsif !attributes[attribute_map[key]].nil?
150
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
151
+ end
152
+ end
153
+ new(transformed_hash)
154
+ end
155
+
156
+ # Returns the object in the form of hash
157
+ # @return [Hash] Returns the object in the form of hash
158
+ def to_hash
159
+ hash = {}
160
+ self.class.attribute_map.each_pair do |attr, param|
161
+ value = self.send(attr)
162
+ if value.nil?
163
+ is_nullable = self.class.openapi_nullable.include?(attr)
164
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
165
+ end
166
+
167
+ hash[param] = _to_hash(value)
168
+ end
169
+ hash
170
+ end
171
+
172
+ end
173
+
174
+ end
@@ -0,0 +1,249 @@
1
+ =begin
2
+ #Repull API
3
+
4
+ #The unified API for vacation rental tech. Connect to 50+ PMS platforms and 4 OTA channels through one REST API. Built-in AI operations for guest communication, pricing, and listing optimization. ## Designed for AI agents Every error response on this API includes machine-parseable fields so an LLM (Claude in MCP, Cursor, Cline, GPT, etc.) can self-recover without escalating to a human: - `error.code` — stable string identifier (e.g. `invalid_params`, `rate_limit_exceeded`) - `error.message` — human-readable cause - `error.fix` — exact recovery steps (e.g. \"Pass `check_in_after` as ISO 8601: `?check_in_after=2026-01-15`\") - `error.docs_url` — link to the canonical write-up at `https://repull.dev/docs/errors/{code}` - `error.request_id` — id to correlate with server-side logs - `error.field` / `error.value_received` / `error.valid_values` / `error.did_you_mean` — when the error is parameter-specific - `error.retry_after` — seconds to wait before retrying (rate-limit + transient upstream) `Access-Control-Expose-Headers` lists `x-request-id` and the `X-RateLimit-*` family so browsers can read them on cross-origin responses. ## Quick Start 1. Get an API key at https://repull.dev/dashboard 2. Connect a PMS: `POST /v1/connect/{provider}` 3. List properties: `GET /v1/properties` 4. Get reservations: `GET /v1/reservations` ## Authentication All requests require a Bearer token: ``` Authorization: Bearer sk_live_YOUR_API_KEY ``` ## Request Correlation (X-Request-ID) Every response carries an `X-Request-ID` header, e.g. `X-Request-ID: req_01HXY...`. Include this id in support tickets and bug reports — we can trace the full request lifecycle (auth, rate limit, handler, downstream calls, log row) from a single id. You may set the header on the inbound request to forward your own trace id; we will echo it back instead of generating a new one. Accepted format: `^[\\\\w.-]{1,128}$`. The id is also embedded in error envelopes as `request_id` so server-side log diffs work even when the response headers are stripped by an intermediate proxy. ## Rate Limits The public API enforces a per-API-key sliding-window rate limit on top of the per-tier monthly + daily-AI quotas. **Default policy:** 600 requests per 60 seconds, per API key. Sliding window — there is no fixed-minute boundary you can burst across. Every response includes: | Header | Meaning | |---|---| | `X-RateLimit-Limit` | Requests permitted in the current window. | | `X-RateLimit-Remaining` | Requests left in the current window after this call. | | `X-RateLimit-Reset` | Unix epoch (seconds) when the next slot opens. | | `X-RateLimit-Policy` | Machine-readable policy descriptor, e.g. `600;w=60`. | | `Retry-After` | Seconds to wait before retrying. **Only present on 429 responses.** | **On 429 (rate_limit_exceeded):** the response body matches the standard error envelope with `code: \"rate_limit_exceeded\"`, plus `limit`, `window_seconds`, `retry_after`, and `request_id` fields. SDKs MUST honor `Retry-After` and use exponential backoff with jitter on subsequent retries — never a tight loop. Recommended backoff: ``` sleep_ms = (Retry-After * 1000) + random(0..250) ``` Monthly + daily-AI tier quotas (`free`, `starter`, `custom`) are enforced separately and also surface as 429s; they include `tier`, `scope`, and `resetsAt` fields. ## Plan Limits (402 — `listings_limit_exceeded`) The Repull API also enforces a per-tier cap on **active listings**: | Tier | Active listings cap | |---|---| | `free` | 3 | | `starter` | unlimited (10 included, then billed per listing) | | `custom` | unlimited | When a customer's active-listing count is above their tier cap, the API returns **`402 Payment Required`** with `error.code = \"listings_limit_exceeded\"` on every route EXCEPT: - `/v1/health` — uptime probes are never gated. - `/v1/usage/*` — so dashboards can render the over-cap state. - Any `DELETE` — so the customer can trim listings to get back under the cap without paying. Unlike 429, 402 is NOT a \"wait and retry\" condition — `Retry-After` is not set. The only paths back to 200 are: 1. `DELETE` enough listings to come back under the cap, or 2. Upgrade at `https://repull.dev/dashboard/billing`. The server-side usage cache is 60s, so the first 200 after an upgrade may take up to a minute. The envelope mirrors `rate_limit_exceeded` for SDK ergonomics: `tier`, `limit`, `active_listings`, `upgrade_url`, plus the standard `code` / `message` / `fix` / `docs_url` / `request_id`.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.22.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Repull
17
+ class ReservationThreadAssignedPayloadObject < ApiModelBase
18
+ attr_accessor :reservation_id
19
+
20
+ attr_accessor :customer_id
21
+
22
+ attr_accessor :listing_id
23
+
24
+ # Repull conversation id.
25
+ attr_accessor :thread_id
26
+
27
+ # The channel's own conversation id.
28
+ attr_accessor :external_thread_id
29
+
30
+ # What the thread pointed at before. Null on the common orphan-adoption case; set when a thread moved between bookings.
31
+ attr_accessor :previous_reservation_id
32
+
33
+ # Attribute mapping from ruby-style variable name to JSON key.
34
+ def self.attribute_map
35
+ {
36
+ :'reservation_id' => :'reservationId',
37
+ :'customer_id' => :'customerId',
38
+ :'listing_id' => :'listingId',
39
+ :'thread_id' => :'threadId',
40
+ :'external_thread_id' => :'externalThreadId',
41
+ :'previous_reservation_id' => :'previousReservationId'
42
+ }
43
+ end
44
+
45
+ # Returns attribute mapping this model knows about
46
+ def self.acceptable_attribute_map
47
+ attribute_map
48
+ end
49
+
50
+ # Returns all the JSON keys this model knows about
51
+ def self.acceptable_attributes
52
+ acceptable_attribute_map.values
53
+ end
54
+
55
+ # Attribute type mapping.
56
+ def self.openapi_types
57
+ {
58
+ :'reservation_id' => :'Integer',
59
+ :'customer_id' => :'Integer',
60
+ :'listing_id' => :'Integer',
61
+ :'thread_id' => :'String',
62
+ :'external_thread_id' => :'String',
63
+ :'previous_reservation_id' => :'Integer'
64
+ }
65
+ end
66
+
67
+ # List of attributes with nullable: true
68
+ def self.openapi_nullable
69
+ Set.new([
70
+ :'listing_id',
71
+ :'external_thread_id',
72
+ :'previous_reservation_id'
73
+ ])
74
+ end
75
+
76
+ # Initializes the object
77
+ # @param [Hash] attributes Model attributes in the form of hash
78
+ def initialize(attributes = {})
79
+ if (!attributes.is_a?(Hash))
80
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::ReservationThreadAssignedPayloadObject` initialize method"
81
+ end
82
+
83
+ # check to see if the attribute exists and convert string to symbol for hash key
84
+ acceptable_attribute_map = self.class.acceptable_attribute_map
85
+ attributes = attributes.each_with_object({}) { |(k, v), h|
86
+ if (!acceptable_attribute_map.key?(k.to_sym))
87
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::ReservationThreadAssignedPayloadObject`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
88
+ end
89
+ h[k.to_sym] = v
90
+ }
91
+
92
+ if attributes.key?(:'reservation_id')
93
+ self.reservation_id = attributes[:'reservation_id']
94
+ else
95
+ self.reservation_id = nil
96
+ end
97
+
98
+ if attributes.key?(:'customer_id')
99
+ self.customer_id = attributes[:'customer_id']
100
+ else
101
+ self.customer_id = nil
102
+ end
103
+
104
+ if attributes.key?(:'listing_id')
105
+ self.listing_id = attributes[:'listing_id']
106
+ end
107
+
108
+ if attributes.key?(:'thread_id')
109
+ self.thread_id = attributes[:'thread_id']
110
+ else
111
+ self.thread_id = nil
112
+ end
113
+
114
+ if attributes.key?(:'external_thread_id')
115
+ self.external_thread_id = attributes[:'external_thread_id']
116
+ end
117
+
118
+ if attributes.key?(:'previous_reservation_id')
119
+ self.previous_reservation_id = attributes[:'previous_reservation_id']
120
+ end
121
+ end
122
+
123
+ # Show invalid properties with the reasons. Usually used together with valid?
124
+ # @return Array for valid properties with the reasons
125
+ def list_invalid_properties
126
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
127
+ invalid_properties = Array.new
128
+ if @reservation_id.nil?
129
+ invalid_properties.push('invalid value for "reservation_id", reservation_id cannot be nil.')
130
+ end
131
+
132
+ if @customer_id.nil?
133
+ invalid_properties.push('invalid value for "customer_id", customer_id cannot be nil.')
134
+ end
135
+
136
+ if @thread_id.nil?
137
+ invalid_properties.push('invalid value for "thread_id", thread_id cannot be nil.')
138
+ end
139
+
140
+ invalid_properties
141
+ end
142
+
143
+ # Check to see if the all the properties in the model are valid
144
+ # @return true if the model is valid
145
+ def valid?
146
+ warn '[DEPRECATED] the `valid?` method is obsolete'
147
+ return false if @reservation_id.nil?
148
+ return false if @customer_id.nil?
149
+ return false if @thread_id.nil?
150
+ true
151
+ end
152
+
153
+ # Custom attribute writer method with validation
154
+ # @param [Object] reservation_id Value to be assigned
155
+ def reservation_id=(reservation_id)
156
+ if reservation_id.nil?
157
+ fail ArgumentError, 'reservation_id cannot be nil'
158
+ end
159
+
160
+ @reservation_id = reservation_id
161
+ end
162
+
163
+ # Custom attribute writer method with validation
164
+ # @param [Object] customer_id Value to be assigned
165
+ def customer_id=(customer_id)
166
+ if customer_id.nil?
167
+ fail ArgumentError, 'customer_id cannot be nil'
168
+ end
169
+
170
+ @customer_id = customer_id
171
+ end
172
+
173
+ # Custom attribute writer method with validation
174
+ # @param [Object] thread_id Value to be assigned
175
+ def thread_id=(thread_id)
176
+ if thread_id.nil?
177
+ fail ArgumentError, 'thread_id cannot be nil'
178
+ end
179
+
180
+ @thread_id = thread_id
181
+ end
182
+
183
+ # Checks equality by comparing each attribute.
184
+ # @param [Object] Object to be compared
185
+ def ==(o)
186
+ return true if self.equal?(o)
187
+ self.class == o.class &&
188
+ reservation_id == o.reservation_id &&
189
+ customer_id == o.customer_id &&
190
+ listing_id == o.listing_id &&
191
+ thread_id == o.thread_id &&
192
+ external_thread_id == o.external_thread_id &&
193
+ previous_reservation_id == o.previous_reservation_id
194
+ end
195
+
196
+ # @see the `==` method
197
+ # @param [Object] Object to be compared
198
+ def eql?(o)
199
+ self == o
200
+ end
201
+
202
+ # Calculates hash code according to all attributes.
203
+ # @return [Integer] Hash code
204
+ def hash
205
+ [reservation_id, customer_id, listing_id, thread_id, external_thread_id, previous_reservation_id].hash
206
+ end
207
+
208
+ # Builds the object from hash
209
+ # @param [Hash] attributes Model attributes in the form of hash
210
+ # @return [Object] Returns the model itself
211
+ def self.build_from_hash(attributes)
212
+ return nil unless attributes.is_a?(Hash)
213
+ attributes = attributes.transform_keys(&:to_sym)
214
+ transformed_hash = {}
215
+ openapi_types.each_pair do |key, type|
216
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
217
+ transformed_hash["#{key}"] = nil
218
+ elsif type =~ /\AArray<(.*)>/i
219
+ # check to ensure the input is an array given that the attribute
220
+ # is documented as an array but the input is not
221
+ if attributes[attribute_map[key]].is_a?(Array)
222
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
223
+ end
224
+ elsif !attributes[attribute_map[key]].nil?
225
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
226
+ end
227
+ end
228
+ new(transformed_hash)
229
+ end
230
+
231
+ # Returns the object in the form of hash
232
+ # @return [Hash] Returns the object in the form of hash
233
+ def to_hash
234
+ hash = {}
235
+ self.class.attribute_map.each_pair do |attr, param|
236
+ value = self.send(attr)
237
+ if value.nil?
238
+ is_nullable = self.class.openapi_nullable.include?(attr)
239
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
240
+ end
241
+
242
+ hash[param] = _to_hash(value)
243
+ end
244
+ hash
245
+ end
246
+
247
+ end
248
+
249
+ end
@@ -27,6 +27,9 @@ module Repull
27
27
  :'AccountImportStartedEvent',
28
28
  :'AiOperationCompletedEvent',
29
29
  :'AiOperationFailedEvent',
30
+ :'BookingUnacknowledgedEvent',
31
+ :'ChannelDegradedEvent',
32
+ :'ChannelSyncFailedEvent',
30
33
  :'ConnectSessionCompletedEvent',
31
34
  :'InquiryCreatedEvent',
32
35
  :'InquiryUpdatedEvent',
@@ -50,6 +53,7 @@ module Repull
50
53
  :'ReservationMessageUpdatedEvent',
51
54
  :'ReservationRequestCreatedEvent',
52
55
  :'ReservationRequestUpdatedEvent',
56
+ :'ReservationThreadAssignedEvent',
53
57
  :'ReservationUpdatedEvent',
54
58
  :'ReviewCreatedEvent',
55
59
  :'ReviewRespondedEvent',
@@ -72,6 +76,9 @@ module Repull
72
76
  :'account.import.started' => :'AccountImportStartedEvent',
73
77
  :'ai.operation.completed' => :'AiOperationCompletedEvent',
74
78
  :'ai.operation.failed' => :'AiOperationFailedEvent',
79
+ :'booking.unacknowledged' => :'BookingUnacknowledgedEvent',
80
+ :'channel.degraded' => :'ChannelDegradedEvent',
81
+ :'channel.sync.failed' => :'ChannelSyncFailedEvent',
75
82
  :'connect.session.completed' => :'ConnectSessionCompletedEvent',
76
83
  :'inquiry.created' => :'InquiryCreatedEvent',
77
84
  :'inquiry.updated' => :'InquiryUpdatedEvent',
@@ -95,6 +102,7 @@ module Repull
95
102
  :'reservation.message.updated' => :'ReservationMessageUpdatedEvent',
96
103
  :'reservation.request.created' => :'ReservationRequestCreatedEvent',
97
104
  :'reservation.request.updated' => :'ReservationRequestUpdatedEvent',
105
+ :'reservation.thread.assigned' => :'ReservationThreadAssignedEvent',
98
106
  :'reservation.updated' => :'ReservationUpdatedEvent',
99
107
  :'review.created' => :'ReviewCreatedEvent',
100
108
  :'review.responded' => :'ReviewRespondedEvent',
@@ -25,6 +25,10 @@ module Repull
25
25
  RESERVATION_ALTERATION_RESPONDED = "reservation.alteration.responded".freeze
26
26
  RESERVATION_REQUEST_CREATED = "reservation.request.created".freeze
27
27
  RESERVATION_REQUEST_UPDATED = "reservation.request.updated".freeze
28
+ BOOKING_UNACKNOWLEDGED = "booking.unacknowledged".freeze
29
+ CHANNEL_SYNC_FAILED = "channel.sync.failed".freeze
30
+ CHANNEL_DEGRADED = "channel.degraded".freeze
31
+ RESERVATION_THREAD_ASSIGNED = "reservation.thread.assigned".freeze
28
32
  INQUIRY_CREATED = "inquiry.created".freeze
29
33
  INQUIRY_UPDATED = "inquiry.updated".freeze
30
34
  LISTING_CREATED = "listing.created".freeze
@@ -51,7 +55,7 @@ module Repull
51
55
  USAGE_QUOTA_WARNING = "usage.quota.warning".freeze
52
56
 
53
57
  def self.all_vars
54
- @all_vars ||= [RESERVATION_CREATED, RESERVATION_UPDATED, RESERVATION_CANCELLED, RESERVATION_MESSAGE_RECEIVED, RESERVATION_MESSAGE_SENT, RESERVATION_MESSAGE_UPDATED, RESERVATION_ALTERATION_CREATED, RESERVATION_ALTERATION_RESPONDED, RESERVATION_REQUEST_CREATED, RESERVATION_REQUEST_UPDATED, INQUIRY_CREATED, INQUIRY_UPDATED, LISTING_CREATED, LISTING_UPDATED, LISTING_DELETED, LISTING_SUSPENDED, LISTING_REACTIVATED, ACCOUNT_CREATED, CONNECT_SESSION_COMPLETED, ACCOUNT_DISCONNECTED, ACCOUNT_IMPORT_STARTED, ACCOUNT_IMPORT_COMPLETED, ACCOUNT_IMPORT_FAILED, REVIEW_CREATED, REVIEW_RESPONDED, AI_OPERATION_COMPLETED, AI_OPERATION_FAILED, PAYMENT_COMPLETED, PAYMENT_REFUNDED, PAYOUT_COMPLETED, MIGRATION_COMPLETED, MIGRATION_FAILED, REPULL_PING, USAGE_QUOTA_WARNING].freeze
58
+ @all_vars ||= [RESERVATION_CREATED, RESERVATION_UPDATED, RESERVATION_CANCELLED, RESERVATION_MESSAGE_RECEIVED, RESERVATION_MESSAGE_SENT, RESERVATION_MESSAGE_UPDATED, RESERVATION_ALTERATION_CREATED, RESERVATION_ALTERATION_RESPONDED, RESERVATION_REQUEST_CREATED, RESERVATION_REQUEST_UPDATED, BOOKING_UNACKNOWLEDGED, CHANNEL_SYNC_FAILED, CHANNEL_DEGRADED, RESERVATION_THREAD_ASSIGNED, INQUIRY_CREATED, INQUIRY_UPDATED, LISTING_CREATED, LISTING_UPDATED, LISTING_DELETED, LISTING_SUSPENDED, LISTING_REACTIVATED, ACCOUNT_CREATED, CONNECT_SESSION_COMPLETED, ACCOUNT_DISCONNECTED, ACCOUNT_IMPORT_STARTED, ACCOUNT_IMPORT_COMPLETED, ACCOUNT_IMPORT_FAILED, REVIEW_CREATED, REVIEW_RESPONDED, AI_OPERATION_COMPLETED, AI_OPERATION_FAILED, PAYMENT_COMPLETED, PAYMENT_REFUNDED, PAYOUT_COMPLETED, MIGRATION_COMPLETED, MIGRATION_FAILED, REPULL_PING, USAGE_QUOTA_WARNING].freeze
55
59
  end
56
60
 
57
61
  # Builds the enum from string
@@ -11,5 +11,5 @@ Generator version: 7.22.0
11
11
  =end
12
12
 
13
13
  module Repull
14
- VERSION = '0.2.35'
14
+ VERSION = '0.2.36'
15
15
  end
data/lib/repull.rb CHANGED
@@ -143,6 +143,8 @@ require 'repull/models/booking_rooms_rates_response_rooms_inner'
143
143
  require 'repull/models/booking_rooms_rates_response_rooms_inner_rates_inner'
144
144
  require 'repull/models/booking_setup_request'
145
145
  require 'repull/models/booking_setup_request_legal_entity'
146
+ require 'repull/models/booking_unacknowledged_event'
147
+ require 'repull/models/booking_unacknowledged_payload'
146
148
  require 'repull/models/booking_upstream_failure'
147
149
  require 'repull/models/booking_verify_hotel_request'
148
150
  require 'repull/models/booking_verify_hotel_response'
@@ -154,7 +156,15 @@ require 'repull/models/calendar_day'
154
156
  require 'repull/models/calendar_response'
155
157
  require 'repull/models/cancel_reservation200_response'
156
158
  require 'repull/models/cancel_reservation_request'
159
+ require 'repull/models/channel_degraded_event'
160
+ require 'repull/models/channel_degraded_payload'
161
+ require 'repull/models/channel_degraded_payload_object'
157
162
  require 'repull/models/channel_market_state_item'
163
+ require 'repull/models/channel_sync_failed_event'
164
+ require 'repull/models/channel_sync_failure_payload'
165
+ require 'repull/models/channel_sync_failure_payload_failures_inner'
166
+ require 'repull/models/channel_sync_failure_payload_object'
167
+ require 'repull/models/charge_per'
158
168
  require 'repull/models/check_migration_cutover200_response'
159
169
  require 'repull/models/check_migration_cutover_request'
160
170
  require 'repull/models/check_migration_cutover_request_reservations_inner'
@@ -285,6 +295,14 @@ require 'repull/models/guest_update_request'
285
295
  require 'repull/models/guest_update_response'
286
296
  require 'repull/models/guest_update_response_contacts_inner'
287
297
  require 'repull/models/guest_update_response_pms_inner'
298
+ require 'repull/models/import_from_channex200_response'
299
+ require 'repull/models/import_from_channex200_response_data'
300
+ require 'repull/models/import_from_channex200_response_data_channels_inner'
301
+ require 'repull/models/import_from_channex200_response_data_properties_inner'
302
+ require 'repull/models/import_from_channex200_response_data_summary'
303
+ require 'repull/models/import_from_channex200_response_data_summary_bookings'
304
+ require 'repull/models/import_from_channex200_response_data_summary_properties'
305
+ require 'repull/models/import_from_channex_request'
288
306
  require 'repull/models/inquiry_created_event'
289
307
  require 'repull/models/inquiry_created_payload'
290
308
  require 'repull/models/inquiry_updated_event'
@@ -336,6 +354,7 @@ require 'repull/models/listing_comp_nightly'
336
354
  require 'repull/models/listing_comp_ratings'
337
355
  require 'repull/models/listing_comps_response'
338
356
  require 'repull/models/listing_content'
357
+ require 'repull/models/listing_content_photo'
339
358
  require 'repull/models/listing_content_update_request'
340
359
  require 'repull/models/listing_content_update_request_address'
341
360
  require 'repull/models/listing_content_update_request_amenities'
@@ -360,6 +379,7 @@ require 'repull/models/listing_created_payload_address'
360
379
  require 'repull/models/listing_deleted_event'
361
380
  require 'repull/models/listing_deleted_payload'
362
381
  require 'repull/models/listing_details'
382
+ require 'repull/models/listing_fee'
363
383
  require 'repull/models/listing_generate_content_request'
364
384
  require 'repull/models/listing_generate_content_response'
365
385
  require 'repull/models/listing_hotel'
@@ -372,6 +392,10 @@ require 'repull/models/listing_photo_delete_response'
372
392
  require 'repull/models/listing_photo_upload_url_request'
373
393
  require 'repull/models/listing_photo_upload_url_response'
374
394
  require 'repull/models/listing_photos_response'
395
+ require 'repull/models/listing_policies'
396
+ require 'repull/models/listing_policies_check_in'
397
+ require 'repull/models/listing_policies_check_out'
398
+ require 'repull/models/listing_policies_quiet_hours'
375
399
  require 'repull/models/listing_pricing_apply_request'
376
400
  require 'repull/models/listing_pricing_apply_response'
377
401
  require 'repull/models/listing_pricing_history_entry'
@@ -381,6 +405,7 @@ require 'repull/models/listing_pricing_response'
381
405
  require 'repull/models/listing_pricing_response_comp_summary'
382
406
  require 'repull/models/listing_pricing_response_date_range'
383
407
  require 'repull/models/listing_pricing_response_listing'
408
+ require 'repull/models/listing_pricing_settings'
384
409
  require 'repull/models/listing_pricing_strategy'
385
410
  require 'repull/models/listing_pricing_strategy_input'
386
411
  require 'repull/models/listing_publish_airbnb_request'
@@ -394,6 +419,9 @@ require 'repull/models/listing_pull_airbnb_request'
394
419
  require 'repull/models/listing_pull_response'
395
420
  require 'repull/models/listing_quality_tier'
396
421
  require 'repull/models/listing_reactivated_event'
422
+ require 'repull/models/listing_room'
423
+ require 'repull/models/listing_room_beds_inner'
424
+ require 'repull/models/listing_rules'
397
425
  require 'repull/models/listing_segment'
398
426
  require 'repull/models/listing_segment_recommendation'
399
427
  require 'repull/models/listing_segments_response'
@@ -402,6 +430,7 @@ require 'repull/models/listing_status_batch_request'
402
430
  require 'repull/models/listing_status_batch_response'
403
431
  require 'repull/models/listing_suspended_event'
404
432
  require 'repull/models/listing_suspension_payload'
433
+ require 'repull/models/listing_tax'
405
434
  require 'repull/models/listing_units_inner'
406
435
  require 'repull/models/listing_updated_event'
407
436
  require 'repull/models/listing_updated_payload'
@@ -577,6 +606,9 @@ require 'repull/models/reservation_request_created_event'
577
606
  require 'repull/models/reservation_request_created_payload'
578
607
  require 'repull/models/reservation_request_updated_event'
579
608
  require 'repull/models/reservation_request_updated_payload'
609
+ require 'repull/models/reservation_thread_assigned_event'
610
+ require 'repull/models/reservation_thread_assigned_payload'
611
+ require 'repull/models/reservation_thread_assigned_payload_object'
580
612
  require 'repull/models/reservation_unit'
581
613
  require 'repull/models/reservation_update_request'
582
614
  require 'repull/models/reservation_update_response'