ElasticEmail 4.0.24 → 4.0.26

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 (242) hide show
  1. checksums.yaml +4 -4
  2. data/ElasticEmail.gemspec +1 -1
  3. data/README.md +23 -5
  4. data/VERSION +1 -1
  5. data/docs/CampaignsApi.md +71 -0
  6. data/docs/CertificateValidationStatus.md +15 -0
  7. data/docs/DomainData.md +54 -0
  8. data/docs/DomainDetail.md +52 -0
  9. data/docs/DomainOwner.md +15 -0
  10. data/docs/DomainPayload.md +20 -0
  11. data/docs/DomainUpdatePayload.md +24 -0
  12. data/docs/DomainsApi.md +583 -0
  13. data/docs/EmailStatus.md +3 -1
  14. data/docs/EmailsApi.md +1 -1
  15. data/docs/MessageCategoryEnum.md +15 -0
  16. data/docs/TrackingType.md +15 -0
  17. data/docs/TrackingValidationStatus.md +15 -0
  18. data/lib/ElasticEmail/api/campaigns_api.rb +62 -1
  19. data/lib/ElasticEmail/api/contacts_api.rb +1 -1
  20. data/lib/ElasticEmail/api/domains_api.rb +545 -0
  21. data/lib/ElasticEmail/api/emails_api.rb +3 -3
  22. data/lib/ElasticEmail/api/events_api.rb +1 -1
  23. data/lib/ElasticEmail/api/files_api.rb +1 -1
  24. data/lib/ElasticEmail/api/inbound_route_api.rb +1 -1
  25. data/lib/ElasticEmail/api/lists_api.rb +1 -1
  26. data/lib/ElasticEmail/api/security_api.rb +1 -1
  27. data/lib/ElasticEmail/api/segments_api.rb +1 -1
  28. data/lib/ElasticEmail/api/statistics_api.rb +1 -1
  29. data/lib/ElasticEmail/api/sub_accounts_api.rb +1 -1
  30. data/lib/ElasticEmail/api/suppressions_api.rb +1 -1
  31. data/lib/ElasticEmail/api/templates_api.rb +1 -1
  32. data/lib/ElasticEmail/api/verifications_api.rb +1 -1
  33. data/lib/ElasticEmail/api_client.rb +3 -3
  34. data/lib/ElasticEmail/api_error.rb +1 -1
  35. data/lib/ElasticEmail/configuration.rb +1 -11
  36. data/lib/ElasticEmail/models/access_level.rb +3 -2
  37. data/lib/ElasticEmail/models/account_status_enum.rb +1 -1
  38. data/lib/ElasticEmail/models/api_key.rb +1 -1
  39. data/lib/ElasticEmail/models/api_key_payload.rb +1 -1
  40. data/lib/ElasticEmail/models/body_content_type.rb +1 -1
  41. data/lib/ElasticEmail/models/body_part.rb +1 -1
  42. data/lib/ElasticEmail/models/campaign.rb +1 -1
  43. data/lib/ElasticEmail/models/campaign_options.rb +1 -1
  44. data/lib/ElasticEmail/models/campaign_recipient.rb +1 -1
  45. data/lib/ElasticEmail/models/campaign_status.rb +1 -1
  46. data/lib/ElasticEmail/models/campaign_template.rb +1 -1
  47. data/lib/ElasticEmail/models/certificate_validation_status.rb +42 -0
  48. data/lib/ElasticEmail/models/channel_log_status_summary.rb +1 -1
  49. data/lib/ElasticEmail/models/compression_format.rb +1 -1
  50. data/lib/ElasticEmail/models/consent_data.rb +1 -1
  51. data/lib/ElasticEmail/models/consent_tracking.rb +1 -1
  52. data/lib/ElasticEmail/models/contact.rb +1 -1
  53. data/lib/ElasticEmail/models/contact_activity.rb +1 -1
  54. data/lib/ElasticEmail/models/contact_payload.rb +1 -1
  55. data/lib/ElasticEmail/models/contact_source.rb +1 -1
  56. data/lib/ElasticEmail/models/contact_status.rb +1 -1
  57. data/lib/ElasticEmail/models/contact_update_payload.rb +1 -1
  58. data/lib/ElasticEmail/models/contacts_list.rb +1 -1
  59. data/lib/ElasticEmail/models/delivery_optimization_type.rb +1 -1
  60. data/lib/ElasticEmail/models/domain_data.rb +417 -0
  61. data/lib/ElasticEmail/models/domain_detail.rb +407 -0
  62. data/lib/ElasticEmail/models/domain_owner.rb +40 -0
  63. data/lib/ElasticEmail/models/domain_payload.rb +224 -0
  64. data/lib/ElasticEmail/models/domain_update_payload.rb +265 -0
  65. data/lib/ElasticEmail/models/email_content.rb +1 -1
  66. data/lib/ElasticEmail/models/email_data.rb +1 -1
  67. data/lib/ElasticEmail/models/email_job_failed_status.rb +1 -1
  68. data/lib/ElasticEmail/models/email_job_status.rb +1 -1
  69. data/lib/ElasticEmail/models/email_message_data.rb +1 -1
  70. data/lib/ElasticEmail/models/email_predicted_validation_status.rb +1 -1
  71. data/lib/ElasticEmail/models/email_recipient.rb +1 -1
  72. data/lib/ElasticEmail/models/email_send.rb +1 -1
  73. data/lib/ElasticEmail/models/email_status.rb +16 -5
  74. data/lib/ElasticEmail/models/email_transactional_message_data.rb +1 -1
  75. data/lib/ElasticEmail/models/email_validation_result.rb +1 -1
  76. data/lib/ElasticEmail/models/email_validation_status.rb +1 -1
  77. data/lib/ElasticEmail/models/email_view.rb +1 -1
  78. data/lib/ElasticEmail/models/emails_payload.rb +1 -1
  79. data/lib/ElasticEmail/models/encoding_type.rb +1 -1
  80. data/lib/ElasticEmail/models/event_type.rb +1 -1
  81. data/lib/ElasticEmail/models/events_order_by.rb +1 -1
  82. data/lib/ElasticEmail/models/export_file_formats.rb +1 -1
  83. data/lib/ElasticEmail/models/export_link.rb +1 -1
  84. data/lib/ElasticEmail/models/export_status.rb +1 -1
  85. data/lib/ElasticEmail/models/file_info.rb +1 -1
  86. data/lib/ElasticEmail/models/file_payload.rb +1 -1
  87. data/lib/ElasticEmail/models/file_upload_result.rb +1 -1
  88. data/lib/ElasticEmail/models/inbound_payload.rb +1 -1
  89. data/lib/ElasticEmail/models/inbound_route.rb +1 -1
  90. data/lib/ElasticEmail/models/inbound_route_action_type.rb +1 -1
  91. data/lib/ElasticEmail/models/inbound_route_filter_type.rb +1 -1
  92. data/lib/ElasticEmail/models/list_payload.rb +1 -1
  93. data/lib/ElasticEmail/models/list_update_payload.rb +1 -1
  94. data/lib/ElasticEmail/models/log_job_status.rb +1 -1
  95. data/lib/ElasticEmail/models/log_status_summary.rb +1 -1
  96. data/lib/ElasticEmail/models/merge_email_payload.rb +1 -1
  97. data/lib/ElasticEmail/models/message_attachment.rb +1 -1
  98. data/lib/ElasticEmail/models/message_category.rb +1 -1
  99. data/lib/ElasticEmail/models/message_category_enum.rb +55 -0
  100. data/lib/ElasticEmail/models/new_api_key.rb +1 -1
  101. data/lib/ElasticEmail/models/new_smtp_credentials.rb +1 -1
  102. data/lib/ElasticEmail/models/options.rb +1 -1
  103. data/lib/ElasticEmail/models/recipient_event.rb +1 -1
  104. data/lib/ElasticEmail/models/segment.rb +1 -1
  105. data/lib/ElasticEmail/models/segment_payload.rb +1 -1
  106. data/lib/ElasticEmail/models/smtp_credentials.rb +1 -1
  107. data/lib/ElasticEmail/models/smtp_credentials_payload.rb +1 -1
  108. data/lib/ElasticEmail/models/sort_order_item.rb +1 -1
  109. data/lib/ElasticEmail/models/split_optimization_type.rb +1 -1
  110. data/lib/ElasticEmail/models/split_options.rb +1 -1
  111. data/lib/ElasticEmail/models/sub_account_info.rb +1 -1
  112. data/lib/ElasticEmail/models/subaccount_email_credits_payload.rb +1 -1
  113. data/lib/ElasticEmail/models/subaccount_email_settings.rb +1 -1
  114. data/lib/ElasticEmail/models/subaccount_email_settings_payload.rb +1 -1
  115. data/lib/ElasticEmail/models/subaccount_payload.rb +1 -1
  116. data/lib/ElasticEmail/models/subaccount_settings_info.rb +1 -1
  117. data/lib/ElasticEmail/models/subaccount_settings_info_payload.rb +1 -1
  118. data/lib/ElasticEmail/models/suppression.rb +1 -1
  119. data/lib/ElasticEmail/models/template.rb +1 -1
  120. data/lib/ElasticEmail/models/template_payload.rb +1 -1
  121. data/lib/ElasticEmail/models/template_scope.rb +1 -1
  122. data/lib/ElasticEmail/models/template_type.rb +3 -2
  123. data/lib/ElasticEmail/models/tracking_type.rb +44 -0
  124. data/lib/ElasticEmail/models/tracking_validation_status.rb +42 -0
  125. data/lib/ElasticEmail/models/transactional_recipient.rb +1 -1
  126. data/lib/ElasticEmail/models/utm.rb +1 -1
  127. data/lib/ElasticEmail/models/verification_file_result.rb +1 -1
  128. data/lib/ElasticEmail/models/verification_file_result_details.rb +1 -1
  129. data/lib/ElasticEmail/models/verification_status.rb +1 -1
  130. data/lib/ElasticEmail/version.rb +2 -2
  131. data/lib/ElasticEmail.rb +11 -1
  132. data/spec/api/campaigns_api_spec.rb +13 -1
  133. data/spec/api/contacts_api_spec.rb +1 -1
  134. data/spec/api/domains_api_spec.rb +132 -0
  135. data/spec/api/emails_api_spec.rb +2 -2
  136. data/spec/api/events_api_spec.rb +1 -1
  137. data/spec/api/files_api_spec.rb +1 -1
  138. data/spec/api/inbound_route_api_spec.rb +1 -1
  139. data/spec/api/lists_api_spec.rb +1 -1
  140. data/spec/api/security_api_spec.rb +1 -1
  141. data/spec/api/segments_api_spec.rb +1 -1
  142. data/spec/api/statistics_api_spec.rb +1 -1
  143. data/spec/api/sub_accounts_api_spec.rb +1 -1
  144. data/spec/api/suppressions_api_spec.rb +1 -1
  145. data/spec/api/templates_api_spec.rb +1 -1
  146. data/spec/api/verifications_api_spec.rb +1 -1
  147. data/spec/models/access_level_spec.rb +1 -1
  148. data/spec/models/account_status_enum_spec.rb +1 -1
  149. data/spec/models/api_key_payload_spec.rb +1 -1
  150. data/spec/models/api_key_spec.rb +1 -1
  151. data/spec/models/body_content_type_spec.rb +1 -1
  152. data/spec/models/body_part_spec.rb +1 -1
  153. data/spec/models/campaign_options_spec.rb +1 -1
  154. data/spec/models/campaign_recipient_spec.rb +1 -1
  155. data/spec/models/campaign_spec.rb +1 -1
  156. data/spec/models/campaign_status_spec.rb +1 -1
  157. data/spec/models/campaign_template_spec.rb +1 -1
  158. data/spec/models/certificate_validation_status_spec.rb +30 -0
  159. data/spec/models/channel_log_status_summary_spec.rb +1 -1
  160. data/spec/models/compression_format_spec.rb +1 -1
  161. data/spec/models/consent_data_spec.rb +1 -1
  162. data/spec/models/consent_tracking_spec.rb +1 -1
  163. data/spec/models/contact_activity_spec.rb +1 -1
  164. data/spec/models/contact_payload_spec.rb +1 -1
  165. data/spec/models/contact_source_spec.rb +1 -1
  166. data/spec/models/contact_spec.rb +1 -1
  167. data/spec/models/contact_status_spec.rb +1 -1
  168. data/spec/models/contact_update_payload_spec.rb +1 -1
  169. data/spec/models/contacts_list_spec.rb +1 -1
  170. data/spec/models/delivery_optimization_type_spec.rb +1 -1
  171. data/spec/models/domain_data_spec.rb +144 -0
  172. data/spec/models/domain_detail_spec.rb +138 -0
  173. data/spec/models/domain_owner_spec.rb +30 -0
  174. data/spec/models/domain_payload_spec.rb +42 -0
  175. data/spec/models/domain_update_payload_spec.rb +54 -0
  176. data/spec/models/email_content_spec.rb +1 -1
  177. data/spec/models/email_data_spec.rb +1 -1
  178. data/spec/models/email_job_failed_status_spec.rb +1 -1
  179. data/spec/models/email_job_status_spec.rb +1 -1
  180. data/spec/models/email_message_data_spec.rb +1 -1
  181. data/spec/models/email_predicted_validation_status_spec.rb +1 -1
  182. data/spec/models/email_recipient_spec.rb +1 -1
  183. data/spec/models/email_send_spec.rb +1 -1
  184. data/spec/models/email_status_spec.rb +7 -1
  185. data/spec/models/email_transactional_message_data_spec.rb +1 -1
  186. data/spec/models/email_validation_result_spec.rb +1 -1
  187. data/spec/models/email_validation_status_spec.rb +1 -1
  188. data/spec/models/email_view_spec.rb +1 -1
  189. data/spec/models/emails_payload_spec.rb +1 -1
  190. data/spec/models/encoding_type_spec.rb +1 -1
  191. data/spec/models/event_type_spec.rb +1 -1
  192. data/spec/models/events_order_by_spec.rb +1 -1
  193. data/spec/models/export_file_formats_spec.rb +1 -1
  194. data/spec/models/export_link_spec.rb +1 -1
  195. data/spec/models/export_status_spec.rb +1 -1
  196. data/spec/models/file_info_spec.rb +1 -1
  197. data/spec/models/file_payload_spec.rb +1 -1
  198. data/spec/models/file_upload_result_spec.rb +1 -1
  199. data/spec/models/inbound_payload_spec.rb +1 -1
  200. data/spec/models/inbound_route_action_type_spec.rb +1 -1
  201. data/spec/models/inbound_route_filter_type_spec.rb +1 -1
  202. data/spec/models/inbound_route_spec.rb +1 -1
  203. data/spec/models/list_payload_spec.rb +1 -1
  204. data/spec/models/list_update_payload_spec.rb +1 -1
  205. data/spec/models/log_job_status_spec.rb +1 -1
  206. data/spec/models/log_status_summary_spec.rb +1 -1
  207. data/spec/models/merge_email_payload_spec.rb +1 -1
  208. data/spec/models/message_attachment_spec.rb +1 -1
  209. data/spec/models/message_category_enum_spec.rb +30 -0
  210. data/spec/models/message_category_spec.rb +1 -1
  211. data/spec/models/new_api_key_spec.rb +1 -1
  212. data/spec/models/new_smtp_credentials_spec.rb +1 -1
  213. data/spec/models/options_spec.rb +1 -1
  214. data/spec/models/recipient_event_spec.rb +1 -1
  215. data/spec/models/segment_payload_spec.rb +1 -1
  216. data/spec/models/segment_spec.rb +1 -1
  217. data/spec/models/smtp_credentials_payload_spec.rb +1 -1
  218. data/spec/models/smtp_credentials_spec.rb +1 -1
  219. data/spec/models/sort_order_item_spec.rb +1 -1
  220. data/spec/models/split_optimization_type_spec.rb +1 -1
  221. data/spec/models/split_options_spec.rb +1 -1
  222. data/spec/models/sub_account_info_spec.rb +1 -1
  223. data/spec/models/subaccount_email_credits_payload_spec.rb +1 -1
  224. data/spec/models/subaccount_email_settings_payload_spec.rb +1 -1
  225. data/spec/models/subaccount_email_settings_spec.rb +1 -1
  226. data/spec/models/subaccount_payload_spec.rb +1 -1
  227. data/spec/models/subaccount_settings_info_payload_spec.rb +1 -1
  228. data/spec/models/subaccount_settings_info_spec.rb +1 -1
  229. data/spec/models/suppression_spec.rb +1 -1
  230. data/spec/models/template_payload_spec.rb +1 -1
  231. data/spec/models/template_scope_spec.rb +1 -1
  232. data/spec/models/template_spec.rb +1 -1
  233. data/spec/models/template_type_spec.rb +1 -1
  234. data/spec/models/tracking_type_spec.rb +30 -0
  235. data/spec/models/tracking_validation_status_spec.rb +30 -0
  236. data/spec/models/transactional_recipient_spec.rb +1 -1
  237. data/spec/models/utm_spec.rb +1 -1
  238. data/spec/models/verification_file_result_details_spec.rb +1 -1
  239. data/spec/models/verification_file_result_spec.rb +1 -1
  240. data/spec/models/verification_status_spec.rb +1 -1
  241. data/spec/spec_helper.rb +1 -1
  242. metadata +124 -84
@@ -0,0 +1,265 @@
1
+ =begin
2
+ #Elastic Email REST API
3
+
4
+ #This API is based on the REST API architecture, allowing the user to easily manage their data with this resource-based approach. Every API call is established on which specific request type (GET, POST, PUT, DELETE) will be used. The API has a limit of 20 concurrent connections and a hard timeout of 600 seconds per request. To start using this API, you will need your Access Token (available <a target=\"_blank\" href=\"https://app.elasticemail.com/marketing/settings/new/manage-api\">here</a>). Remember to keep it safe. Required access levels are listed in the given request’s description. Downloadable library clients can be found in our Github repository <a target=\"_blank\" href=\"https://github.com/ElasticEmail?tab=repositories&q=%22rest+api%22+in%3Areadme\">here</a>
5
+
6
+ The version of the OpenAPI document: 4.0.0
7
+ Contact: support@elasticemail.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.5.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module ElasticEmail
17
+ class DomainUpdatePayload
18
+ attr_accessor :certificate_status
19
+
20
+ attr_accessor :verp
21
+
22
+ attr_accessor :custom_bounces_domain
23
+
24
+ attr_accessor :is_custom_bounces_domain_default
25
+
26
+ class EnumAttributeValidator
27
+ attr_reader :datatype
28
+ attr_reader :allowable_values
29
+
30
+ def initialize(datatype, allowable_values)
31
+ @allowable_values = allowable_values.map do |value|
32
+ case datatype.to_s
33
+ when /Integer/i
34
+ value.to_i
35
+ when /Float/i
36
+ value.to_f
37
+ else
38
+ value
39
+ end
40
+ end
41
+ end
42
+
43
+ def valid?(value)
44
+ !value || allowable_values.include?(value)
45
+ end
46
+ end
47
+
48
+ # Attribute mapping from ruby-style variable name to JSON key.
49
+ def self.attribute_map
50
+ {
51
+ :'certificate_status' => :'CertificateStatus',
52
+ :'verp' => :'VERP',
53
+ :'custom_bounces_domain' => :'CustomBouncesDomain',
54
+ :'is_custom_bounces_domain_default' => :'IsCustomBouncesDomainDefault'
55
+ }
56
+ end
57
+
58
+ # Returns all the JSON keys this model knows about
59
+ def self.acceptable_attributes
60
+ attribute_map.values
61
+ end
62
+
63
+ # Attribute type mapping.
64
+ def self.openapi_types
65
+ {
66
+ :'certificate_status' => :'CertificateValidationStatus',
67
+ :'verp' => :'Boolean',
68
+ :'custom_bounces_domain' => :'String',
69
+ :'is_custom_bounces_domain_default' => :'Boolean'
70
+ }
71
+ end
72
+
73
+ # List of attributes with nullable: true
74
+ def self.openapi_nullable
75
+ Set.new([
76
+ ])
77
+ end
78
+
79
+ # Initializes the object
80
+ # @param [Hash] attributes Model attributes in the form of hash
81
+ def initialize(attributes = {})
82
+ if (!attributes.is_a?(Hash))
83
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ElasticEmail::DomainUpdatePayload` initialize method"
84
+ end
85
+
86
+ # check to see if the attribute exists and convert string to symbol for hash key
87
+ attributes = attributes.each_with_object({}) { |(k, v), h|
88
+ if (!self.class.attribute_map.key?(k.to_sym))
89
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::DomainUpdatePayload`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
90
+ end
91
+ h[k.to_sym] = v
92
+ }
93
+
94
+ if attributes.key?(:'certificate_status')
95
+ self.certificate_status = attributes[:'certificate_status']
96
+ else
97
+ self.certificate_status = 'ErrorOccured'
98
+ end
99
+
100
+ if attributes.key?(:'verp')
101
+ self.verp = attributes[:'verp']
102
+ end
103
+
104
+ if attributes.key?(:'custom_bounces_domain')
105
+ self.custom_bounces_domain = attributes[:'custom_bounces_domain']
106
+ end
107
+
108
+ if attributes.key?(:'is_custom_bounces_domain_default')
109
+ self.is_custom_bounces_domain_default = attributes[:'is_custom_bounces_domain_default']
110
+ end
111
+ end
112
+
113
+ # Show invalid properties with the reasons. Usually used together with valid?
114
+ # @return Array for valid properties with the reasons
115
+ def list_invalid_properties
116
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
117
+ invalid_properties = Array.new
118
+ invalid_properties
119
+ end
120
+
121
+ # Check to see if the all the properties in the model are valid
122
+ # @return true if the model is valid
123
+ def valid?
124
+ warn '[DEPRECATED] the `valid?` method is obsolete'
125
+ true
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
+ certificate_status == o.certificate_status &&
134
+ verp == o.verp &&
135
+ custom_bounces_domain == o.custom_bounces_domain &&
136
+ is_custom_bounces_domain_default == o.is_custom_bounces_domain_default
137
+ end
138
+
139
+ # @see the `==` method
140
+ # @param [Object] Object to be compared
141
+ def eql?(o)
142
+ self == o
143
+ end
144
+
145
+ # Calculates hash code according to all attributes.
146
+ # @return [Integer] Hash code
147
+ def hash
148
+ [certificate_status, verp, custom_bounces_domain, is_custom_bounces_domain_default].hash
149
+ end
150
+
151
+ # Builds the object from hash
152
+ # @param [Hash] attributes Model attributes in the form of hash
153
+ # @return [Object] Returns the model itself
154
+ def self.build_from_hash(attributes)
155
+ return nil unless attributes.is_a?(Hash)
156
+ attributes = attributes.transform_keys(&:to_sym)
157
+ transformed_hash = {}
158
+ openapi_types.each_pair do |key, type|
159
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
160
+ transformed_hash["#{key}"] = nil
161
+ elsif type =~ /\AArray<(.*)>/i
162
+ # check to ensure the input is an array given that the attribute
163
+ # is documented as an array but the input is not
164
+ if attributes[attribute_map[key]].is_a?(Array)
165
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
166
+ end
167
+ elsif !attributes[attribute_map[key]].nil?
168
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
169
+ end
170
+ end
171
+ new(transformed_hash)
172
+ end
173
+
174
+ # Deserializes the data based on type
175
+ # @param string type Data type
176
+ # @param string value Value to be deserialized
177
+ # @return [Object] Deserialized data
178
+ def self._deserialize(type, value)
179
+ case type.to_sym
180
+ when :Time
181
+ Time.parse(value)
182
+ when :Date
183
+ Date.parse(value)
184
+ when :String
185
+ value.to_s
186
+ when :Integer
187
+ value.to_i
188
+ when :Float
189
+ value.to_f
190
+ when :Boolean
191
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
192
+ true
193
+ else
194
+ false
195
+ end
196
+ when :Object
197
+ # generic object (usually a Hash), return directly
198
+ value
199
+ when /\AArray<(?<inner_type>.+)>\z/
200
+ inner_type = Regexp.last_match[:inner_type]
201
+ value.map { |v| _deserialize(inner_type, v) }
202
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
203
+ k_type = Regexp.last_match[:k_type]
204
+ v_type = Regexp.last_match[:v_type]
205
+ {}.tap do |hash|
206
+ value.each do |k, v|
207
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
208
+ end
209
+ end
210
+ else # model
211
+ # models (e.g. Pet) or oneOf
212
+ klass = ElasticEmail.const_get(type)
213
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
214
+ end
215
+ end
216
+
217
+ # Returns the string representation of the object
218
+ # @return [String] String presentation of the object
219
+ def to_s
220
+ to_hash.to_s
221
+ end
222
+
223
+ # to_body is an alias to to_hash (backward compatibility)
224
+ # @return [Hash] Returns the object in the form of hash
225
+ def to_body
226
+ to_hash
227
+ end
228
+
229
+ # Returns the object in the form of hash
230
+ # @return [Hash] Returns the object in the form of hash
231
+ def to_hash
232
+ hash = {}
233
+ self.class.attribute_map.each_pair do |attr, param|
234
+ value = self.send(attr)
235
+ if value.nil?
236
+ is_nullable = self.class.openapi_nullable.include?(attr)
237
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
238
+ end
239
+
240
+ hash[param] = _to_hash(value)
241
+ end
242
+ hash
243
+ end
244
+
245
+ # Outputs non-array value in the form of hash
246
+ # For object, use to_hash. Otherwise, just return the value
247
+ # @param [Object] value Any valid value
248
+ # @return [Hash] Returns the value in the form of hash
249
+ def _to_hash(value)
250
+ if value.is_a?(Array)
251
+ value.compact.map { |v| _to_hash(v) }
252
+ elsif value.is_a?(Hash)
253
+ {}.tap do |hash|
254
+ value.each { |k, v| hash[k] = _to_hash(v) }
255
+ end
256
+ elsif value.respond_to? :to_hash
257
+ value.to_hash
258
+ else
259
+ value
260
+ end
261
+ end
262
+
263
+ end
264
+
265
+ end
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -51,6 +51,8 @@ module ElasticEmail
51
51
  # Envelope from address
52
52
  attr_accessor :envelope_from
53
53
 
54
+ attr_accessor :error_category
55
+
54
56
  class EnumAttributeValidator
55
57
  attr_reader :datatype
56
58
  attr_reader :allowable_values
@@ -87,7 +89,8 @@ module ElasticEmail
87
89
  :'date_clicked' => :'DateClicked',
88
90
  :'error_message' => :'ErrorMessage',
89
91
  :'transaction_id' => :'TransactionID',
90
- :'envelope_from' => :'EnvelopeFrom'
92
+ :'envelope_from' => :'EnvelopeFrom',
93
+ :'error_category' => :'ErrorCategory'
91
94
  }
92
95
  end
93
96
 
@@ -110,7 +113,8 @@ module ElasticEmail
110
113
  :'date_clicked' => :'Time',
111
114
  :'error_message' => :'String',
112
115
  :'transaction_id' => :'String',
113
- :'envelope_from' => :'String'
116
+ :'envelope_from' => :'String',
117
+ :'error_category' => :'MessageCategoryEnum'
114
118
  }
115
119
  end
116
120
 
@@ -186,6 +190,12 @@ module ElasticEmail
186
190
  if attributes.key?(:'envelope_from')
187
191
  self.envelope_from = attributes[:'envelope_from']
188
192
  end
193
+
194
+ if attributes.key?(:'error_category')
195
+ self.error_category = attributes[:'error_category']
196
+ else
197
+ self.error_category = 'Unknown'
198
+ end
189
199
  end
190
200
 
191
201
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -219,7 +229,8 @@ module ElasticEmail
219
229
  date_clicked == o.date_clicked &&
220
230
  error_message == o.error_message &&
221
231
  transaction_id == o.transaction_id &&
222
- envelope_from == o.envelope_from
232
+ envelope_from == o.envelope_from &&
233
+ error_category == o.error_category
223
234
  end
224
235
 
225
236
  # @see the `==` method
@@ -231,7 +242,7 @@ module ElasticEmail
231
242
  # Calculates hash code according to all attributes.
232
243
  # @return [Integer] Hash code
233
244
  def hash
234
- [from, to, date, status, status_name, status_change_date, date_sent, date_opened, date_clicked, error_message, transaction_id, envelope_from].hash
245
+ [from, to, date, status, status_name, status_change_date, date_sent, date_opened, date_clicked, error_message, transaction_id, envelope_from, error_category].hash
235
246
  end
236
247
 
237
248
  # Builds the object from hash
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12
 
@@ -6,7 +6,7 @@
6
6
  The version of the OpenAPI document: 4.0.0
7
7
  Contact: support@elasticemail.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.7.0
9
+ Generator version: 7.5.0
10
10
 
11
11
  =end
12
12