repull 0.2.8 → 0.2.10

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 (79) hide show
  1. checksums.yaml +4 -4
  2. data/lib/repull/api/airbnb_api.rb +1443 -182
  3. data/lib/repull/api/availability_api.rb +24 -92
  4. data/lib/repull/api/billing_api.rb +186 -15
  5. data/lib/repull/api/booking_com_api.rb +532 -41
  6. data/lib/repull/api/listings_api.rb +74 -0
  7. data/lib/repull/api/plumguide_api.rb +245 -0
  8. data/lib/repull/api/reservations_api.rb +0 -197
  9. data/lib/repull/api/sandbox_api.rb +136 -0
  10. data/lib/repull/api/vrbo_api.rb +0 -126
  11. data/lib/repull/models/acknowledge_booking_reservations_request.rb +176 -0
  12. data/lib/repull/models/{create_studio_project201_response_data.rb → airbnb_alteration.rb} +44 -52
  13. data/lib/repull/models/airbnb_amenity.rb +171 -0
  14. data/lib/repull/models/{get_studio_deployment200_response.rb → airbnb_availability_write_request.rb} +52 -10
  15. data/lib/repull/models/airbnb_calendar_operation.rb +250 -0
  16. data/lib/repull/models/airbnb_listing_action_request.rb +198 -0
  17. data/lib/repull/models/{update_availability_request.rb → airbnb_pricing_write_request.rb} +100 -11
  18. data/lib/repull/models/booking_availability_update.rb +276 -0
  19. data/lib/repull/models/booking_availability_update_request.rb +230 -0
  20. data/lib/repull/models/{generate_studio_completion_request_project_id.rb → booking_availability_update_request_property_id.rb} +2 -2
  21. data/lib/repull/models/booking_availability_update_request_updates_inner.rb +104 -0
  22. data/lib/repull/models/booking_pricing_rate_update.rb +1 -0
  23. data/lib/repull/models/booking_pricing_rate_update_restrictions.rb +65 -6
  24. data/lib/repull/models/booking_setup_request.rb +220 -0
  25. data/lib/repull/models/create_airbnb_alteration_request.rb +195 -0
  26. data/lib/repull/models/{create_studio_deployment201_response_data.rb → create_airbnb_offer_request.rb} +42 -30
  27. data/lib/repull/models/{create_studio_project_request.rb → create_booking_webhook_request.rb} +36 -47
  28. data/lib/repull/models/{generate_studio_completion200_response.rb → delete_airbnb_listing_photo200_response.rb} +10 -10
  29. data/lib/repull/models/{delete_studio_project200_response.rb → get_airbnb_alteration200_response.rb} +50 -7
  30. data/lib/repull/models/{delete_studio_project_file200_response.rb → get_airbnb_listing_quality200_response.rb} +37 -7
  31. data/lib/repull/models/{create_studio_project_generation201_response.rb → get_airbnb_listing_settings200_response.rb} +37 -7
  32. data/lib/repull/models/{delete_studio_deployment200_response.rb → get_airbnb_thread200_response.rb} +50 -7
  33. data/lib/repull/models/{list_studio_deployments200_response.rb → get_usage_logs200_response.rb} +17 -8
  34. data/lib/repull/models/get_usage_logs200_response_data_inner.rb +264 -0
  35. data/lib/repull/models/{create_studio_deployment201_response.rb → get_usage_logs200_response_pagination.rb} +29 -10
  36. data/lib/repull/models/get_usage_summary200_response.rb +232 -0
  37. data/lib/repull/models/get_usage_summary200_response_breakdown_inner.rb +183 -0
  38. data/lib/repull/models/{delete_studio_deployment200_response_data.rb → get_usage_summary200_response_limits.rb} +18 -16
  39. data/lib/repull/models/{delete_studio_project200_response_data.rb → get_usage_summary200_response_remaining.rb} +18 -16
  40. data/lib/repull/models/{create_studio_project_generation201_response_data.rb → get_usage_summary200_response_status_distribution.rb} +31 -22
  41. data/lib/repull/models/{upsert_studio_project_file_request.rb → get_usage_summary200_response_timeline_inner.rb} +28 -28
  42. data/lib/repull/models/{create_studio_project_generation_request.rb → get_usage_summary200_response_totals.rb} +28 -28
  43. data/lib/repull/models/{create_studio_project201_response.rb → get_usage_summary200_response_used.rb} +19 -10
  44. data/lib/repull/models/get_usage_tier200_response.rb +183 -0
  45. data/lib/repull/models/{list_studio_projects200_response.rb → get_usage_tier200_response_limits.rb} +31 -12
  46. data/lib/repull/models/{update_reservation_request.rb → get_usage_tier200_response_remaining.rb} +25 -31
  47. data/lib/repull/models/{get_studio_project200_response.rb → get_usage_tier200_response_used.rb} +28 -10
  48. data/lib/repull/models/list_airbnb_alterations200_response.rb +192 -0
  49. data/lib/repull/models/list_airbnb_listing_amenities200_response.rb +190 -0
  50. data/lib/repull/models/{create_studio_deployment_request.rb → list_airbnb_listing_amenities200_response_data.rb} +23 -28
  51. data/lib/repull/models/{list_studio_project_files200_response.rb → list_airbnb_transactions200_response.rb} +50 -7
  52. data/lib/repull/models/listing_content_update_request.rb +243 -0
  53. data/lib/repull/models/{upsert_studio_project_file200_response.rb → listing_content_update_request_address.rb} +53 -10
  54. data/lib/repull/models/listing_content_update_request_amenities.rb +105 -0
  55. data/lib/repull/models/listing_content_update_request_amenities_one_of_inner.rb +196 -0
  56. data/lib/repull/models/listing_content_update_request_occupancy.rb +179 -0
  57. data/lib/repull/{api/ai_api.rb → models/listing_content_update_request_photos_inner.rb} +77 -59
  58. data/lib/repull/models/{generate_studio_completion200_response_data.rb → listing_content_update_request_photos_inner_one_of.rb} +81 -66
  59. data/lib/repull/models/listing_content_update_request_policies.rb +253 -0
  60. data/lib/repull/models/{create_ai_operation200_response.rb → listing_content_update_response.rb} +32 -16
  61. data/lib/repull/models/map_airbnb_listing_request.rb +215 -0
  62. data/lib/repull/models/{create_reservation_request.rb → map_airbnb_listing_response.rb} +137 -116
  63. data/lib/repull/models/property.rb +42 -69
  64. data/lib/repull/models/property_availability.rb +222 -0
  65. data/lib/repull/models/property_availability_day.rb +247 -0
  66. data/lib/repull/models/reservation.rb +28 -1
  67. data/lib/repull/models/sandbox_fixture_ref.rb +193 -0
  68. data/lib/repull/models/{delete_studio_project_file200_response_data.rb → sandbox_reset_result.rb} +72 -11
  69. data/lib/repull/models/sandbox_reset_result_deleted.rb +216 -0
  70. data/lib/repull/models/sandbox_seed_result.rb +278 -0
  71. data/lib/repull/models/{update_studio_project_request.rb → update_airbnb_message_request.rb} +43 -24
  72. data/lib/repull/models/update_booking_charges_request.rb +194 -0
  73. data/lib/repull/version.rb +1 -1
  74. data/lib/repull.rb +59 -34
  75. data/openapi/v1.json +3956 -2522
  76. metadata +61 -36
  77. data/lib/repull/api/studio_api.rb +0 -1094
  78. data/lib/repull/models/generate_studio_completion_request.rb +0 -305
  79. data/lib/repull/models/upsert_studio_project_file200_response_data.rb +0 -147
@@ -14,22 +14,18 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Repull
17
- class CreateStudioProjectRequest < ApiModelBase
18
- # Human-readable project name. Used to derive the slug.
19
- attr_accessor :name
17
+ class CreateBookingWebhookRequest < ApiModelBase
18
+ # Booking.com CNS notification type.
19
+ attr_accessor :notification_type
20
20
 
21
- # Initial prompt that seeds the project. Repull AI scaffolds the first generation from this.
22
- attr_accessor :prompt
23
-
24
- # Optional template to start from (e.g. `next-saas`). Omit to generate from prompt only.
25
- attr_accessor :template_id
21
+ # HTTPS endpoint Booking.com pushes notifications to.
22
+ attr_accessor :callback_url
26
23
 
27
24
  # Attribute mapping from ruby-style variable name to JSON key.
28
25
  def self.attribute_map
29
26
  {
30
- :'name' => :'name',
31
- :'prompt' => :'prompt',
32
- :'template_id' => :'template_id'
27
+ :'notification_type' => :'notification_type',
28
+ :'callback_url' => :'callback_url'
33
29
  }
34
30
  end
35
31
 
@@ -46,16 +42,14 @@ module Repull
46
42
  # Attribute type mapping.
47
43
  def self.openapi_types
48
44
  {
49
- :'name' => :'String',
50
- :'prompt' => :'String',
51
- :'template_id' => :'String'
45
+ :'notification_type' => :'String',
46
+ :'callback_url' => :'String'
52
47
  }
53
48
  end
54
49
 
55
50
  # List of attributes with nullable: true
56
51
  def self.openapi_nullable
57
52
  Set.new([
58
- :'template_id'
59
53
  ])
60
54
  end
61
55
 
@@ -63,32 +57,28 @@ module Repull
63
57
  # @param [Hash] attributes Model attributes in the form of hash
64
58
  def initialize(attributes = {})
65
59
  if (!attributes.is_a?(Hash))
66
- fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::CreateStudioProjectRequest` initialize method"
60
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::CreateBookingWebhookRequest` initialize method"
67
61
  end
68
62
 
69
63
  # check to see if the attribute exists and convert string to symbol for hash key
70
64
  acceptable_attribute_map = self.class.acceptable_attribute_map
71
65
  attributes = attributes.each_with_object({}) { |(k, v), h|
72
66
  if (!acceptable_attribute_map.key?(k.to_sym))
73
- fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::CreateStudioProjectRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::CreateBookingWebhookRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
74
68
  end
75
69
  h[k.to_sym] = v
76
70
  }
77
71
 
78
- if attributes.key?(:'name')
79
- self.name = attributes[:'name']
72
+ if attributes.key?(:'notification_type')
73
+ self.notification_type = attributes[:'notification_type']
80
74
  else
81
- self.name = nil
75
+ self.notification_type = nil
82
76
  end
83
77
 
84
- if attributes.key?(:'prompt')
85
- self.prompt = attributes[:'prompt']
78
+ if attributes.key?(:'callback_url')
79
+ self.callback_url = attributes[:'callback_url']
86
80
  else
87
- self.prompt = nil
88
- end
89
-
90
- if attributes.key?(:'template_id')
91
- self.template_id = attributes[:'template_id']
81
+ self.callback_url = nil
92
82
  end
93
83
  end
94
84
 
@@ -97,12 +87,12 @@ module Repull
97
87
  def list_invalid_properties
98
88
  warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
99
89
  invalid_properties = Array.new
100
- if @name.nil?
101
- invalid_properties.push('invalid value for "name", name cannot be nil.')
90
+ if @notification_type.nil?
91
+ invalid_properties.push('invalid value for "notification_type", notification_type cannot be nil.')
102
92
  end
103
93
 
104
- if @prompt.nil?
105
- invalid_properties.push('invalid value for "prompt", prompt cannot be nil.')
94
+ if @callback_url.nil?
95
+ invalid_properties.push('invalid value for "callback_url", callback_url cannot be nil.')
106
96
  end
107
97
 
108
98
  invalid_properties
@@ -112,29 +102,29 @@ module Repull
112
102
  # @return true if the model is valid
113
103
  def valid?
114
104
  warn '[DEPRECATED] the `valid?` method is obsolete'
115
- return false if @name.nil?
116
- return false if @prompt.nil?
105
+ return false if @notification_type.nil?
106
+ return false if @callback_url.nil?
117
107
  true
118
108
  end
119
109
 
120
110
  # Custom attribute writer method with validation
121
- # @param [Object] name Value to be assigned
122
- def name=(name)
123
- if name.nil?
124
- fail ArgumentError, 'name cannot be nil'
111
+ # @param [Object] notification_type Value to be assigned
112
+ def notification_type=(notification_type)
113
+ if notification_type.nil?
114
+ fail ArgumentError, 'notification_type cannot be nil'
125
115
  end
126
116
 
127
- @name = name
117
+ @notification_type = notification_type
128
118
  end
129
119
 
130
120
  # Custom attribute writer method with validation
131
- # @param [Object] prompt Value to be assigned
132
- def prompt=(prompt)
133
- if prompt.nil?
134
- fail ArgumentError, 'prompt cannot be nil'
121
+ # @param [Object] callback_url Value to be assigned
122
+ def callback_url=(callback_url)
123
+ if callback_url.nil?
124
+ fail ArgumentError, 'callback_url cannot be nil'
135
125
  end
136
126
 
137
- @prompt = prompt
127
+ @callback_url = callback_url
138
128
  end
139
129
 
140
130
  # Checks equality by comparing each attribute.
@@ -142,9 +132,8 @@ module Repull
142
132
  def ==(o)
143
133
  return true if self.equal?(o)
144
134
  self.class == o.class &&
145
- name == o.name &&
146
- prompt == o.prompt &&
147
- template_id == o.template_id
135
+ notification_type == o.notification_type &&
136
+ callback_url == o.callback_url
148
137
  end
149
138
 
150
139
  # @see the `==` method
@@ -156,7 +145,7 @@ module Repull
156
145
  # Calculates hash code according to all attributes.
157
146
  # @return [Integer] Hash code
158
147
  def hash
159
- [name, prompt, template_id].hash
148
+ [notification_type, callback_url].hash
160
149
  end
161
150
 
162
151
  # Builds the object from hash
@@ -14,13 +14,13 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Repull
17
- class GenerateStudioCompletion200Response < ApiModelBase
18
- attr_accessor :data
17
+ class DeleteAirbnbListingPhoto200Response < ApiModelBase
18
+ attr_accessor :deleted
19
19
 
20
20
  # Attribute mapping from ruby-style variable name to JSON key.
21
21
  def self.attribute_map
22
22
  {
23
- :'data' => :'data'
23
+ :'deleted' => :'deleted'
24
24
  }
25
25
  end
26
26
 
@@ -37,7 +37,7 @@ module Repull
37
37
  # Attribute type mapping.
38
38
  def self.openapi_types
39
39
  {
40
- :'data' => :'GenerateStudioCompletion200ResponseData'
40
+ :'deleted' => :'Boolean'
41
41
  }
42
42
  end
43
43
 
@@ -51,20 +51,20 @@ module Repull
51
51
  # @param [Hash] attributes Model attributes in the form of hash
52
52
  def initialize(attributes = {})
53
53
  if (!attributes.is_a?(Hash))
54
- fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::GenerateStudioCompletion200Response` initialize method"
54
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::DeleteAirbnbListingPhoto200Response` initialize method"
55
55
  end
56
56
 
57
57
  # check to see if the attribute exists and convert string to symbol for hash key
58
58
  acceptable_attribute_map = self.class.acceptable_attribute_map
59
59
  attributes = attributes.each_with_object({}) { |(k, v), h|
60
60
  if (!acceptable_attribute_map.key?(k.to_sym))
61
- fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::GenerateStudioCompletion200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
61
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::DeleteAirbnbListingPhoto200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
62
62
  end
63
63
  h[k.to_sym] = v
64
64
  }
65
65
 
66
- if attributes.key?(:'data')
67
- self.data = attributes[:'data']
66
+ if attributes.key?(:'deleted')
67
+ self.deleted = attributes[:'deleted']
68
68
  end
69
69
  end
70
70
 
@@ -88,7 +88,7 @@ module Repull
88
88
  def ==(o)
89
89
  return true if self.equal?(o)
90
90
  self.class == o.class &&
91
- data == o.data
91
+ deleted == o.deleted
92
92
  end
93
93
 
94
94
  # @see the `==` method
@@ -100,7 +100,7 @@ module Repull
100
100
  # Calculates hash code according to all attributes.
101
101
  # @return [Integer] Hash code
102
102
  def hash
103
- [data].hash
103
+ [deleted].hash
104
104
  end
105
105
 
106
106
  # Builds the object from hash
@@ -14,13 +14,16 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Repull
17
- class DeleteStudioProject200Response < ApiModelBase
17
+ class GetAirbnbAlteration200Response < ApiModelBase
18
18
  attr_accessor :data
19
19
 
20
+ attr_accessor :data_freshness
21
+
20
22
  # Attribute mapping from ruby-style variable name to JSON key.
21
23
  def self.attribute_map
22
24
  {
23
- :'data' => :'data'
25
+ :'data' => :'data',
26
+ :'data_freshness' => :'data_freshness'
24
27
  }
25
28
  end
26
29
 
@@ -37,7 +40,8 @@ module Repull
37
40
  # Attribute type mapping.
38
41
  def self.openapi_types
39
42
  {
40
- :'data' => :'DeleteStudioProject200ResponseData'
43
+ :'data' => :'AirbnbAlteration',
44
+ :'data_freshness' => :'AirbnbDataFreshness'
41
45
  }
42
46
  end
43
47
 
@@ -51,20 +55,28 @@ module Repull
51
55
  # @param [Hash] attributes Model attributes in the form of hash
52
56
  def initialize(attributes = {})
53
57
  if (!attributes.is_a?(Hash))
54
- fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::DeleteStudioProject200Response` initialize method"
58
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::GetAirbnbAlteration200Response` initialize method"
55
59
  end
56
60
 
57
61
  # check to see if the attribute exists and convert string to symbol for hash key
58
62
  acceptable_attribute_map = self.class.acceptable_attribute_map
59
63
  attributes = attributes.each_with_object({}) { |(k, v), h|
60
64
  if (!acceptable_attribute_map.key?(k.to_sym))
61
- fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::DeleteStudioProject200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
65
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::GetAirbnbAlteration200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
62
66
  end
63
67
  h[k.to_sym] = v
64
68
  }
65
69
 
66
70
  if attributes.key?(:'data')
67
71
  self.data = attributes[:'data']
72
+ else
73
+ self.data = nil
74
+ end
75
+
76
+ if attributes.key?(:'data_freshness')
77
+ self.data_freshness = attributes[:'data_freshness']
78
+ else
79
+ self.data_freshness = nil
68
80
  end
69
81
  end
70
82
 
@@ -73,6 +85,14 @@ module Repull
73
85
  def list_invalid_properties
74
86
  warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
75
87
  invalid_properties = Array.new
88
+ if @data.nil?
89
+ invalid_properties.push('invalid value for "data", data cannot be nil.')
90
+ end
91
+
92
+ if @data_freshness.nil?
93
+ invalid_properties.push('invalid value for "data_freshness", data_freshness cannot be nil.')
94
+ end
95
+
76
96
  invalid_properties
77
97
  end
78
98
 
@@ -80,15 +100,38 @@ module Repull
80
100
  # @return true if the model is valid
81
101
  def valid?
82
102
  warn '[DEPRECATED] the `valid?` method is obsolete'
103
+ return false if @data.nil?
104
+ return false if @data_freshness.nil?
83
105
  true
84
106
  end
85
107
 
108
+ # Custom attribute writer method with validation
109
+ # @param [Object] data Value to be assigned
110
+ def data=(data)
111
+ if data.nil?
112
+ fail ArgumentError, 'data cannot be nil'
113
+ end
114
+
115
+ @data = data
116
+ end
117
+
118
+ # Custom attribute writer method with validation
119
+ # @param [Object] data_freshness Value to be assigned
120
+ def data_freshness=(data_freshness)
121
+ if data_freshness.nil?
122
+ fail ArgumentError, 'data_freshness cannot be nil'
123
+ end
124
+
125
+ @data_freshness = data_freshness
126
+ end
127
+
86
128
  # Checks equality by comparing each attribute.
87
129
  # @param [Object] Object to be compared
88
130
  def ==(o)
89
131
  return true if self.equal?(o)
90
132
  self.class == o.class &&
91
- data == o.data
133
+ data == o.data &&
134
+ data_freshness == o.data_freshness
92
135
  end
93
136
 
94
137
  # @see the `==` method
@@ -100,7 +143,7 @@ module Repull
100
143
  # Calculates hash code according to all attributes.
101
144
  # @return [Integer] Hash code
102
145
  def hash
103
- [data].hash
146
+ [data, data_freshness].hash
104
147
  end
105
148
 
106
149
  # Builds the object from hash
@@ -14,13 +14,17 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Repull
17
- class DeleteStudioProjectFile200Response < ApiModelBase
17
+ class GetAirbnbListingQuality200Response < ApiModelBase
18
+ # Shape depends on `type`: an object `{ standards, issues }` for `all`/`standards`, or an array for `issues`/`stats`.
18
19
  attr_accessor :data
19
20
 
21
+ attr_accessor :data_freshness
22
+
20
23
  # Attribute mapping from ruby-style variable name to JSON key.
21
24
  def self.attribute_map
22
25
  {
23
- :'data' => :'data'
26
+ :'data' => :'data',
27
+ :'data_freshness' => :'data_freshness'
24
28
  }
25
29
  end
26
30
 
@@ -37,13 +41,15 @@ module Repull
37
41
  # Attribute type mapping.
38
42
  def self.openapi_types
39
43
  {
40
- :'data' => :'DeleteStudioProjectFile200ResponseData'
44
+ :'data' => :'Object',
45
+ :'data_freshness' => :'AirbnbDataFreshness'
41
46
  }
42
47
  end
43
48
 
44
49
  # List of attributes with nullable: true
45
50
  def self.openapi_nullable
46
51
  Set.new([
52
+ :'data',
47
53
  ])
48
54
  end
49
55
 
@@ -51,20 +57,28 @@ module Repull
51
57
  # @param [Hash] attributes Model attributes in the form of hash
52
58
  def initialize(attributes = {})
53
59
  if (!attributes.is_a?(Hash))
54
- fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::DeleteStudioProjectFile200Response` initialize method"
60
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::GetAirbnbListingQuality200Response` initialize method"
55
61
  end
56
62
 
57
63
  # check to see if the attribute exists and convert string to symbol for hash key
58
64
  acceptable_attribute_map = self.class.acceptable_attribute_map
59
65
  attributes = attributes.each_with_object({}) { |(k, v), h|
60
66
  if (!acceptable_attribute_map.key?(k.to_sym))
61
- fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::DeleteStudioProjectFile200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::GetAirbnbListingQuality200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
62
68
  end
63
69
  h[k.to_sym] = v
64
70
  }
65
71
 
66
72
  if attributes.key?(:'data')
67
73
  self.data = attributes[:'data']
74
+ else
75
+ self.data = nil
76
+ end
77
+
78
+ if attributes.key?(:'data_freshness')
79
+ self.data_freshness = attributes[:'data_freshness']
80
+ else
81
+ self.data_freshness = nil
68
82
  end
69
83
  end
70
84
 
@@ -73,6 +87,10 @@ module Repull
73
87
  def list_invalid_properties
74
88
  warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
75
89
  invalid_properties = Array.new
90
+ if @data_freshness.nil?
91
+ invalid_properties.push('invalid value for "data_freshness", data_freshness cannot be nil.')
92
+ end
93
+
76
94
  invalid_properties
77
95
  end
78
96
 
@@ -80,15 +98,27 @@ module Repull
80
98
  # @return true if the model is valid
81
99
  def valid?
82
100
  warn '[DEPRECATED] the `valid?` method is obsolete'
101
+ return false if @data_freshness.nil?
83
102
  true
84
103
  end
85
104
 
105
+ # Custom attribute writer method with validation
106
+ # @param [Object] data_freshness Value to be assigned
107
+ def data_freshness=(data_freshness)
108
+ if data_freshness.nil?
109
+ fail ArgumentError, 'data_freshness cannot be nil'
110
+ end
111
+
112
+ @data_freshness = data_freshness
113
+ end
114
+
86
115
  # Checks equality by comparing each attribute.
87
116
  # @param [Object] Object to be compared
88
117
  def ==(o)
89
118
  return true if self.equal?(o)
90
119
  self.class == o.class &&
91
- data == o.data
120
+ data == o.data &&
121
+ data_freshness == o.data_freshness
92
122
  end
93
123
 
94
124
  # @see the `==` method
@@ -100,7 +130,7 @@ module Repull
100
130
  # Calculates hash code according to all attributes.
101
131
  # @return [Integer] Hash code
102
132
  def hash
103
- [data].hash
133
+ [data, data_freshness].hash
104
134
  end
105
135
 
106
136
  # Builds the object from hash
@@ -14,13 +14,17 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Repull
17
- class CreateStudioProjectGeneration201Response < ApiModelBase
17
+ class GetAirbnbListingSettings200Response < ApiModelBase
18
+ # Shape depends on `type`: `{ hosts, locales }` for `all`, or an array for `hosts`/`permits`/`locales`.
18
19
  attr_accessor :data
19
20
 
21
+ attr_accessor :data_freshness
22
+
20
23
  # Attribute mapping from ruby-style variable name to JSON key.
21
24
  def self.attribute_map
22
25
  {
23
- :'data' => :'data'
26
+ :'data' => :'data',
27
+ :'data_freshness' => :'data_freshness'
24
28
  }
25
29
  end
26
30
 
@@ -37,13 +41,15 @@ module Repull
37
41
  # Attribute type mapping.
38
42
  def self.openapi_types
39
43
  {
40
- :'data' => :'CreateStudioProjectGeneration201ResponseData'
44
+ :'data' => :'Object',
45
+ :'data_freshness' => :'AirbnbDataFreshness'
41
46
  }
42
47
  end
43
48
 
44
49
  # List of attributes with nullable: true
45
50
  def self.openapi_nullable
46
51
  Set.new([
52
+ :'data',
47
53
  ])
48
54
  end
49
55
 
@@ -51,20 +57,28 @@ module Repull
51
57
  # @param [Hash] attributes Model attributes in the form of hash
52
58
  def initialize(attributes = {})
53
59
  if (!attributes.is_a?(Hash))
54
- fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::CreateStudioProjectGeneration201Response` initialize method"
60
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Repull::GetAirbnbListingSettings200Response` initialize method"
55
61
  end
56
62
 
57
63
  # check to see if the attribute exists and convert string to symbol for hash key
58
64
  acceptable_attribute_map = self.class.acceptable_attribute_map
59
65
  attributes = attributes.each_with_object({}) { |(k, v), h|
60
66
  if (!acceptable_attribute_map.key?(k.to_sym))
61
- fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::CreateStudioProjectGeneration201Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Repull::GetAirbnbListingSettings200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
62
68
  end
63
69
  h[k.to_sym] = v
64
70
  }
65
71
 
66
72
  if attributes.key?(:'data')
67
73
  self.data = attributes[:'data']
74
+ else
75
+ self.data = nil
76
+ end
77
+
78
+ if attributes.key?(:'data_freshness')
79
+ self.data_freshness = attributes[:'data_freshness']
80
+ else
81
+ self.data_freshness = nil
68
82
  end
69
83
  end
70
84
 
@@ -73,6 +87,10 @@ module Repull
73
87
  def list_invalid_properties
74
88
  warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
75
89
  invalid_properties = Array.new
90
+ if @data_freshness.nil?
91
+ invalid_properties.push('invalid value for "data_freshness", data_freshness cannot be nil.')
92
+ end
93
+
76
94
  invalid_properties
77
95
  end
78
96
 
@@ -80,15 +98,27 @@ module Repull
80
98
  # @return true if the model is valid
81
99
  def valid?
82
100
  warn '[DEPRECATED] the `valid?` method is obsolete'
101
+ return false if @data_freshness.nil?
83
102
  true
84
103
  end
85
104
 
105
+ # Custom attribute writer method with validation
106
+ # @param [Object] data_freshness Value to be assigned
107
+ def data_freshness=(data_freshness)
108
+ if data_freshness.nil?
109
+ fail ArgumentError, 'data_freshness cannot be nil'
110
+ end
111
+
112
+ @data_freshness = data_freshness
113
+ end
114
+
86
115
  # Checks equality by comparing each attribute.
87
116
  # @param [Object] Object to be compared
88
117
  def ==(o)
89
118
  return true if self.equal?(o)
90
119
  self.class == o.class &&
91
- data == o.data
120
+ data == o.data &&
121
+ data_freshness == o.data_freshness
92
122
  end
93
123
 
94
124
  # @see the `==` method
@@ -100,7 +130,7 @@ module Repull
100
130
  # Calculates hash code according to all attributes.
101
131
  # @return [Integer] Hash code
102
132
  def hash
103
- [data].hash
133
+ [data, data_freshness].hash
104
134
  end
105
135
 
106
136
  # Builds the object from hash