relentless_identity 1.0.0

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 (101) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +9 -0
  3. data/README.md +143 -0
  4. data/Rakefile +10 -0
  5. data/docs/AccountApi.md +219 -0
  6. data/docs/AliasInfo.md +20 -0
  7. data/docs/BatchSummary.md +26 -0
  8. data/docs/ClientBackgroundJobDetailResponse.md +30 -0
  9. data/docs/ClientBackgroundJobItemResponse.md +48 -0
  10. data/docs/ClientBackgroundJobPageResponse.md +26 -0
  11. data/docs/ClientBackgroundJobResponse.md +76 -0
  12. data/docs/ClientBatchIdentityResponse.md +20 -0
  13. data/docs/ClientFinderResponse.md +34 -0
  14. data/docs/ClientFinderResponseAlias.md +20 -0
  15. data/docs/ClientIdentityResponse.md +34 -0
  16. data/docs/ClientRequestHistoryItem.md +52 -0
  17. data/docs/ClientRequestHistoryPageResponse.md +26 -0
  18. data/docs/ClientTokenStatusResponse.md +28 -0
  19. data/docs/ClientUsageResponse.md +54 -0
  20. data/docs/ErrorResponse.md +24 -0
  21. data/docs/FinderApi.md +77 -0
  22. data/docs/FinderBatchJobRequest.md +22 -0
  23. data/docs/FinderBatchJobRequestInputsInner.md +20 -0
  24. data/docs/FinderRequest.md +20 -0
  25. data/docs/HTTPValidationError.md +18 -0
  26. data/docs/IdentityProvider.md +20 -0
  27. data/docs/JobsApi.md +529 -0
  28. data/docs/LocationInner.md +15 -0
  29. data/docs/ProbeApi.md +147 -0
  30. data/docs/ProbeBatchJobBackgroundRequest.md +22 -0
  31. data/docs/ProbeBatchRequest.md +18 -0
  32. data/docs/ProbeRequest.md +18 -0
  33. data/docs/ValidationError.md +26 -0
  34. data/git_push.sh +57 -0
  35. data/lib/relentless_identity/api/account_api.rb +225 -0
  36. data/lib/relentless_identity/api/finder_api.rb +90 -0
  37. data/lib/relentless_identity/api/jobs_api.rb +535 -0
  38. data/lib/relentless_identity/api/probe_api.rb +158 -0
  39. data/lib/relentless_identity/api_client.rb +397 -0
  40. data/lib/relentless_identity/api_error.rb +58 -0
  41. data/lib/relentless_identity/api_model_base.rb +88 -0
  42. data/lib/relentless_identity/configuration.rb +309 -0
  43. data/lib/relentless_identity/models/alias_info.rb +159 -0
  44. data/lib/relentless_identity/models/batch_summary.rb +318 -0
  45. data/lib/relentless_identity/models/client_background_job_detail_response.rb +307 -0
  46. data/lib/relentless_identity/models/client_background_job_item_response.rb +455 -0
  47. data/lib/relentless_identity/models/client_background_job_page_response.rb +271 -0
  48. data/lib/relentless_identity/models/client_background_job_response.rb +745 -0
  49. data/lib/relentless_identity/models/client_batch_identity_response.rb +194 -0
  50. data/lib/relentless_identity/models/client_finder_response.rb +285 -0
  51. data/lib/relentless_identity/models/client_finder_response_alias.rb +104 -0
  52. data/lib/relentless_identity/models/client_identity_response.rb +285 -0
  53. data/lib/relentless_identity/models/client_request_history_item.rb +450 -0
  54. data/lib/relentless_identity/models/client_request_history_page_response.rb +271 -0
  55. data/lib/relentless_identity/models/client_token_status_response.rb +259 -0
  56. data/lib/relentless_identity/models/client_usage_response.rb +506 -0
  57. data/lib/relentless_identity/models/error_response.rb +178 -0
  58. data/lib/relentless_identity/models/finder_batch_job_request.rb +206 -0
  59. data/lib/relentless_identity/models/finder_batch_job_request_inputs_inner.rb +192 -0
  60. data/lib/relentless_identity/models/finder_request.rb +193 -0
  61. data/lib/relentless_identity/models/http_validation_error.rb +149 -0
  62. data/lib/relentless_identity/models/identity_provider.rb +157 -0
  63. data/lib/relentless_identity/models/location_inner.rb +103 -0
  64. data/lib/relentless_identity/models/probe_batch_job_background_request.rb +206 -0
  65. data/lib/relentless_identity/models/probe_batch_request.rb +186 -0
  66. data/lib/relentless_identity/models/probe_request.rb +166 -0
  67. data/lib/relentless_identity/models/validation_error.rb +237 -0
  68. data/lib/relentless_identity/version.rb +15 -0
  69. data/lib/relentless_identity.rb +69 -0
  70. data/relentless_identity.gemspec +39 -0
  71. data/spec/api/account_api_spec.rb +72 -0
  72. data/spec/api/finder_api_spec.rb +47 -0
  73. data/spec/api/jobs_api_spec.rb +130 -0
  74. data/spec/api/probe_api_spec.rb +59 -0
  75. data/spec/models/alias_info_spec.rb +42 -0
  76. data/spec/models/batch_summary_spec.rb +60 -0
  77. data/spec/models/client_background_job_detail_response_spec.rb +72 -0
  78. data/spec/models/client_background_job_item_response_spec.rb +138 -0
  79. data/spec/models/client_background_job_page_response_spec.rb +60 -0
  80. data/spec/models/client_background_job_response_spec.rb +222 -0
  81. data/spec/models/client_batch_identity_response_spec.rb +42 -0
  82. data/spec/models/client_finder_response_alias_spec.rb +21 -0
  83. data/spec/models/client_finder_response_spec.rb +92 -0
  84. data/spec/models/client_identity_response_spec.rb +92 -0
  85. data/spec/models/client_request_history_item_spec.rb +150 -0
  86. data/spec/models/client_request_history_page_response_spec.rb +60 -0
  87. data/spec/models/client_token_status_response_spec.rb +70 -0
  88. data/spec/models/client_usage_response_spec.rb +144 -0
  89. data/spec/models/error_response_spec.rb +54 -0
  90. data/spec/models/finder_batch_job_request_inputs_inner_spec.rb +42 -0
  91. data/spec/models/finder_batch_job_request_spec.rb +48 -0
  92. data/spec/models/finder_request_spec.rb +42 -0
  93. data/spec/models/http_validation_error_spec.rb +36 -0
  94. data/spec/models/identity_provider_spec.rb +42 -0
  95. data/spec/models/location_inner_spec.rb +21 -0
  96. data/spec/models/probe_batch_job_background_request_spec.rb +48 -0
  97. data/spec/models/probe_batch_request_spec.rb +36 -0
  98. data/spec/models/probe_request_spec.rb +36 -0
  99. data/spec/models/validation_error_spec.rb +60 -0
  100. data/spec/spec_helper.rb +111 -0
  101. metadata +213 -0
@@ -0,0 +1,285 @@
1
+ =begin
2
+ #Relentless Identity API
3
+
4
+ #Public client API for Finder and Probe workflows. This spec is generated from the FastAPI app, then narrowed to the supported bearer-authenticated routes used by SDKs and the API reference.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.21.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module RelentlessIdentity
17
+ # Compact public result envelope used by Finder and Probe style responses.
18
+ class ClientIdentityResponse < ApiModelBase
19
+ # Final public deliverability verdict.
20
+ attr_accessor :state
21
+
22
+ # Operational outcome. `error` means the verification could not complete cleanly and should not be treated as a negative mailbox verdict.
23
+ attr_accessor :outcome
24
+
25
+ attr_accessor :address
26
+
27
+ # Whether the resolved address is an alias rather than a primary mailbox.
28
+ attr_accessor :is_alias
29
+
30
+ attr_accessor :_alias
31
+
32
+ # Whether the mailbox domain behaved like a catch-all during verification.
33
+ attr_accessor :is_catchall
34
+
35
+ # Identity providers associated with the mailbox domain when available.
36
+ attr_accessor :identity_providers
37
+
38
+ # Observed MX hosts for the mailbox domain.
39
+ attr_accessor :mx_hosts
40
+
41
+ attr_accessor :request_id
42
+
43
+ class EnumAttributeValidator
44
+ attr_reader :datatype
45
+ attr_reader :allowable_values
46
+
47
+ def initialize(datatype, allowable_values)
48
+ @allowable_values = allowable_values.map do |value|
49
+ case datatype.to_s
50
+ when /Integer/i
51
+ value.to_i
52
+ when /Float/i
53
+ value.to_f
54
+ else
55
+ value
56
+ end
57
+ end
58
+ end
59
+
60
+ def valid?(value)
61
+ !value || allowable_values.include?(value)
62
+ end
63
+ end
64
+
65
+ # Attribute mapping from ruby-style variable name to JSON key.
66
+ def self.attribute_map
67
+ {
68
+ :'state' => :'state',
69
+ :'outcome' => :'outcome',
70
+ :'address' => :'address',
71
+ :'is_alias' => :'is_alias',
72
+ :'_alias' => :'alias',
73
+ :'is_catchall' => :'is_catchall',
74
+ :'identity_providers' => :'identity_providers',
75
+ :'mx_hosts' => :'mx_hosts',
76
+ :'request_id' => :'request_id'
77
+ }
78
+ end
79
+
80
+ # Returns attribute mapping this model knows about
81
+ def self.acceptable_attribute_map
82
+ attribute_map
83
+ end
84
+
85
+ # Returns all the JSON keys this model knows about
86
+ def self.acceptable_attributes
87
+ acceptable_attribute_map.values
88
+ end
89
+
90
+ # Attribute type mapping.
91
+ def self.openapi_types
92
+ {
93
+ :'state' => :'String',
94
+ :'outcome' => :'String',
95
+ :'address' => :'String',
96
+ :'is_alias' => :'Boolean',
97
+ :'_alias' => :'ClientFinderResponseAlias',
98
+ :'is_catchall' => :'Boolean',
99
+ :'identity_providers' => :'Array<IdentityProvider>',
100
+ :'mx_hosts' => :'Array<String>',
101
+ :'request_id' => :'String'
102
+ }
103
+ end
104
+
105
+ # List of attributes with nullable: true
106
+ def self.openapi_nullable
107
+ Set.new([
108
+ :'address',
109
+ :'request_id'
110
+ ])
111
+ end
112
+
113
+ # Initializes the object
114
+ # @param [Hash] attributes Model attributes in the form of hash
115
+ def initialize(attributes = {})
116
+ if (!attributes.is_a?(Hash))
117
+ fail ArgumentError, "The input argument (attributes) must be a hash in `RelentlessIdentity::ClientIdentityResponse` initialize method"
118
+ end
119
+
120
+ # check to see if the attribute exists and convert string to symbol for hash key
121
+ acceptable_attribute_map = self.class.acceptable_attribute_map
122
+ attributes = attributes.each_with_object({}) { |(k, v), h|
123
+ if (!acceptable_attribute_map.key?(k.to_sym))
124
+ fail ArgumentError, "`#{k}` is not a valid attribute in `RelentlessIdentity::ClientIdentityResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
125
+ end
126
+ h[k.to_sym] = v
127
+ }
128
+
129
+ if attributes.key?(:'state')
130
+ self.state = attributes[:'state']
131
+ else
132
+ self.state = nil
133
+ end
134
+
135
+ if attributes.key?(:'outcome')
136
+ self.outcome = attributes[:'outcome']
137
+ end
138
+
139
+ if attributes.key?(:'address')
140
+ self.address = attributes[:'address']
141
+ end
142
+
143
+ if attributes.key?(:'is_alias')
144
+ self.is_alias = attributes[:'is_alias']
145
+ end
146
+
147
+ if attributes.key?(:'_alias')
148
+ self._alias = attributes[:'_alias']
149
+ end
150
+
151
+ if attributes.key?(:'is_catchall')
152
+ self.is_catchall = attributes[:'is_catchall']
153
+ end
154
+
155
+ if attributes.key?(:'identity_providers')
156
+ if (value = attributes[:'identity_providers']).is_a?(Array)
157
+ self.identity_providers = value
158
+ end
159
+ end
160
+
161
+ if attributes.key?(:'mx_hosts')
162
+ if (value = attributes[:'mx_hosts']).is_a?(Array)
163
+ self.mx_hosts = value
164
+ end
165
+ end
166
+
167
+ if attributes.key?(:'request_id')
168
+ self.request_id = attributes[:'request_id']
169
+ end
170
+ end
171
+
172
+ # Show invalid properties with the reasons. Usually used together with valid?
173
+ # @return Array for valid properties with the reasons
174
+ def list_invalid_properties
175
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
176
+ invalid_properties = Array.new
177
+ if @state.nil?
178
+ invalid_properties.push('invalid value for "state", state cannot be nil.')
179
+ end
180
+
181
+ invalid_properties
182
+ end
183
+
184
+ # Check to see if the all the properties in the model are valid
185
+ # @return true if the model is valid
186
+ def valid?
187
+ warn '[DEPRECATED] the `valid?` method is obsolete'
188
+ return false if @state.nil?
189
+ state_validator = EnumAttributeValidator.new('String', ["deliverable", "undeliverable"])
190
+ return false unless state_validator.valid?(@state)
191
+ outcome_validator = EnumAttributeValidator.new('String', ["found", "not_found", "error"])
192
+ return false unless outcome_validator.valid?(@outcome)
193
+ true
194
+ end
195
+
196
+ # Custom attribute writer method checking allowed values (enum).
197
+ # @param [Object] state Object to be assigned
198
+ def state=(state)
199
+ validator = EnumAttributeValidator.new('String', ["deliverable", "undeliverable"])
200
+ unless validator.valid?(state)
201
+ fail ArgumentError, "invalid value for \"state\", must be one of #{validator.allowable_values}."
202
+ end
203
+ @state = state
204
+ end
205
+
206
+ # Custom attribute writer method checking allowed values (enum).
207
+ # @param [Object] outcome Object to be assigned
208
+ def outcome=(outcome)
209
+ validator = EnumAttributeValidator.new('String', ["found", "not_found", "error"])
210
+ unless validator.valid?(outcome)
211
+ fail ArgumentError, "invalid value for \"outcome\", must be one of #{validator.allowable_values}."
212
+ end
213
+ @outcome = outcome
214
+ end
215
+
216
+ # Checks equality by comparing each attribute.
217
+ # @param [Object] Object to be compared
218
+ def ==(o)
219
+ return true if self.equal?(o)
220
+ self.class == o.class &&
221
+ state == o.state &&
222
+ outcome == o.outcome &&
223
+ address == o.address &&
224
+ is_alias == o.is_alias &&
225
+ _alias == o._alias &&
226
+ is_catchall == o.is_catchall &&
227
+ identity_providers == o.identity_providers &&
228
+ mx_hosts == o.mx_hosts &&
229
+ request_id == o.request_id
230
+ end
231
+
232
+ # @see the `==` method
233
+ # @param [Object] Object to be compared
234
+ def eql?(o)
235
+ self == o
236
+ end
237
+
238
+ # Calculates hash code according to all attributes.
239
+ # @return [Integer] Hash code
240
+ def hash
241
+ [state, outcome, address, is_alias, _alias, is_catchall, identity_providers, mx_hosts, request_id].hash
242
+ end
243
+
244
+ # Builds the object from hash
245
+ # @param [Hash] attributes Model attributes in the form of hash
246
+ # @return [Object] Returns the model itself
247
+ def self.build_from_hash(attributes)
248
+ return nil unless attributes.is_a?(Hash)
249
+ attributes = attributes.transform_keys(&:to_sym)
250
+ transformed_hash = {}
251
+ openapi_types.each_pair do |key, type|
252
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
253
+ transformed_hash["#{key}"] = nil
254
+ elsif type =~ /\AArray<(.*)>/i
255
+ # check to ensure the input is an array given that the attribute
256
+ # is documented as an array but the input is not
257
+ if attributes[attribute_map[key]].is_a?(Array)
258
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
259
+ end
260
+ elsif !attributes[attribute_map[key]].nil?
261
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
262
+ end
263
+ end
264
+ new(transformed_hash)
265
+ end
266
+
267
+ # Returns the object in the form of hash
268
+ # @return [Hash] Returns the object in the form of hash
269
+ def to_hash
270
+ hash = {}
271
+ self.class.attribute_map.each_pair do |attr, param|
272
+ value = self.send(attr)
273
+ if value.nil?
274
+ is_nullable = self.class.openapi_nullable.include?(attr)
275
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
276
+ end
277
+
278
+ hash[param] = _to_hash(value)
279
+ end
280
+ hash
281
+ end
282
+
283
+ end
284
+
285
+ end