ElasticEmail 4.0.27 → 4.0.29

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 (253) hide show
  1. checksums.yaml +4 -4
  2. data/ElasticEmail.gemspec +1 -1
  3. data/README.md +21 -9
  4. data/VERSION +1 -1
  5. data/docs/CampaignOptions.md +3 -1
  6. data/docs/CampaignTemplate.md +2 -2
  7. data/docs/CampaignsApi.md +73 -0
  8. data/docs/DKIMRecord.md +26 -0
  9. data/docs/DomainData.md +7 -1
  10. data/docs/DomainDetail.md +7 -1
  11. data/docs/EmailContent.md +2 -2
  12. data/docs/MessageAttachment.md +2 -2
  13. data/docs/SecurityApi.md +4 -4
  14. data/docs/SubAccountsApi.md +73 -1
  15. data/docs/Webhook.md +42 -0
  16. data/docs/WebhookApi.md +372 -0
  17. data/docs/WebhookCreatePayload.md +34 -0
  18. data/docs/WebhookUpdatePayload.md +36 -0
  19. data/lib/ElasticEmail/api/campaigns_api.rb +69 -1
  20. data/lib/ElasticEmail/api/contacts_api.rb +1 -1
  21. data/lib/ElasticEmail/api/domains_api.rb +1 -1
  22. data/lib/ElasticEmail/api/emails_api.rb +1 -1
  23. data/lib/ElasticEmail/api/events_api.rb +1 -1
  24. data/lib/ElasticEmail/api/files_api.rb +1 -1
  25. data/lib/ElasticEmail/api/inbound_route_api.rb +1 -1
  26. data/lib/ElasticEmail/api/lists_api.rb +1 -1
  27. data/lib/ElasticEmail/api/security_api.rb +5 -5
  28. data/lib/ElasticEmail/api/segments_api.rb +1 -1
  29. data/lib/ElasticEmail/api/statistics_api.rb +1 -1
  30. data/lib/ElasticEmail/api/sub_accounts_api.rb +66 -3
  31. data/lib/ElasticEmail/api/suppressions_api.rb +1 -1
  32. data/lib/ElasticEmail/api/templates_api.rb +1 -1
  33. data/lib/ElasticEmail/api/verifications_api.rb +1 -1
  34. data/lib/ElasticEmail/api/webhook_api.rb +351 -0
  35. data/lib/ElasticEmail/api_client.rb +8 -9
  36. data/lib/ElasticEmail/api_error.rb +1 -1
  37. data/lib/ElasticEmail/configuration.rb +1 -1
  38. data/lib/ElasticEmail/models/access_level.rb +1 -1
  39. data/lib/ElasticEmail/models/account_status_enum.rb +1 -1
  40. data/lib/ElasticEmail/models/api_key.rb +10 -4
  41. data/lib/ElasticEmail/models/api_key_payload.rb +30 -4
  42. data/lib/ElasticEmail/models/body_content_type.rb +1 -1
  43. data/lib/ElasticEmail/models/body_part.rb +20 -4
  44. data/lib/ElasticEmail/models/campaign.rb +30 -4
  45. data/lib/ElasticEmail/models/campaign_options.rb +25 -8
  46. data/lib/ElasticEmail/models/campaign_recipient.rb +10 -4
  47. data/lib/ElasticEmail/models/campaign_status.rb +1 -1
  48. data/lib/ElasticEmail/models/campaign_template.rb +21 -5
  49. data/lib/ElasticEmail/models/certificate_validation_status.rb +3 -2
  50. data/lib/ElasticEmail/models/channel_log_status_summary.rb +10 -4
  51. data/lib/ElasticEmail/models/compression_format.rb +1 -1
  52. data/lib/ElasticEmail/models/consent_data.rb +10 -4
  53. data/lib/ElasticEmail/models/consent_tracking.rb +1 -1
  54. data/lib/ElasticEmail/models/contact.rb +10 -4
  55. data/lib/ElasticEmail/models/contact_activity.rb +10 -4
  56. data/lib/ElasticEmail/models/contact_payload.rb +20 -4
  57. data/lib/ElasticEmail/models/contact_source.rb +1 -1
  58. data/lib/ElasticEmail/models/contact_status.rb +1 -1
  59. data/lib/ElasticEmail/models/contact_update_payload.rb +10 -4
  60. data/lib/ElasticEmail/models/contacts_list.rb +10 -4
  61. data/lib/ElasticEmail/models/delivery_optimization_type.rb +1 -1
  62. data/lib/ElasticEmail/models/dkim_record.rb +258 -0
  63. data/lib/ElasticEmail/models/domain_data.rb +42 -8
  64. data/lib/ElasticEmail/models/domain_detail.rb +42 -8
  65. data/lib/ElasticEmail/models/domain_owner.rb +1 -1
  66. data/lib/ElasticEmail/models/domain_payload.rb +10 -4
  67. data/lib/ElasticEmail/models/domain_update_payload.rb +10 -4
  68. data/lib/ElasticEmail/models/email_content.rb +21 -5
  69. data/lib/ElasticEmail/models/email_data.rb +10 -4
  70. data/lib/ElasticEmail/models/email_job_failed_status.rb +10 -4
  71. data/lib/ElasticEmail/models/email_job_status.rb +10 -4
  72. data/lib/ElasticEmail/models/email_message_data.rb +30 -4
  73. data/lib/ElasticEmail/models/email_predicted_validation_status.rb +1 -1
  74. data/lib/ElasticEmail/models/email_recipient.rb +20 -4
  75. data/lib/ElasticEmail/models/email_send.rb +10 -4
  76. data/lib/ElasticEmail/models/email_status.rb +10 -4
  77. data/lib/ElasticEmail/models/email_transactional_message_data.rb +30 -4
  78. data/lib/ElasticEmail/models/email_validation_result.rb +10 -4
  79. data/lib/ElasticEmail/models/email_validation_status.rb +1 -1
  80. data/lib/ElasticEmail/models/email_view.rb +10 -4
  81. data/lib/ElasticEmail/models/emails_payload.rb +10 -4
  82. data/lib/ElasticEmail/models/encoding_type.rb +1 -1
  83. data/lib/ElasticEmail/models/event_type.rb +6 -3
  84. data/lib/ElasticEmail/models/events_order_by.rb +1 -1
  85. data/lib/ElasticEmail/models/export_file_formats.rb +1 -1
  86. data/lib/ElasticEmail/models/export_link.rb +10 -4
  87. data/lib/ElasticEmail/models/export_status.rb +1 -1
  88. data/lib/ElasticEmail/models/file_info.rb +10 -4
  89. data/lib/ElasticEmail/models/file_payload.rb +20 -4
  90. data/lib/ElasticEmail/models/file_upload_result.rb +10 -4
  91. data/lib/ElasticEmail/models/inbound_payload.rb +50 -4
  92. data/lib/ElasticEmail/models/inbound_route.rb +10 -4
  93. data/lib/ElasticEmail/models/inbound_route_action_type.rb +1 -1
  94. data/lib/ElasticEmail/models/inbound_route_filter_type.rb +1 -1
  95. data/lib/ElasticEmail/models/list_payload.rb +20 -4
  96. data/lib/ElasticEmail/models/list_update_payload.rb +10 -4
  97. data/lib/ElasticEmail/models/log_job_status.rb +1 -1
  98. data/lib/ElasticEmail/models/log_status_summary.rb +10 -4
  99. data/lib/ElasticEmail/models/merge_email_payload.rb +30 -4
  100. data/lib/ElasticEmail/models/message_attachment.rb +31 -5
  101. data/lib/ElasticEmail/models/message_category.rb +1 -1
  102. data/lib/ElasticEmail/models/message_category_enum.rb +1 -1
  103. data/lib/ElasticEmail/models/new_api_key.rb +10 -4
  104. data/lib/ElasticEmail/models/new_smtp_credentials.rb +10 -4
  105. data/lib/ElasticEmail/models/options.rb +10 -4
  106. data/lib/ElasticEmail/models/recipient_event.rb +10 -4
  107. data/lib/ElasticEmail/models/segment.rb +10 -4
  108. data/lib/ElasticEmail/models/segment_payload.rb +30 -4
  109. data/lib/ElasticEmail/models/smtp_credentials.rb +10 -4
  110. data/lib/ElasticEmail/models/smtp_credentials_payload.rb +20 -4
  111. data/lib/ElasticEmail/models/sort_order_item.rb +30 -4
  112. data/lib/ElasticEmail/models/split_optimization_type.rb +1 -1
  113. data/lib/ElasticEmail/models/split_options.rb +10 -4
  114. data/lib/ElasticEmail/models/sub_account_info.rb +10 -4
  115. data/lib/ElasticEmail/models/subaccount_email_credits_payload.rb +20 -4
  116. data/lib/ElasticEmail/models/subaccount_email_settings.rb +10 -4
  117. data/lib/ElasticEmail/models/subaccount_email_settings_payload.rb +10 -4
  118. data/lib/ElasticEmail/models/subaccount_payload.rb +30 -4
  119. data/lib/ElasticEmail/models/subaccount_settings_info.rb +10 -4
  120. data/lib/ElasticEmail/models/subaccount_settings_info_payload.rb +10 -4
  121. data/lib/ElasticEmail/models/suppression.rb +10 -4
  122. data/lib/ElasticEmail/models/template.rb +10 -4
  123. data/lib/ElasticEmail/models/template_payload.rb +20 -4
  124. data/lib/ElasticEmail/models/template_scope.rb +1 -1
  125. data/lib/ElasticEmail/models/template_type.rb +1 -1
  126. data/lib/ElasticEmail/models/tracking_type.rb +1 -1
  127. data/lib/ElasticEmail/models/tracking_validation_status.rb +1 -1
  128. data/lib/ElasticEmail/models/transactional_recipient.rb +20 -4
  129. data/lib/ElasticEmail/models/utm.rb +10 -4
  130. data/lib/ElasticEmail/models/verification_file_result.rb +10 -4
  131. data/lib/ElasticEmail/models/verification_file_result_details.rb +10 -4
  132. data/lib/ElasticEmail/models/verification_status.rb +1 -1
  133. data/lib/ElasticEmail/models/webhook.rb +336 -0
  134. data/lib/ElasticEmail/models/webhook_create_payload.rb +329 -0
  135. data/lib/ElasticEmail/models/webhook_update_payload.rb +312 -0
  136. data/lib/ElasticEmail/version.rb +2 -2
  137. data/lib/ElasticEmail.rb +6 -1
  138. data/spec/api/campaigns_api_spec.rb +14 -1
  139. data/spec/api/contacts_api_spec.rb +1 -1
  140. data/spec/api/domains_api_spec.rb +1 -1
  141. data/spec/api/emails_api_spec.rb +1 -1
  142. data/spec/api/events_api_spec.rb +1 -1
  143. data/spec/api/files_api_spec.rb +1 -1
  144. data/spec/api/inbound_route_api_spec.rb +1 -1
  145. data/spec/api/lists_api_spec.rb +1 -1
  146. data/spec/api/security_api_spec.rb +3 -3
  147. data/spec/api/segments_api_spec.rb +1 -1
  148. data/spec/api/statistics_api_spec.rb +1 -1
  149. data/spec/api/sub_accounts_api_spec.rb +14 -2
  150. data/spec/api/suppressions_api_spec.rb +1 -1
  151. data/spec/api/templates_api_spec.rb +1 -1
  152. data/spec/api/verifications_api_spec.rb +1 -1
  153. data/spec/api/webhook_api_spec.rb +97 -0
  154. data/spec/models/access_level_spec.rb +1 -1
  155. data/spec/models/account_status_enum_spec.rb +1 -1
  156. data/spec/models/api_key_payload_spec.rb +1 -1
  157. data/spec/models/api_key_spec.rb +1 -1
  158. data/spec/models/body_content_type_spec.rb +1 -1
  159. data/spec/models/body_part_spec.rb +1 -1
  160. data/spec/models/campaign_options_spec.rb +7 -1
  161. data/spec/models/campaign_recipient_spec.rb +1 -1
  162. data/spec/models/campaign_spec.rb +1 -1
  163. data/spec/models/campaign_status_spec.rb +1 -1
  164. data/spec/models/campaign_template_spec.rb +1 -1
  165. data/spec/models/certificate_validation_status_spec.rb +1 -1
  166. data/spec/models/channel_log_status_summary_spec.rb +1 -1
  167. data/spec/models/compression_format_spec.rb +1 -1
  168. data/spec/models/consent_data_spec.rb +1 -1
  169. data/spec/models/consent_tracking_spec.rb +1 -1
  170. data/spec/models/contact_activity_spec.rb +1 -1
  171. data/spec/models/contact_payload_spec.rb +1 -1
  172. data/spec/models/contact_source_spec.rb +1 -1
  173. data/spec/models/contact_spec.rb +1 -1
  174. data/spec/models/contact_status_spec.rb +1 -1
  175. data/spec/models/contact_update_payload_spec.rb +1 -1
  176. data/spec/models/contacts_list_spec.rb +1 -1
  177. data/spec/models/delivery_optimization_type_spec.rb +1 -1
  178. data/spec/models/dkim_record_spec.rb +60 -0
  179. data/spec/models/domain_data_spec.rb +19 -1
  180. data/spec/models/domain_detail_spec.rb +19 -1
  181. data/spec/models/domain_owner_spec.rb +1 -1
  182. data/spec/models/domain_payload_spec.rb +1 -1
  183. data/spec/models/domain_update_payload_spec.rb +1 -1
  184. data/spec/models/email_content_spec.rb +1 -1
  185. data/spec/models/email_data_spec.rb +1 -1
  186. data/spec/models/email_job_failed_status_spec.rb +1 -1
  187. data/spec/models/email_job_status_spec.rb +1 -1
  188. data/spec/models/email_message_data_spec.rb +1 -1
  189. data/spec/models/email_predicted_validation_status_spec.rb +1 -1
  190. data/spec/models/email_recipient_spec.rb +1 -1
  191. data/spec/models/email_send_spec.rb +1 -1
  192. data/spec/models/email_status_spec.rb +1 -1
  193. data/spec/models/email_transactional_message_data_spec.rb +1 -1
  194. data/spec/models/email_validation_result_spec.rb +1 -1
  195. data/spec/models/email_validation_status_spec.rb +1 -1
  196. data/spec/models/email_view_spec.rb +1 -1
  197. data/spec/models/emails_payload_spec.rb +1 -1
  198. data/spec/models/encoding_type_spec.rb +1 -1
  199. data/spec/models/event_type_spec.rb +1 -1
  200. data/spec/models/events_order_by_spec.rb +1 -1
  201. data/spec/models/export_file_formats_spec.rb +1 -1
  202. data/spec/models/export_link_spec.rb +1 -1
  203. data/spec/models/export_status_spec.rb +1 -1
  204. data/spec/models/file_info_spec.rb +1 -1
  205. data/spec/models/file_payload_spec.rb +1 -1
  206. data/spec/models/file_upload_result_spec.rb +1 -1
  207. data/spec/models/inbound_payload_spec.rb +1 -1
  208. data/spec/models/inbound_route_action_type_spec.rb +1 -1
  209. data/spec/models/inbound_route_filter_type_spec.rb +1 -1
  210. data/spec/models/inbound_route_spec.rb +1 -1
  211. data/spec/models/list_payload_spec.rb +1 -1
  212. data/spec/models/list_update_payload_spec.rb +1 -1
  213. data/spec/models/log_job_status_spec.rb +1 -1
  214. data/spec/models/log_status_summary_spec.rb +1 -1
  215. data/spec/models/merge_email_payload_spec.rb +1 -1
  216. data/spec/models/message_attachment_spec.rb +1 -1
  217. data/spec/models/message_category_enum_spec.rb +1 -1
  218. data/spec/models/message_category_spec.rb +1 -1
  219. data/spec/models/new_api_key_spec.rb +1 -1
  220. data/spec/models/new_smtp_credentials_spec.rb +1 -1
  221. data/spec/models/options_spec.rb +1 -1
  222. data/spec/models/recipient_event_spec.rb +1 -1
  223. data/spec/models/segment_payload_spec.rb +1 -1
  224. data/spec/models/segment_spec.rb +1 -1
  225. data/spec/models/smtp_credentials_payload_spec.rb +1 -1
  226. data/spec/models/smtp_credentials_spec.rb +1 -1
  227. data/spec/models/sort_order_item_spec.rb +1 -1
  228. data/spec/models/split_optimization_type_spec.rb +1 -1
  229. data/spec/models/split_options_spec.rb +1 -1
  230. data/spec/models/sub_account_info_spec.rb +1 -1
  231. data/spec/models/subaccount_email_credits_payload_spec.rb +1 -1
  232. data/spec/models/subaccount_email_settings_payload_spec.rb +1 -1
  233. data/spec/models/subaccount_email_settings_spec.rb +1 -1
  234. data/spec/models/subaccount_payload_spec.rb +1 -1
  235. data/spec/models/subaccount_settings_info_payload_spec.rb +1 -1
  236. data/spec/models/subaccount_settings_info_spec.rb +1 -1
  237. data/spec/models/suppression_spec.rb +1 -1
  238. data/spec/models/template_payload_spec.rb +1 -1
  239. data/spec/models/template_scope_spec.rb +1 -1
  240. data/spec/models/template_spec.rb +1 -1
  241. data/spec/models/template_type_spec.rb +1 -1
  242. data/spec/models/tracking_type_spec.rb +1 -1
  243. data/spec/models/tracking_validation_status_spec.rb +1 -1
  244. data/spec/models/transactional_recipient_spec.rb +1 -1
  245. data/spec/models/utm_spec.rb +1 -1
  246. data/spec/models/verification_file_result_details_spec.rb +1 -1
  247. data/spec/models/verification_file_result_spec.rb +1 -1
  248. data/spec/models/verification_status_spec.rb +1 -1
  249. data/spec/models/webhook_create_payload_spec.rb +84 -0
  250. data/spec/models/webhook_spec.rb +108 -0
  251. data/spec/models/webhook_update_payload_spec.rb +90 -0
  252. data/spec/spec_helper.rb +1 -1
  253. metadata +109 -89
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -37,7 +37,7 @@ module ElasticEmail
37
37
  # Your e-mail with an optional name (e.g.: John Doe <email@domain.com>)
38
38
  attr_accessor :from
39
39
 
40
- # To what address should the recipients reply to (e.g. John Doe <email@domain.com>)
40
+ # To what addresses should the recipients reply to (e.g. John Doe <email@domain.com>)
41
41
  attr_accessor :reply_to
42
42
 
43
43
  # Default subject of email.
@@ -69,9 +69,14 @@ module ElasticEmail
69
69
  }
70
70
  end
71
71
 
72
+ # Returns attribute mapping this model knows about
73
+ def self.acceptable_attribute_map
74
+ attribute_map
75
+ end
76
+
72
77
  # Returns all the JSON keys this model knows about
73
78
  def self.acceptable_attributes
74
- attribute_map.values
79
+ acceptable_attribute_map.values
75
80
  end
76
81
 
77
82
  # Attribute type mapping.
@@ -106,9 +111,10 @@ module ElasticEmail
106
111
  end
107
112
 
108
113
  # check to see if the attribute exists and convert string to symbol for hash key
114
+ acceptable_attribute_map = self.class.acceptable_attribute_map
109
115
  attributes = attributes.each_with_object({}) { |(k, v), h|
110
- if (!self.class.attribute_map.key?(k.to_sym))
111
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailContent`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
116
+ if (!acceptable_attribute_map.key?(k.to_sym))
117
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailContent`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
112
118
  end
113
119
  h[k.to_sym] = v
114
120
  }
@@ -194,6 +200,16 @@ module ElasticEmail
194
200
  true
195
201
  end
196
202
 
203
+ # Custom attribute writer method with validation
204
+ # @param [Object] from Value to be assigned
205
+ def from=(from)
206
+ if from.nil?
207
+ fail ArgumentError, 'from cannot be nil'
208
+ end
209
+
210
+ @from = from
211
+ end
212
+
197
213
  # Checks equality by comparing each attribute.
198
214
  # @param [Object] Object to be compared
199
215
  def ==(o)
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -31,9 +31,14 @@ module ElasticEmail
31
31
  }
32
32
  end
33
33
 
34
+ # Returns attribute mapping this model knows about
35
+ def self.acceptable_attribute_map
36
+ attribute_map
37
+ end
38
+
34
39
  # Returns all the JSON keys this model knows about
35
40
  def self.acceptable_attributes
36
- attribute_map.values
41
+ acceptable_attribute_map.values
37
42
  end
38
43
 
39
44
  # Attribute type mapping.
@@ -59,9 +64,10 @@ module ElasticEmail
59
64
  end
60
65
 
61
66
  # check to see if the attribute exists and convert string to symbol for hash key
67
+ acceptable_attribute_map = self.class.acceptable_attribute_map
62
68
  attributes = attributes.each_with_object({}) { |(k, v), h|
63
- if (!self.class.attribute_map.key?(k.to_sym))
64
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
69
+ if (!acceptable_attribute_map.key?(k.to_sym))
70
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailData`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
65
71
  end
66
72
  h[k.to_sym] = v
67
73
  }
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -34,9 +34,14 @@ module ElasticEmail
34
34
  }
35
35
  end
36
36
 
37
+ # Returns attribute mapping this model knows about
38
+ def self.acceptable_attribute_map
39
+ attribute_map
40
+ end
41
+
37
42
  # Returns all the JSON keys this model knows about
38
43
  def self.acceptable_attributes
39
- attribute_map.values
44
+ acceptable_attribute_map.values
40
45
  end
41
46
 
42
47
  # Attribute type mapping.
@@ -63,9 +68,10 @@ module ElasticEmail
63
68
  end
64
69
 
65
70
  # check to see if the attribute exists and convert string to symbol for hash key
71
+ acceptable_attribute_map = self.class.acceptable_attribute_map
66
72
  attributes = attributes.each_with_object({}) { |(k, v), h|
67
- if (!self.class.attribute_map.key?(k.to_sym))
68
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailJobFailedStatus`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
73
+ if (!acceptable_attribute_map.key?(k.to_sym))
74
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailJobFailedStatus`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
69
75
  end
70
76
  h[k.to_sym] = v
71
77
  }
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -93,9 +93,14 @@ module ElasticEmail
93
93
  }
94
94
  end
95
95
 
96
+ # Returns attribute mapping this model knows about
97
+ def self.acceptable_attribute_map
98
+ attribute_map
99
+ end
100
+
96
101
  # Returns all the JSON keys this model knows about
97
102
  def self.acceptable_attributes
98
- attribute_map.values
103
+ acceptable_attribute_map.values
99
104
  end
100
105
 
101
106
  # Attribute type mapping.
@@ -138,9 +143,10 @@ module ElasticEmail
138
143
  end
139
144
 
140
145
  # check to see if the attribute exists and convert string to symbol for hash key
146
+ acceptable_attribute_map = self.class.acceptable_attribute_map
141
147
  attributes = attributes.each_with_object({}) { |(k, v), h|
142
- if (!self.class.attribute_map.key?(k.to_sym))
143
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailJobStatus`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
148
+ if (!acceptable_attribute_map.key?(k.to_sym))
149
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailJobStatus`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
144
150
  end
145
151
  h[k.to_sym] = v
146
152
  }
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -32,9 +32,14 @@ module ElasticEmail
32
32
  }
33
33
  end
34
34
 
35
+ # Returns attribute mapping this model knows about
36
+ def self.acceptable_attribute_map
37
+ attribute_map
38
+ end
39
+
35
40
  # Returns all the JSON keys this model knows about
36
41
  def self.acceptable_attributes
37
- attribute_map.values
42
+ acceptable_attribute_map.values
38
43
  end
39
44
 
40
45
  # Attribute type mapping.
@@ -60,9 +65,10 @@ module ElasticEmail
60
65
  end
61
66
 
62
67
  # check to see if the attribute exists and convert string to symbol for hash key
68
+ acceptable_attribute_map = self.class.acceptable_attribute_map
63
69
  attributes = attributes.each_with_object({}) { |(k, v), h|
64
- if (!self.class.attribute_map.key?(k.to_sym))
65
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailMessageData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
70
+ if (!acceptable_attribute_map.key?(k.to_sym))
71
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailMessageData`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
66
72
  end
67
73
  h[k.to_sym] = v
68
74
  }
@@ -111,6 +117,26 @@ module ElasticEmail
111
117
  true
112
118
  end
113
119
 
120
+ # Custom attribute writer method with validation
121
+ # @param [Object] recipients Value to be assigned
122
+ def recipients=(recipients)
123
+ if recipients.nil?
124
+ fail ArgumentError, 'recipients cannot be nil'
125
+ end
126
+
127
+ @recipients = recipients
128
+ end
129
+
130
+ # Custom attribute writer method with validation
131
+ # @param [Object] content Value to be assigned
132
+ def content=(content)
133
+ if content.nil?
134
+ fail ArgumentError, 'content cannot be nil'
135
+ end
136
+
137
+ @content = content
138
+ end
139
+
114
140
  # Checks equality by comparing each attribute.
115
141
  # @param [Object] Object to be compared
116
142
  def ==(o)
@@ -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.11.0
9
+ Generator version: 7.14.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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -30,9 +30,14 @@ module ElasticEmail
30
30
  }
31
31
  end
32
32
 
33
+ # Returns attribute mapping this model knows about
34
+ def self.acceptable_attribute_map
35
+ attribute_map
36
+ end
37
+
33
38
  # Returns all the JSON keys this model knows about
34
39
  def self.acceptable_attributes
35
- attribute_map.values
40
+ acceptable_attribute_map.values
36
41
  end
37
42
 
38
43
  # Attribute type mapping.
@@ -57,9 +62,10 @@ module ElasticEmail
57
62
  end
58
63
 
59
64
  # check to see if the attribute exists and convert string to symbol for hash key
65
+ acceptable_attribute_map = self.class.acceptable_attribute_map
60
66
  attributes = attributes.each_with_object({}) { |(k, v), h|
61
- if (!self.class.attribute_map.key?(k.to_sym))
62
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailRecipient`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
67
+ if (!acceptable_attribute_map.key?(k.to_sym))
68
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailRecipient`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
63
69
  end
64
70
  h[k.to_sym] = v
65
71
  }
@@ -97,6 +103,16 @@ module ElasticEmail
97
103
  true
98
104
  end
99
105
 
106
+ # Custom attribute writer method with validation
107
+ # @param [Object] email Value to be assigned
108
+ def email=(email)
109
+ if email.nil?
110
+ fail ArgumentError, 'email cannot be nil'
111
+ end
112
+
113
+ @email = email
114
+ end
115
+
100
116
  # Checks equality by comparing each attribute.
101
117
  # @param [Object] Object to be compared
102
118
  def ==(o)
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -29,9 +29,14 @@ module ElasticEmail
29
29
  }
30
30
  end
31
31
 
32
+ # Returns attribute mapping this model knows about
33
+ def self.acceptable_attribute_map
34
+ attribute_map
35
+ end
36
+
32
37
  # Returns all the JSON keys this model knows about
33
38
  def self.acceptable_attributes
34
- attribute_map.values
39
+ acceptable_attribute_map.values
35
40
  end
36
41
 
37
42
  # Attribute type mapping.
@@ -56,9 +61,10 @@ module ElasticEmail
56
61
  end
57
62
 
58
63
  # check to see if the attribute exists and convert string to symbol for hash key
64
+ acceptable_attribute_map = self.class.acceptable_attribute_map
59
65
  attributes = attributes.each_with_object({}) { |(k, v), h|
60
- if (!self.class.attribute_map.key?(k.to_sym))
61
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailSend`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
66
+ if (!acceptable_attribute_map.key?(k.to_sym))
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailSend`. 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
  }
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -94,9 +94,14 @@ module ElasticEmail
94
94
  }
95
95
  end
96
96
 
97
+ # Returns attribute mapping this model knows about
98
+ def self.acceptable_attribute_map
99
+ attribute_map
100
+ end
101
+
97
102
  # Returns all the JSON keys this model knows about
98
103
  def self.acceptable_attributes
99
- attribute_map.values
104
+ acceptable_attribute_map.values
100
105
  end
101
106
 
102
107
  # Attribute type mapping.
@@ -134,9 +139,10 @@ module ElasticEmail
134
139
  end
135
140
 
136
141
  # check to see if the attribute exists and convert string to symbol for hash key
142
+ acceptable_attribute_map = self.class.acceptable_attribute_map
137
143
  attributes = attributes.each_with_object({}) { |(k, v), h|
138
- if (!self.class.attribute_map.key?(k.to_sym))
139
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailStatus`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
144
+ if (!acceptable_attribute_map.key?(k.to_sym))
145
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailStatus`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
140
146
  end
141
147
  h[k.to_sym] = v
142
148
  }
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -31,9 +31,14 @@ module ElasticEmail
31
31
  }
32
32
  end
33
33
 
34
+ # Returns attribute mapping this model knows about
35
+ def self.acceptable_attribute_map
36
+ attribute_map
37
+ end
38
+
34
39
  # Returns all the JSON keys this model knows about
35
40
  def self.acceptable_attributes
36
- attribute_map.values
41
+ acceptable_attribute_map.values
37
42
  end
38
43
 
39
44
  # Attribute type mapping.
@@ -59,9 +64,10 @@ module ElasticEmail
59
64
  end
60
65
 
61
66
  # check to see if the attribute exists and convert string to symbol for hash key
67
+ acceptable_attribute_map = self.class.acceptable_attribute_map
62
68
  attributes = attributes.each_with_object({}) { |(k, v), h|
63
- if (!self.class.attribute_map.key?(k.to_sym))
64
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailTransactionalMessageData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
69
+ if (!acceptable_attribute_map.key?(k.to_sym))
70
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailTransactionalMessageData`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
65
71
  end
66
72
  h[k.to_sym] = v
67
73
  }
@@ -108,6 +114,26 @@ module ElasticEmail
108
114
  true
109
115
  end
110
116
 
117
+ # Custom attribute writer method with validation
118
+ # @param [Object] recipients Value to be assigned
119
+ def recipients=(recipients)
120
+ if recipients.nil?
121
+ fail ArgumentError, 'recipients cannot be nil'
122
+ end
123
+
124
+ @recipients = recipients
125
+ end
126
+
127
+ # Custom attribute writer method with validation
128
+ # @param [Object] content Value to be assigned
129
+ def content=(content)
130
+ if content.nil?
131
+ fail ArgumentError, 'content cannot be nil'
132
+ end
133
+
134
+ @content = content
135
+ end
136
+
111
137
  # Checks equality by comparing each attribute.
112
138
  # @param [Object] Object to be compared
113
139
  def ==(o)
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -85,9 +85,14 @@ module ElasticEmail
85
85
  }
86
86
  end
87
87
 
88
+ # Returns attribute mapping this model knows about
89
+ def self.acceptable_attribute_map
90
+ attribute_map
91
+ end
92
+
88
93
  # Returns all the JSON keys this model knows about
89
94
  def self.acceptable_attributes
90
- attribute_map.values
95
+ acceptable_attribute_map.values
91
96
  end
92
97
 
93
98
  # Attribute type mapping.
@@ -121,9 +126,10 @@ module ElasticEmail
121
126
  end
122
127
 
123
128
  # check to see if the attribute exists and convert string to symbol for hash key
129
+ acceptable_attribute_map = self.class.acceptable_attribute_map
124
130
  attributes = attributes.each_with_object({}) { |(k, v), h|
125
- if (!self.class.attribute_map.key?(k.to_sym))
126
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailValidationResult`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
131
+ if (!acceptable_attribute_map.key?(k.to_sym))
132
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailValidationResult`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
127
133
  end
128
134
  h[k.to_sym] = v
129
135
  }
@@ -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.11.0
9
+ Generator version: 7.14.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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -34,9 +34,14 @@ module ElasticEmail
34
34
  }
35
35
  end
36
36
 
37
+ # Returns attribute mapping this model knows about
38
+ def self.acceptable_attribute_map
39
+ attribute_map
40
+ end
41
+
37
42
  # Returns all the JSON keys this model knows about
38
43
  def self.acceptable_attributes
39
- attribute_map.values
44
+ acceptable_attribute_map.values
40
45
  end
41
46
 
42
47
  # Attribute type mapping.
@@ -62,9 +67,10 @@ module ElasticEmail
62
67
  end
63
68
 
64
69
  # check to see if the attribute exists and convert string to symbol for hash key
70
+ acceptable_attribute_map = self.class.acceptable_attribute_map
65
71
  attributes = attributes.each_with_object({}) { |(k, v), h|
66
- if (!self.class.attribute_map.key?(k.to_sym))
67
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailView`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
72
+ if (!acceptable_attribute_map.key?(k.to_sym))
73
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailView`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
68
74
  end
69
75
  h[k.to_sym] = v
70
76
  }
@@ -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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -30,9 +30,14 @@ module ElasticEmail
30
30
  }
31
31
  end
32
32
 
33
+ # Returns attribute mapping this model knows about
34
+ def self.acceptable_attribute_map
35
+ attribute_map
36
+ end
37
+
33
38
  # Returns all the JSON keys this model knows about
34
39
  def self.acceptable_attributes
35
- attribute_map.values
40
+ acceptable_attribute_map.values
36
41
  end
37
42
 
38
43
  # Attribute type mapping.
@@ -57,9 +62,10 @@ module ElasticEmail
57
62
  end
58
63
 
59
64
  # check to see if the attribute exists and convert string to symbol for hash key
65
+ acceptable_attribute_map = self.class.acceptable_attribute_map
60
66
  attributes = attributes.each_with_object({}) { |(k, v), h|
61
- if (!self.class.attribute_map.key?(k.to_sym))
62
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailsPayload`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
67
+ if (!acceptable_attribute_map.key?(k.to_sym))
68
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::EmailsPayload`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
63
69
  end
64
70
  h[k.to_sym] = v
65
71
  }
@@ -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.11.0
9
+ Generator version: 7.14.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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -17,15 +17,18 @@ module ElasticEmail
17
17
  class EventType
18
18
  SUBMISSION = "Submission".freeze
19
19
  FAILED_ATTEMPT = "FailedAttempt".freeze
20
- BOUNCE = "Bounce".freeze
20
+ ERROR = "Error".freeze
21
21
  SENT = "Sent".freeze
22
22
  OPEN = "Open".freeze
23
23
  CLICK = "Click".freeze
24
24
  UNSUBSCRIBE = "Unsubscribe".freeze
25
25
  COMPLAINT = "Complaint".freeze
26
+ BOUNCE = "Bounce".freeze
27
+ TRANSACTIONAL_UNSUBSCRIBE = "TransactionalUnsubscribe".freeze
28
+ SUPPRESS = "Suppress".freeze
26
29
 
27
30
  def self.all_vars
28
- @all_vars ||= [SUBMISSION, FAILED_ATTEMPT, BOUNCE, SENT, OPEN, CLICK, UNSUBSCRIBE, COMPLAINT].freeze
31
+ @all_vars ||= [SUBMISSION, FAILED_ATTEMPT, ERROR, SENT, OPEN, CLICK, UNSUBSCRIBE, COMPLAINT, BOUNCE, TRANSACTIONAL_UNSUBSCRIBE, SUPPRESS].freeze
29
32
  end
30
33
 
31
34
  # Builds the enum from string
@@ -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.11.0
9
+ Generator version: 7.14.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.11.0
9
+ Generator version: 7.14.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.11.0
9
+ Generator version: 7.14.0
10
10
 
11
11
  =end
12
12
 
@@ -29,9 +29,14 @@ module ElasticEmail
29
29
  }
30
30
  end
31
31
 
32
+ # Returns attribute mapping this model knows about
33
+ def self.acceptable_attribute_map
34
+ attribute_map
35
+ end
36
+
32
37
  # Returns all the JSON keys this model knows about
33
38
  def self.acceptable_attributes
34
- attribute_map.values
39
+ acceptable_attribute_map.values
35
40
  end
36
41
 
37
42
  # Attribute type mapping.
@@ -56,9 +61,10 @@ module ElasticEmail
56
61
  end
57
62
 
58
63
  # check to see if the attribute exists and convert string to symbol for hash key
64
+ acceptable_attribute_map = self.class.acceptable_attribute_map
59
65
  attributes = attributes.each_with_object({}) { |(k, v), h|
60
- if (!self.class.attribute_map.key?(k.to_sym))
61
- fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::ExportLink`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
66
+ if (!acceptable_attribute_map.key?(k.to_sym))
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ElasticEmail::ExportLink`. 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
  }