late-sdk 0.0.44 → 0.0.45

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 (30) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +0 -11
  3. data/docs/WhatsAppPhoneNumbersApi.md +0 -294
  4. data/lib/late-sdk/api/whats_app_phone_numbers_api.rb +0 -281
  5. data/lib/late-sdk/version.rb +1 -1
  6. data/lib/late-sdk.rb +0 -7
  7. data/openapi.yaml +0 -192
  8. data/spec/api/whats_app_phone_numbers_api_spec.rb +0 -53
  9. metadata +1 -29
  10. data/docs/GetPreverifiedWhatsAppNumbers200Response.md +0 -20
  11. data/docs/GetPreverifiedWhatsAppNumbers200ResponseNumbersInner.md +0 -26
  12. data/docs/RequestWhatsAppVerificationCode200Response.md +0 -20
  13. data/docs/RequestWhatsAppVerificationCodeRequest.md +0 -18
  14. data/docs/SearchAvailableWhatsAppNumbers200Response.md +0 -18
  15. data/docs/VerifyWhatsAppPhoneNumber200Response.md +0 -22
  16. data/docs/VerifyWhatsAppPhoneNumberRequest.md +0 -18
  17. data/lib/late-sdk/models/get_preverified_whats_app_numbers200_response.rb +0 -161
  18. data/lib/late-sdk/models/get_preverified_whats_app_numbers200_response_numbers_inner.rb +0 -183
  19. data/lib/late-sdk/models/request_whats_app_verification_code200_response.rb +0 -190
  20. data/lib/late-sdk/models/request_whats_app_verification_code_request.rb +0 -184
  21. data/lib/late-sdk/models/search_available_whats_app_numbers200_response.rb +0 -149
  22. data/lib/late-sdk/models/verify_whats_app_phone_number200_response.rb +0 -165
  23. data/lib/late-sdk/models/verify_whats_app_phone_number_request.rb +0 -165
  24. data/spec/models/get_preverified_whats_app_numbers200_response_numbers_inner_spec.rb +0 -60
  25. data/spec/models/get_preverified_whats_app_numbers200_response_spec.rb +0 -42
  26. data/spec/models/request_whats_app_verification_code200_response_spec.rb +0 -46
  27. data/spec/models/request_whats_app_verification_code_request_spec.rb +0 -40
  28. data/spec/models/search_available_whats_app_numbers200_response_spec.rb +0 -36
  29. data/spec/models/verify_whats_app_phone_number200_response_spec.rb +0 -48
  30. data/spec/models/verify_whats_app_phone_number_request_spec.rb +0 -36
@@ -1,161 +0,0 @@
1
- =begin
2
- #Late API
3
-
4
- #API reference for Late. Authenticate with a Bearer API key. Base URL: https://getlate.dev/api
5
-
6
- The version of the OpenAPI document: 1.0.1
7
- Contact: support@getlate.dev
8
- Generated by: https://openapi-generator.tech
9
- Generator version: 7.19.0
10
-
11
- =end
12
-
13
- require 'date'
14
- require 'time'
15
-
16
- module Late
17
- class GetPreverifiedWhatsAppNumbers200Response < ApiModelBase
18
- # IDs to pass in FB.login() extras.setup.preVerifiedPhone.ids
19
- attr_accessor :pre_verified_ids
20
-
21
- attr_accessor :numbers
22
-
23
- # Attribute mapping from ruby-style variable name to JSON key.
24
- def self.attribute_map
25
- {
26
- :'pre_verified_ids' => :'preVerifiedIds',
27
- :'numbers' => :'numbers'
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
- :'pre_verified_ids' => :'Array<String>',
45
- :'numbers' => :'Array<GetPreverifiedWhatsAppNumbers200ResponseNumbersInner>'
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 `Late::GetPreverifiedWhatsAppNumbers200Response` 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 `Late::GetPreverifiedWhatsAppNumbers200Response`. 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?(:'pre_verified_ids')
72
- if (value = attributes[:'pre_verified_ids']).is_a?(Array)
73
- self.pre_verified_ids = value
74
- end
75
- end
76
-
77
- if attributes.key?(:'numbers')
78
- if (value = attributes[:'numbers']).is_a?(Array)
79
- self.numbers = value
80
- end
81
- end
82
- end
83
-
84
- # Show invalid properties with the reasons. Usually used together with valid?
85
- # @return Array for valid properties with the reasons
86
- def list_invalid_properties
87
- warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
88
- invalid_properties = Array.new
89
- invalid_properties
90
- end
91
-
92
- # Check to see if the all the properties in the model are valid
93
- # @return true if the model is valid
94
- def valid?
95
- warn '[DEPRECATED] the `valid?` method is obsolete'
96
- true
97
- end
98
-
99
- # Checks equality by comparing each attribute.
100
- # @param [Object] Object to be compared
101
- def ==(o)
102
- return true if self.equal?(o)
103
- self.class == o.class &&
104
- pre_verified_ids == o.pre_verified_ids &&
105
- numbers == o.numbers
106
- end
107
-
108
- # @see the `==` method
109
- # @param [Object] Object to be compared
110
- def eql?(o)
111
- self == o
112
- end
113
-
114
- # Calculates hash code according to all attributes.
115
- # @return [Integer] Hash code
116
- def hash
117
- [pre_verified_ids, numbers].hash
118
- end
119
-
120
- # Builds the object from hash
121
- # @param [Hash] attributes Model attributes in the form of hash
122
- # @return [Object] Returns the model itself
123
- def self.build_from_hash(attributes)
124
- return nil unless attributes.is_a?(Hash)
125
- attributes = attributes.transform_keys(&:to_sym)
126
- transformed_hash = {}
127
- openapi_types.each_pair do |key, type|
128
- if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
129
- transformed_hash["#{key}"] = nil
130
- elsif type =~ /\AArray<(.*)>/i
131
- # check to ensure the input is an array given that the attribute
132
- # is documented as an array but the input is not
133
- if attributes[attribute_map[key]].is_a?(Array)
134
- transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
135
- end
136
- elsif !attributes[attribute_map[key]].nil?
137
- transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
138
- end
139
- end
140
- new(transformed_hash)
141
- end
142
-
143
- # Returns the object in the form of hash
144
- # @return [Hash] Returns the object in the form of hash
145
- def to_hash
146
- hash = {}
147
- self.class.attribute_map.each_pair do |attr, param|
148
- value = self.send(attr)
149
- if value.nil?
150
- is_nullable = self.class.openapi_nullable.include?(attr)
151
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
152
- end
153
-
154
- hash[param] = _to_hash(value)
155
- end
156
- hash
157
- end
158
-
159
- end
160
-
161
- end
@@ -1,183 +0,0 @@
1
- =begin
2
- #Late API
3
-
4
- #API reference for Late. Authenticate with a Bearer API key. Base URL: https://getlate.dev/api
5
-
6
- The version of the OpenAPI document: 1.0.1
7
- Contact: support@getlate.dev
8
- Generated by: https://openapi-generator.tech
9
- Generator version: 7.19.0
10
-
11
- =end
12
-
13
- require 'date'
14
- require 'time'
15
-
16
- module Late
17
- class GetPreverifiedWhatsAppNumbers200ResponseNumbersInner < ApiModelBase
18
- attr_accessor :id
19
-
20
- attr_accessor :phone_number
21
-
22
- attr_accessor :meta_preverified_id
23
-
24
- attr_accessor :meta_verified_at
25
-
26
- attr_accessor :meta_verification_expires_at
27
-
28
- # Attribute mapping from ruby-style variable name to JSON key.
29
- def self.attribute_map
30
- {
31
- :'id' => :'id',
32
- :'phone_number' => :'phoneNumber',
33
- :'meta_preverified_id' => :'metaPreverifiedId',
34
- :'meta_verified_at' => :'metaVerifiedAt',
35
- :'meta_verification_expires_at' => :'metaVerificationExpiresAt'
36
- }
37
- end
38
-
39
- # Returns attribute mapping this model knows about
40
- def self.acceptable_attribute_map
41
- attribute_map
42
- end
43
-
44
- # Returns all the JSON keys this model knows about
45
- def self.acceptable_attributes
46
- acceptable_attribute_map.values
47
- end
48
-
49
- # Attribute type mapping.
50
- def self.openapi_types
51
- {
52
- :'id' => :'String',
53
- :'phone_number' => :'String',
54
- :'meta_preverified_id' => :'String',
55
- :'meta_verified_at' => :'Time',
56
- :'meta_verification_expires_at' => :'Time'
57
- }
58
- end
59
-
60
- # List of attributes with nullable: true
61
- def self.openapi_nullable
62
- Set.new([
63
- ])
64
- end
65
-
66
- # Initializes the object
67
- # @param [Hash] attributes Model attributes in the form of hash
68
- def initialize(attributes = {})
69
- if (!attributes.is_a?(Hash))
70
- fail ArgumentError, "The input argument (attributes) must be a hash in `Late::GetPreverifiedWhatsAppNumbers200ResponseNumbersInner` initialize method"
71
- end
72
-
73
- # check to see if the attribute exists and convert string to symbol for hash key
74
- acceptable_attribute_map = self.class.acceptable_attribute_map
75
- attributes = attributes.each_with_object({}) { |(k, v), h|
76
- if (!acceptable_attribute_map.key?(k.to_sym))
77
- fail ArgumentError, "`#{k}` is not a valid attribute in `Late::GetPreverifiedWhatsAppNumbers200ResponseNumbersInner`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
78
- end
79
- h[k.to_sym] = v
80
- }
81
-
82
- if attributes.key?(:'id')
83
- self.id = attributes[:'id']
84
- end
85
-
86
- if attributes.key?(:'phone_number')
87
- self.phone_number = attributes[:'phone_number']
88
- end
89
-
90
- if attributes.key?(:'meta_preverified_id')
91
- self.meta_preverified_id = attributes[:'meta_preverified_id']
92
- end
93
-
94
- if attributes.key?(:'meta_verified_at')
95
- self.meta_verified_at = attributes[:'meta_verified_at']
96
- end
97
-
98
- if attributes.key?(:'meta_verification_expires_at')
99
- self.meta_verification_expires_at = attributes[:'meta_verification_expires_at']
100
- end
101
- end
102
-
103
- # Show invalid properties with the reasons. Usually used together with valid?
104
- # @return Array for valid properties with the reasons
105
- def list_invalid_properties
106
- warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
107
- invalid_properties = Array.new
108
- invalid_properties
109
- end
110
-
111
- # Check to see if the all the properties in the model are valid
112
- # @return true if the model is valid
113
- def valid?
114
- warn '[DEPRECATED] the `valid?` method is obsolete'
115
- true
116
- end
117
-
118
- # Checks equality by comparing each attribute.
119
- # @param [Object] Object to be compared
120
- def ==(o)
121
- return true if self.equal?(o)
122
- self.class == o.class &&
123
- id == o.id &&
124
- phone_number == o.phone_number &&
125
- meta_preverified_id == o.meta_preverified_id &&
126
- meta_verified_at == o.meta_verified_at &&
127
- meta_verification_expires_at == o.meta_verification_expires_at
128
- end
129
-
130
- # @see the `==` method
131
- # @param [Object] Object to be compared
132
- def eql?(o)
133
- self == o
134
- end
135
-
136
- # Calculates hash code according to all attributes.
137
- # @return [Integer] Hash code
138
- def hash
139
- [id, phone_number, meta_preverified_id, meta_verified_at, meta_verification_expires_at].hash
140
- end
141
-
142
- # Builds the object from hash
143
- # @param [Hash] attributes Model attributes in the form of hash
144
- # @return [Object] Returns the model itself
145
- def self.build_from_hash(attributes)
146
- return nil unless attributes.is_a?(Hash)
147
- attributes = attributes.transform_keys(&:to_sym)
148
- transformed_hash = {}
149
- openapi_types.each_pair do |key, type|
150
- if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
151
- transformed_hash["#{key}"] = nil
152
- elsif type =~ /\AArray<(.*)>/i
153
- # check to ensure the input is an array given that the attribute
154
- # is documented as an array but the input is not
155
- if attributes[attribute_map[key]].is_a?(Array)
156
- transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
157
- end
158
- elsif !attributes[attribute_map[key]].nil?
159
- transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
160
- end
161
- end
162
- new(transformed_hash)
163
- end
164
-
165
- # Returns the object in the form of hash
166
- # @return [Hash] Returns the object in the form of hash
167
- def to_hash
168
- hash = {}
169
- self.class.attribute_map.each_pair do |attr, param|
170
- value = self.send(attr)
171
- if value.nil?
172
- is_nullable = self.class.openapi_nullable.include?(attr)
173
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
174
- end
175
-
176
- hash[param] = _to_hash(value)
177
- end
178
- hash
179
- end
180
-
181
- end
182
-
183
- end
@@ -1,190 +0,0 @@
1
- =begin
2
- #Late API
3
-
4
- #API reference for Late. Authenticate with a Bearer API key. Base URL: https://getlate.dev/api
5
-
6
- The version of the OpenAPI document: 1.0.1
7
- Contact: support@getlate.dev
8
- Generated by: https://openapi-generator.tech
9
- Generator version: 7.19.0
10
-
11
- =end
12
-
13
- require 'date'
14
- require 'time'
15
-
16
- module Late
17
- class RequestWhatsAppVerificationCode200Response < ApiModelBase
18
- attr_accessor :message
19
-
20
- attr_accessor :method
21
-
22
- class EnumAttributeValidator
23
- attr_reader :datatype
24
- attr_reader :allowable_values
25
-
26
- def initialize(datatype, allowable_values)
27
- @allowable_values = allowable_values.map do |value|
28
- case datatype.to_s
29
- when /Integer/i
30
- value.to_i
31
- when /Float/i
32
- value.to_f
33
- else
34
- value
35
- end
36
- end
37
- end
38
-
39
- def valid?(value)
40
- !value || allowable_values.include?(value)
41
- end
42
- end
43
-
44
- # Attribute mapping from ruby-style variable name to JSON key.
45
- def self.attribute_map
46
- {
47
- :'message' => :'message',
48
- :'method' => :'method'
49
- }
50
- end
51
-
52
- # Returns attribute mapping this model knows about
53
- def self.acceptable_attribute_map
54
- attribute_map
55
- end
56
-
57
- # Returns all the JSON keys this model knows about
58
- def self.acceptable_attributes
59
- acceptable_attribute_map.values
60
- end
61
-
62
- # Attribute type mapping.
63
- def self.openapi_types
64
- {
65
- :'message' => :'String',
66
- :'method' => :'String'
67
- }
68
- end
69
-
70
- # List of attributes with nullable: true
71
- def self.openapi_nullable
72
- Set.new([
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 `Late::RequestWhatsAppVerificationCode200Response` 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 `Late::RequestWhatsAppVerificationCode200Response`. 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?(:'message')
93
- self.message = attributes[:'message']
94
- end
95
-
96
- if attributes.key?(:'method')
97
- self.method = attributes[:'method']
98
- end
99
- end
100
-
101
- # Show invalid properties with the reasons. Usually used together with valid?
102
- # @return Array for valid properties with the reasons
103
- def list_invalid_properties
104
- warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
105
- invalid_properties = Array.new
106
- invalid_properties
107
- end
108
-
109
- # Check to see if the all the properties in the model are valid
110
- # @return true if the model is valid
111
- def valid?
112
- warn '[DEPRECATED] the `valid?` method is obsolete'
113
- method_validator = EnumAttributeValidator.new('String', ["SMS", "VOICE"])
114
- return false unless method_validator.valid?(@method)
115
- true
116
- end
117
-
118
- # Custom attribute writer method checking allowed values (enum).
119
- # @param [Object] method Object to be assigned
120
- def method=(method)
121
- validator = EnumAttributeValidator.new('String', ["SMS", "VOICE"])
122
- unless validator.valid?(method)
123
- fail ArgumentError, "invalid value for \"method\", must be one of #{validator.allowable_values}."
124
- end
125
- @method = method
126
- end
127
-
128
- # Checks equality by comparing each attribute.
129
- # @param [Object] Object to be compared
130
- def ==(o)
131
- return true if self.equal?(o)
132
- self.class == o.class &&
133
- message == o.message &&
134
- method == o.method
135
- end
136
-
137
- # @see the `==` method
138
- # @param [Object] Object to be compared
139
- def eql?(o)
140
- self == o
141
- end
142
-
143
- # Calculates hash code according to all attributes.
144
- # @return [Integer] Hash code
145
- def hash
146
- [message, method].hash
147
- end
148
-
149
- # Builds the object from hash
150
- # @param [Hash] attributes Model attributes in the form of hash
151
- # @return [Object] Returns the model itself
152
- def self.build_from_hash(attributes)
153
- return nil unless attributes.is_a?(Hash)
154
- attributes = attributes.transform_keys(&:to_sym)
155
- transformed_hash = {}
156
- openapi_types.each_pair do |key, type|
157
- if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
158
- transformed_hash["#{key}"] = nil
159
- elsif type =~ /\AArray<(.*)>/i
160
- # check to ensure the input is an array given that the attribute
161
- # is documented as an array but the input is not
162
- if attributes[attribute_map[key]].is_a?(Array)
163
- transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
164
- end
165
- elsif !attributes[attribute_map[key]].nil?
166
- transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
167
- end
168
- end
169
- new(transformed_hash)
170
- end
171
-
172
- # Returns the object in the form of hash
173
- # @return [Hash] Returns the object in the form of hash
174
- def to_hash
175
- hash = {}
176
- self.class.attribute_map.each_pair do |attr, param|
177
- value = self.send(attr)
178
- if value.nil?
179
- is_nullable = self.class.openapi_nullable.include?(attr)
180
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
181
- end
182
-
183
- hash[param] = _to_hash(value)
184
- end
185
- hash
186
- end
187
-
188
- end
189
-
190
- end