sendpost_ruby_sdk 1.2.2 → 2.0.2

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 (293) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE +21 -0
  3. data/README.md +583 -145
  4. data/docs/AccountStats.md +20 -0
  5. data/docs/AccountStatsStat.md +38 -0
  6. data/docs/AggregateStat.md +38 -0
  7. data/docs/AggregateStats.md +38 -0
  8. data/docs/AggregatedEmailStats.md +38 -0
  9. data/docs/Attachment.md +4 -4
  10. data/docs/AutoWarmupPlan.md +80 -0
  11. data/docs/CopyTo.md +5 -5
  12. data/docs/CreateDomainRequest.md +18 -0
  13. data/docs/CreateSubAccountRequest.md +18 -0
  14. data/docs/CreateSuppressionRequest.md +24 -0
  15. data/docs/CreateSuppressionRequestHardBounceInner.md +18 -0
  16. data/docs/{SuppressionEmail.md → CreateSuppressionRequestManualInner.md} +3 -3
  17. data/docs/CreateSuppressionRequestSpamComplaintInner.md +18 -0
  18. data/docs/CreateSuppressionRequestUnsubscribeInner.md +18 -0
  19. data/docs/CreateWebhookRequest.md +46 -0
  20. data/docs/DeleteResponse.md +2 -2
  21. data/docs/DeleteSubAccountResponse.md +20 -0
  22. data/docs/DeleteSuppression200ResponseInner.md +20 -0
  23. data/docs/DeleteSuppressionRequest.md +18 -0
  24. data/docs/DeleteWebhookResponse.md +20 -0
  25. data/docs/Device.md +1 -1
  26. data/docs/Domain.md +56 -0
  27. data/docs/DomainApi.md +301 -0
  28. data/docs/DomainDkim.md +22 -0
  29. data/docs/DomainDmarc.md +22 -0
  30. data/docs/DomainGpt.md +22 -0
  31. data/docs/DomainReturnPath.md +22 -0
  32. data/docs/DomainSpf.md +22 -0
  33. data/docs/DomainTrack.md +22 -0
  34. data/docs/EIP.md +18 -0
  35. data/docs/{From.md → EmailAddress.md} +4 -4
  36. data/docs/EmailApi.md +38 -32
  37. data/docs/EmailMessage.md +30 -24
  38. data/docs/EmailMessageFrom.md +20 -0
  39. data/docs/EmailMessageObject.md +46 -0
  40. data/docs/{ReplyTo.md → EmailMessageReplyTo.md} +5 -5
  41. data/docs/EmailMessageToInner.md +26 -0
  42. data/docs/EmailMessageToInnerBccInner.md +22 -0
  43. data/docs/EmailMessageToInnerCcInner.md +22 -0
  44. data/docs/EmailMessageWithTemplate.md +52 -0
  45. data/docs/EmailResponse.md +8 -8
  46. data/docs/EmailStats.md +20 -0
  47. data/docs/EmailStatsStats.md +38 -0
  48. data/docs/Event.md +56 -0
  49. data/docs/EventMetadata.md +13 -13
  50. data/docs/{City.md → GeoLocation.md} +8 -8
  51. data/docs/IP.md +62 -0
  52. data/docs/IPAllocationRequest.md +20 -0
  53. data/docs/IPApi.md +375 -0
  54. data/docs/IPDeletionResponse.md +20 -0
  55. data/docs/IPPool.md +42 -0
  56. data/docs/IPPoolCreateRequest.md +28 -0
  57. data/docs/IPPoolDeleteResponse.md +20 -0
  58. data/docs/IPPoolUpdateRequest.md +24 -0
  59. data/docs/IPPoolsApi.md +361 -0
  60. data/docs/IPUpdateRequest.md +18 -0
  61. data/docs/Label.md +22 -0
  62. data/docs/Member.md +40 -0
  63. data/docs/Message.md +76 -0
  64. data/docs/MessageApi.md +79 -0
  65. data/docs/MessageHeaderTo.md +26 -0
  66. data/docs/MessageTo.md +26 -0
  67. data/docs/{Os.md → OperatingSystem.md} +7 -7
  68. data/docs/Person.md +20 -0
  69. data/docs/{To.md → Recipient.md} +7 -7
  70. data/docs/SMTPAuth.md +26 -0
  71. data/docs/Stat.md +20 -0
  72. data/docs/StatStat.md +38 -0
  73. data/docs/StatStats.md +38 -0
  74. data/docs/StatsAApi.md +307 -0
  75. data/docs/StatsApi.md +237 -0
  76. data/docs/SubAccount.md +48 -0
  77. data/docs/SubAccountApi.md +375 -0
  78. data/docs/Suppression.md +8 -8
  79. data/docs/SuppressionApi.md +76 -134
  80. data/docs/ThirdPartySendingProvider.md +38 -0
  81. data/docs/UpdateSubAccount.md +18 -0
  82. data/docs/UpdateWebhook.md +46 -0
  83. data/docs/UserAgent.md +4 -4
  84. data/docs/Webhook.md +54 -0
  85. data/docs/WebhookApi.md +375 -0
  86. data/git_push.sh +1 -1
  87. data/lib/sendpost_ruby_sdk/api/domain_api.rb +290 -0
  88. data/lib/sendpost_ruby_sdk/api/email_api.rb +33 -35
  89. data/lib/sendpost_ruby_sdk/api/ip_api.rb +356 -0
  90. data/lib/sendpost_ruby_sdk/api/ip_pools_api.rb +356 -0
  91. data/lib/sendpost_ruby_sdk/api/message_api.rb +85 -0
  92. data/lib/sendpost_ruby_sdk/api/stats_a_api.rb +320 -0
  93. data/lib/sendpost_ruby_sdk/api/stats_api.rb +260 -0
  94. data/lib/sendpost_ruby_sdk/api/sub_account_api.rb +356 -0
  95. data/lib/sendpost_ruby_sdk/api/suppression_api.rb +81 -141
  96. data/lib/sendpost_ruby_sdk/api/webhook_api.rb +356 -0
  97. data/lib/sendpost_ruby_sdk/api_client.rb +26 -24
  98. data/lib/sendpost_ruby_sdk/api_error.rb +3 -3
  99. data/lib/sendpost_ruby_sdk/configuration.rb +28 -3
  100. data/lib/sendpost_ruby_sdk/models/account_stats.rb +229 -0
  101. data/lib/sendpost_ruby_sdk/models/account_stats_stat.rb +311 -0
  102. data/lib/sendpost_ruby_sdk/models/aggregate_stat.rb +321 -0
  103. data/lib/sendpost_ruby_sdk/models/aggregate_stats.rb +310 -0
  104. data/lib/sendpost_ruby_sdk/models/aggregated_email_stats.rb +321 -0
  105. data/lib/sendpost_ruby_sdk/models/attachment.rb +15 -7
  106. data/lib/sendpost_ruby_sdk/models/auto_warmup_plan.rb +531 -0
  107. data/lib/sendpost_ruby_sdk/models/copy_to.rb +28 -19
  108. data/lib/sendpost_ruby_sdk/models/create_domain_request.rb +221 -0
  109. data/lib/sendpost_ruby_sdk/models/create_sub_account_request.rb +221 -0
  110. data/lib/sendpost_ruby_sdk/models/create_suppression_request.rb +259 -0
  111. data/lib/sendpost_ruby_sdk/models/create_suppression_request_hard_bounce_inner.rb +220 -0
  112. data/lib/sendpost_ruby_sdk/models/create_suppression_request_manual_inner.rb +220 -0
  113. data/lib/sendpost_ruby_sdk/models/create_suppression_request_spam_complaint_inner.rb +220 -0
  114. data/lib/sendpost_ruby_sdk/models/create_suppression_request_unsubscribe_inner.rb +220 -0
  115. data/lib/sendpost_ruby_sdk/models/create_webhook_request.rb +361 -0
  116. data/lib/sendpost_ruby_sdk/models/delete_response.rb +15 -7
  117. data/lib/sendpost_ruby_sdk/models/delete_sub_account_response.rb +231 -0
  118. data/lib/sendpost_ruby_sdk/models/delete_suppression200_response_inner.rb +231 -0
  119. data/lib/sendpost_ruby_sdk/models/delete_suppression_request.rb +222 -0
  120. data/lib/sendpost_ruby_sdk/models/delete_webhook_response.rb +231 -0
  121. data/lib/sendpost_ruby_sdk/models/device.rb +13 -7
  122. data/lib/sendpost_ruby_sdk/models/domain.rb +435 -0
  123. data/lib/sendpost_ruby_sdk/models/domain_dkim.rb +239 -0
  124. data/lib/sendpost_ruby_sdk/models/domain_dmarc.rb +239 -0
  125. data/lib/sendpost_ruby_sdk/models/domain_gpt.rb +239 -0
  126. data/lib/sendpost_ruby_sdk/models/domain_return_path.rb +239 -0
  127. data/lib/sendpost_ruby_sdk/models/domain_spf.rb +239 -0
  128. data/lib/sendpost_ruby_sdk/models/domain_track.rb +239 -0
  129. data/lib/sendpost_ruby_sdk/models/eip.rb +238 -0
  130. data/lib/sendpost_ruby_sdk/models/email_address.rb +229 -0
  131. data/lib/sendpost_ruby_sdk/models/email_message.rb +121 -86
  132. data/lib/sendpost_ruby_sdk/models/email_message_from.rb +229 -0
  133. data/lib/sendpost_ruby_sdk/models/email_message_object.rb +354 -0
  134. data/lib/sendpost_ruby_sdk/models/email_message_reply_to.rb +229 -0
  135. data/lib/sendpost_ruby_sdk/models/email_message_to_inner.rb +262 -0
  136. data/lib/sendpost_ruby_sdk/models/email_message_to_inner_bcc_inner.rb +240 -0
  137. data/lib/sendpost_ruby_sdk/models/email_message_to_inner_cc_inner.rb +240 -0
  138. data/lib/sendpost_ruby_sdk/models/email_message_with_template.rb +392 -0
  139. data/lib/sendpost_ruby_sdk/models/email_response.rb +40 -32
  140. data/lib/sendpost_ruby_sdk/models/email_stats.rb +230 -0
  141. data/lib/sendpost_ruby_sdk/models/email_stats_stats.rb +321 -0
  142. data/lib/sendpost_ruby_sdk/models/event.rb +393 -0
  143. data/lib/sendpost_ruby_sdk/models/event_metadata.rb +59 -53
  144. data/lib/sendpost_ruby_sdk/models/geo_location.rb +256 -0
  145. data/lib/sendpost_ruby_sdk/models/ip.rb +643 -0
  146. data/lib/sendpost_ruby_sdk/models/ip_allocation_request.rb +266 -0
  147. data/lib/sendpost_ruby_sdk/models/ip_deletion_response.rb +265 -0
  148. data/lib/sendpost_ruby_sdk/models/ip_pool.rb +357 -0
  149. data/lib/sendpost_ruby_sdk/models/ip_pool_create_request.rb +299 -0
  150. data/lib/sendpost_ruby_sdk/models/ip_pool_delete_response.rb +229 -0
  151. data/lib/sendpost_ruby_sdk/models/ip_pool_update_request.rb +249 -0
  152. data/lib/sendpost_ruby_sdk/models/ip_update_request.rb +238 -0
  153. data/lib/sendpost_ruby_sdk/models/label.rb +241 -0
  154. data/lib/sendpost_ruby_sdk/models/member.rb +331 -0
  155. data/lib/sendpost_ruby_sdk/models/message.rb +523 -0
  156. data/lib/sendpost_ruby_sdk/models/message_header_to.rb +268 -0
  157. data/lib/sendpost_ruby_sdk/models/message_to.rb +268 -0
  158. data/lib/sendpost_ruby_sdk/models/operating_system.rb +256 -0
  159. data/lib/sendpost_ruby_sdk/models/person.rb +231 -0
  160. data/lib/sendpost_ruby_sdk/models/recipient.rb +263 -0
  161. data/lib/sendpost_ruby_sdk/models/smtp_auth.rb +261 -0
  162. data/lib/sendpost_ruby_sdk/models/stat.rb +230 -0
  163. data/lib/sendpost_ruby_sdk/models/stat_stat.rb +322 -0
  164. data/lib/sendpost_ruby_sdk/models/stat_stats.rb +321 -0
  165. data/lib/sendpost_ruby_sdk/models/sub_account.rb +415 -0
  166. data/lib/sendpost_ruby_sdk/models/suppression.rb +40 -29
  167. data/lib/sendpost_ruby_sdk/models/third_party_sending_provider.rb +310 -0
  168. data/lib/sendpost_ruby_sdk/models/update_sub_account.rb +221 -0
  169. data/lib/sendpost_ruby_sdk/models/update_webhook.rb +368 -0
  170. data/lib/sendpost_ruby_sdk/models/user_agent.rb +13 -7
  171. data/lib/sendpost_ruby_sdk/models/webhook.rb +405 -0
  172. data/lib/sendpost_ruby_sdk/version.rb +4 -4
  173. data/lib/sendpost_ruby_sdk.rb +73 -15
  174. data/spec/api/domain_api_spec.rb +85 -0
  175. data/spec/api/email_api_spec.rb +9 -9
  176. data/spec/api/ip_api_spec.rb +98 -0
  177. data/spec/api/ip_pools_api_spec.rb +98 -0
  178. data/spec/api/message_api_spec.rb +47 -0
  179. data/spec/api/stats_a_api_spec.rb +89 -0
  180. data/spec/api/stats_api_spec.rb +78 -0
  181. data/spec/api/sub_account_api_spec.rb +98 -0
  182. data/spec/api/suppression_api_spec.rb +22 -34
  183. data/spec/api/webhook_api_spec.rb +98 -0
  184. data/spec/models/account_stats_spec.rb +42 -0
  185. data/spec/models/account_stats_stat_spec.rb +96 -0
  186. data/spec/models/aggregate_stat_spec.rb +96 -0
  187. data/spec/models/aggregate_stats_spec.rb +96 -0
  188. data/spec/models/aggregated_email_stats_spec.rb +96 -0
  189. data/spec/models/attachment_spec.rb +6 -4
  190. data/spec/models/auto_warmup_plan_spec.rb +222 -0
  191. data/spec/models/copy_to_spec.rb +8 -6
  192. data/spec/models/create_domain_request_spec.rb +36 -0
  193. data/spec/models/create_sub_account_request_spec.rb +36 -0
  194. data/spec/models/create_suppression_request_hard_bounce_inner_spec.rb +36 -0
  195. data/spec/models/create_suppression_request_manual_inner_spec.rb +36 -0
  196. data/spec/models/create_suppression_request_spam_complaint_inner_spec.rb +36 -0
  197. data/spec/models/create_suppression_request_spec.rb +54 -0
  198. data/spec/models/create_suppression_request_unsubscribe_inner_spec.rb +36 -0
  199. data/spec/models/create_webhook_request_spec.rb +120 -0
  200. data/spec/models/delete_response_spec.rb +6 -4
  201. data/spec/models/delete_sub_account_response_spec.rb +42 -0
  202. data/spec/models/delete_suppression200_response_inner_spec.rb +42 -0
  203. data/spec/models/delete_suppression_request_spec.rb +36 -0
  204. data/spec/models/delete_webhook_response_spec.rb +42 -0
  205. data/spec/models/device_spec.rb +6 -4
  206. data/spec/models/domain_dkim_spec.rb +48 -0
  207. data/spec/models/domain_dmarc_spec.rb +48 -0
  208. data/spec/models/domain_gpt_spec.rb +48 -0
  209. data/spec/models/domain_return_path_spec.rb +48 -0
  210. data/spec/models/domain_spec.rb +150 -0
  211. data/spec/models/domain_spf_spec.rb +48 -0
  212. data/spec/models/domain_track_spec.rb +48 -0
  213. data/spec/models/eip_spec.rb +36 -0
  214. data/spec/models/email_address_spec.rb +42 -0
  215. data/spec/models/email_message_from_spec.rb +42 -0
  216. data/spec/models/email_message_object_spec.rb +120 -0
  217. data/spec/models/email_message_reply_to_spec.rb +42 -0
  218. data/spec/models/email_message_spec.rb +37 -17
  219. data/spec/models/email_message_to_inner_bcc_inner_spec.rb +48 -0
  220. data/spec/models/email_message_to_inner_cc_inner_spec.rb +48 -0
  221. data/spec/models/email_message_to_inner_spec.rb +60 -0
  222. data/spec/models/email_message_with_template_spec.rb +138 -0
  223. data/spec/models/email_response_spec.rb +10 -8
  224. data/spec/models/email_stats_spec.rb +42 -0
  225. data/spec/models/email_stats_stats_spec.rb +96 -0
  226. data/spec/models/event_metadata_spec.rb +24 -10
  227. data/spec/models/event_spec.rb +150 -0
  228. data/spec/models/geo_location_spec.rb +60 -0
  229. data/spec/models/ip_allocation_request_spec.rb +42 -0
  230. data/spec/models/ip_deletion_response_spec.rb +42 -0
  231. data/spec/models/ip_pool_create_request_spec.rb +66 -0
  232. data/spec/models/ip_pool_delete_response_spec.rb +42 -0
  233. data/spec/models/ip_pool_spec.rb +108 -0
  234. data/spec/models/ip_pool_update_request_spec.rb +54 -0
  235. data/spec/models/ip_spec.rb +168 -0
  236. data/spec/models/ip_update_request_spec.rb +36 -0
  237. data/spec/models/label_spec.rb +48 -0
  238. data/spec/models/member_spec.rb +102 -0
  239. data/spec/models/message_header_to_spec.rb +60 -0
  240. data/spec/models/message_spec.rb +210 -0
  241. data/spec/models/message_to_spec.rb +60 -0
  242. data/spec/models/operating_system_spec.rb +60 -0
  243. data/spec/models/person_spec.rb +42 -0
  244. data/spec/models/recipient_spec.rb +60 -0
  245. data/spec/models/smtp_auth_spec.rb +60 -0
  246. data/spec/models/stat_spec.rb +42 -0
  247. data/spec/models/stat_stat_spec.rb +96 -0
  248. data/spec/models/stat_stats_spec.rb +96 -0
  249. data/spec/models/sub_account_spec.rb +130 -0
  250. data/spec/models/suppression_spec.rb +11 -9
  251. data/spec/models/third_party_sending_provider_spec.rb +96 -0
  252. data/spec/models/update_sub_account_spec.rb +36 -0
  253. data/spec/models/update_webhook_spec.rb +120 -0
  254. data/spec/models/user_agent_spec.rb +6 -4
  255. data/spec/models/webhook_spec.rb +144 -0
  256. data/spec/spec_helper.rb +3 -3
  257. metadata +295 -66
  258. data/config-ruby.json +0 -11
  259. data/docs/CountStat.md +0 -18
  260. data/docs/QEmailMessage.md +0 -70
  261. data/docs/QEvent.md +0 -42
  262. data/docs/RDSuppression.md +0 -18
  263. data/docs/RSuppression.md +0 -24
  264. data/docs/WebhookEvent.md +0 -20
  265. data/generate-libs.bash +0 -1
  266. data/lib/sendpost_ruby_sdk/models/city.rb +0 -250
  267. data/lib/sendpost_ruby_sdk/models/count_stat.rb +0 -214
  268. data/lib/sendpost_ruby_sdk/models/from.rb +0 -223
  269. data/lib/sendpost_ruby_sdk/models/os.rb +0 -250
  270. data/lib/sendpost_ruby_sdk/models/q_email_message.rb +0 -456
  271. data/lib/sendpost_ruby_sdk/models/q_event.rb +0 -324
  272. data/lib/sendpost_ruby_sdk/models/r_suppression.rb +0 -249
  273. data/lib/sendpost_ruby_sdk/models/rd_suppression.rb +0 -216
  274. data/lib/sendpost_ruby_sdk/models/reply_to.rb +0 -223
  275. data/lib/sendpost_ruby_sdk/models/suppression_email.rb +0 -214
  276. data/lib/sendpost_ruby_sdk/models/to.rb +0 -254
  277. data/lib/sendpost_ruby_sdk/models/webhook_event.rb +0 -223
  278. data/sendpost.yaml +0 -666
  279. data/sendpost_ruby_sdk.gemspec +0 -38
  280. data/spec/api_client_spec.rb +0 -228
  281. data/spec/configuration_spec.rb +0 -42
  282. data/spec/models/city_spec.rb +0 -58
  283. data/spec/models/count_stat_spec.rb +0 -34
  284. data/spec/models/from_spec.rb +0 -40
  285. data/spec/models/os_spec.rb +0 -58
  286. data/spec/models/q_email_message_spec.rb +0 -190
  287. data/spec/models/q_event_spec.rb +0 -106
  288. data/spec/models/r_suppression_spec.rb +0 -52
  289. data/spec/models/rd_suppression_spec.rb +0 -34
  290. data/spec/models/reply_to_spec.rb +0 -40
  291. data/spec/models/suppression_email_spec.rb +0 -34
  292. data/spec/models/to_spec.rb +0 -58
  293. data/spec/models/webhook_event_spec.rb +0 -40
data/docs/DomainApi.md ADDED
@@ -0,0 +1,301 @@
1
+ # Sendpost::DomainApi
2
+
3
+ All URIs are relative to *https://api.sendpost.io/api/v1*
4
+
5
+ | Method | HTTP request | Description |
6
+ | ------ | ------------ | ----------- |
7
+ | [**get_all_domains**](DomainApi.md#get_all_domains) | **GET** /subaccount/domain | List Domains |
8
+ | [**subaccount_domain_domain_id_delete**](DomainApi.md#subaccount_domain_domain_id_delete) | **DELETE** /subaccount/domain/{domain_id} | Delete Domain |
9
+ | [**subaccount_domain_domain_id_get**](DomainApi.md#subaccount_domain_domain_id_get) | **GET** /subaccount/domain/{domain_id} | Get Domain |
10
+ | [**subaccount_domain_post**](DomainApi.md#subaccount_domain_post) | **POST** /subaccount/domain | Create Domain |
11
+
12
+
13
+ ## get_all_domains
14
+
15
+ > <Array<Domain>> get_all_domains(opts)
16
+
17
+ List Domains
18
+
19
+ Retrieve a list of all domains associated with the sub-account, including their DNS records and authentication status.
20
+
21
+ ### Examples
22
+
23
+ ```ruby
24
+ require 'time'
25
+ require 'sendpost_ruby_sdk'
26
+ # setup authorization
27
+ Sendpost.configure do |config|
28
+ # Configure API key authorization: subAccountAuth
29
+ config.api_key['X-SubAccount-ApiKey'] = 'YOUR API KEY'
30
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
31
+ # config.api_key_prefix['X-SubAccount-ApiKey'] = 'Bearer'
32
+ end
33
+
34
+ api_instance = Sendpost::DomainApi.new
35
+ opts = {
36
+ limit: 56, # Integer | Number of records to return per request
37
+ offset: 56, # Integer | Number of initial records to skip
38
+ search: 'search_example' # String | Case insensitive search against domain names
39
+ }
40
+
41
+ begin
42
+ # List Domains
43
+ result = api_instance.get_all_domains(opts)
44
+ p result
45
+ rescue Sendpost::ApiError => e
46
+ puts "Error when calling DomainApi->get_all_domains: #{e}"
47
+ end
48
+ ```
49
+
50
+ #### Using the get_all_domains_with_http_info variant
51
+
52
+ This returns an Array which contains the response data, status code and headers.
53
+
54
+ > <Array(<Array<Domain>>, Integer, Hash)> get_all_domains_with_http_info(opts)
55
+
56
+ ```ruby
57
+ begin
58
+ # List Domains
59
+ data, status_code, headers = api_instance.get_all_domains_with_http_info(opts)
60
+ p status_code # => 2xx
61
+ p headers # => { ... }
62
+ p data # => <Array<Domain>>
63
+ rescue Sendpost::ApiError => e
64
+ puts "Error when calling DomainApi->get_all_domains_with_http_info: #{e}"
65
+ end
66
+ ```
67
+
68
+ ### Parameters
69
+
70
+ | Name | Type | Description | Notes |
71
+ | ---- | ---- | ----------- | ----- |
72
+ | **limit** | **Integer** | Number of records to return per request | [optional] |
73
+ | **offset** | **Integer** | Number of initial records to skip | [optional] |
74
+ | **search** | **String** | Case insensitive search against domain names | [optional] |
75
+
76
+ ### Return type
77
+
78
+ [**Array&lt;Domain&gt;**](Domain.md)
79
+
80
+ ### Authorization
81
+
82
+ [subAccountAuth](../README.md#subAccountAuth)
83
+
84
+ ### HTTP request headers
85
+
86
+ - **Content-Type**: Not defined
87
+ - **Accept**: application/json
88
+
89
+
90
+ ## subaccount_domain_domain_id_delete
91
+
92
+ > <DeleteResponse> subaccount_domain_domain_id_delete(domain_id)
93
+
94
+ Delete Domain
95
+
96
+ Delete a specific domain using its `id`.
97
+
98
+ ### Examples
99
+
100
+ ```ruby
101
+ require 'time'
102
+ require 'sendpost_ruby_sdk'
103
+ # setup authorization
104
+ Sendpost.configure do |config|
105
+ # Configure API key authorization: subAccountAuth
106
+ config.api_key['X-SubAccount-ApiKey'] = 'YOUR API KEY'
107
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
108
+ # config.api_key_prefix['X-SubAccount-ApiKey'] = 'Bearer'
109
+ end
110
+
111
+ api_instance = Sendpost::DomainApi.new
112
+ domain_id = 'domain_id_example' # String | The unique ID of the domain to delete.
113
+
114
+ begin
115
+ # Delete Domain
116
+ result = api_instance.subaccount_domain_domain_id_delete(domain_id)
117
+ p result
118
+ rescue Sendpost::ApiError => e
119
+ puts "Error when calling DomainApi->subaccount_domain_domain_id_delete: #{e}"
120
+ end
121
+ ```
122
+
123
+ #### Using the subaccount_domain_domain_id_delete_with_http_info variant
124
+
125
+ This returns an Array which contains the response data, status code and headers.
126
+
127
+ > <Array(<DeleteResponse>, Integer, Hash)> subaccount_domain_domain_id_delete_with_http_info(domain_id)
128
+
129
+ ```ruby
130
+ begin
131
+ # Delete Domain
132
+ data, status_code, headers = api_instance.subaccount_domain_domain_id_delete_with_http_info(domain_id)
133
+ p status_code # => 2xx
134
+ p headers # => { ... }
135
+ p data # => <DeleteResponse>
136
+ rescue Sendpost::ApiError => e
137
+ puts "Error when calling DomainApi->subaccount_domain_domain_id_delete_with_http_info: #{e}"
138
+ end
139
+ ```
140
+
141
+ ### Parameters
142
+
143
+ | Name | Type | Description | Notes |
144
+ | ---- | ---- | ----------- | ----- |
145
+ | **domain_id** | **String** | The unique ID of the domain to delete. | |
146
+
147
+ ### Return type
148
+
149
+ [**DeleteResponse**](DeleteResponse.md)
150
+
151
+ ### Authorization
152
+
153
+ [subAccountAuth](../README.md#subAccountAuth)
154
+
155
+ ### HTTP request headers
156
+
157
+ - **Content-Type**: Not defined
158
+ - **Accept**: application/json
159
+
160
+
161
+ ## subaccount_domain_domain_id_get
162
+
163
+ > <Domain> subaccount_domain_domain_id_get(domain_id)
164
+
165
+ Get Domain
166
+
167
+ Retrieve details of a specific domain using its `id`.
168
+
169
+ ### Examples
170
+
171
+ ```ruby
172
+ require 'time'
173
+ require 'sendpost_ruby_sdk'
174
+ # setup authorization
175
+ Sendpost.configure do |config|
176
+ # Configure API key authorization: subAccountAuth
177
+ config.api_key['X-SubAccount-ApiKey'] = 'YOUR API KEY'
178
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
179
+ # config.api_key_prefix['X-SubAccount-ApiKey'] = 'Bearer'
180
+ end
181
+
182
+ api_instance = Sendpost::DomainApi.new
183
+ domain_id = 'domain_id_example' # String | The unique ID of the domain to retrieve.
184
+
185
+ begin
186
+ # Get Domain
187
+ result = api_instance.subaccount_domain_domain_id_get(domain_id)
188
+ p result
189
+ rescue Sendpost::ApiError => e
190
+ puts "Error when calling DomainApi->subaccount_domain_domain_id_get: #{e}"
191
+ end
192
+ ```
193
+
194
+ #### Using the subaccount_domain_domain_id_get_with_http_info variant
195
+
196
+ This returns an Array which contains the response data, status code and headers.
197
+
198
+ > <Array(<Domain>, Integer, Hash)> subaccount_domain_domain_id_get_with_http_info(domain_id)
199
+
200
+ ```ruby
201
+ begin
202
+ # Get Domain
203
+ data, status_code, headers = api_instance.subaccount_domain_domain_id_get_with_http_info(domain_id)
204
+ p status_code # => 2xx
205
+ p headers # => { ... }
206
+ p data # => <Domain>
207
+ rescue Sendpost::ApiError => e
208
+ puts "Error when calling DomainApi->subaccount_domain_domain_id_get_with_http_info: #{e}"
209
+ end
210
+ ```
211
+
212
+ ### Parameters
213
+
214
+ | Name | Type | Description | Notes |
215
+ | ---- | ---- | ----------- | ----- |
216
+ | **domain_id** | **String** | The unique ID of the domain to retrieve. | |
217
+
218
+ ### Return type
219
+
220
+ [**Domain**](Domain.md)
221
+
222
+ ### Authorization
223
+
224
+ [subAccountAuth](../README.md#subAccountAuth)
225
+
226
+ ### HTTP request headers
227
+
228
+ - **Content-Type**: Not defined
229
+ - **Accept**: application/json
230
+
231
+
232
+ ## subaccount_domain_post
233
+
234
+ > <Domain> subaccount_domain_post(create_domain_request)
235
+
236
+ Create Domain
237
+
238
+ Add a new domain using its `name`.
239
+
240
+ ### Examples
241
+
242
+ ```ruby
243
+ require 'time'
244
+ require 'sendpost_ruby_sdk'
245
+ # setup authorization
246
+ Sendpost.configure do |config|
247
+ # Configure API key authorization: subAccountAuth
248
+ config.api_key['X-SubAccount-ApiKey'] = 'YOUR API KEY'
249
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
250
+ # config.api_key_prefix['X-SubAccount-ApiKey'] = 'Bearer'
251
+ end
252
+
253
+ api_instance = Sendpost::DomainApi.new
254
+ create_domain_request = Sendpost::CreateDomainRequest.new # CreateDomainRequest |
255
+
256
+ begin
257
+ # Create Domain
258
+ result = api_instance.subaccount_domain_post(create_domain_request)
259
+ p result
260
+ rescue Sendpost::ApiError => e
261
+ puts "Error when calling DomainApi->subaccount_domain_post: #{e}"
262
+ end
263
+ ```
264
+
265
+ #### Using the subaccount_domain_post_with_http_info variant
266
+
267
+ This returns an Array which contains the response data, status code and headers.
268
+
269
+ > <Array(<Domain>, Integer, Hash)> subaccount_domain_post_with_http_info(create_domain_request)
270
+
271
+ ```ruby
272
+ begin
273
+ # Create Domain
274
+ data, status_code, headers = api_instance.subaccount_domain_post_with_http_info(create_domain_request)
275
+ p status_code # => 2xx
276
+ p headers # => { ... }
277
+ p data # => <Domain>
278
+ rescue Sendpost::ApiError => e
279
+ puts "Error when calling DomainApi->subaccount_domain_post_with_http_info: #{e}"
280
+ end
281
+ ```
282
+
283
+ ### Parameters
284
+
285
+ | Name | Type | Description | Notes |
286
+ | ---- | ---- | ----------- | ----- |
287
+ | **create_domain_request** | [**CreateDomainRequest**](CreateDomainRequest.md) | | |
288
+
289
+ ### Return type
290
+
291
+ [**Domain**](Domain.md)
292
+
293
+ ### Authorization
294
+
295
+ [subAccountAuth](../README.md#subAccountAuth)
296
+
297
+ ### HTTP request headers
298
+
299
+ - **Content-Type**: application/json
300
+ - **Accept**: application/json
301
+
@@ -0,0 +1,22 @@
1
+ # Sendpost::DomainDkim
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **host** | **String** | | [optional] |
8
+ | **type** | **String** | | [optional] |
9
+ | **text_value** | **String** | | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'sendpost_ruby_sdk'
15
+
16
+ instance = Sendpost::DomainDkim.new(
17
+ host: sp-dkim._domainkey.example.com,
18
+ type: TXT,
19
+ text_value: v&#x3D;DKIM1;k&#x3D;rsa;s&#x3D;email;h&#x3D;sha256;p&#x3D;MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDU9T3mqruDth2rHXCqNiPzr4oRbHqcUMkqCA4sTZgK7WrhjzerHVyqNAfq4Tyx9s4Tqj0CVfAuENp9mHFKt9Kow5csxqTeVkBoi5UaonafsDstm39ggxFQhKTlRpRoV+VNE5jU9WYlv3wywv28DY2woKYG6QBM6JPSKN1dYQpR4QIDAQAB
20
+ )
21
+ ```
22
+
@@ -0,0 +1,22 @@
1
+ # Sendpost::DomainDmarc
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **host** | **String** | | [optional] |
8
+ | **type** | **String** | | [optional] |
9
+ | **text_value** | **String** | | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'sendpost_ruby_sdk'
15
+
16
+ instance = Sendpost::DomainDmarc.new(
17
+ host: _dmarc.hooli.com,
18
+ type: TXT,
19
+ text_value: v&#x3D;DMARC1; p&#x3D;none;
20
+ )
21
+ ```
22
+
data/docs/DomainGpt.md ADDED
@@ -0,0 +1,22 @@
1
+ # Sendpost::DomainGpt
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **host** | **String** | | [optional] |
8
+ | **type** | **String** | | [optional] |
9
+ | **text_value** | **String** | | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'sendpost_ruby_sdk'
15
+
16
+ instance = Sendpost::DomainGpt.new(
17
+ host: example.com,
18
+ type: TXT,
19
+ text_value:
20
+ )
21
+ ```
22
+
@@ -0,0 +1,22 @@
1
+ # Sendpost::DomainReturnPath
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **host** | **String** | | [optional] |
8
+ | **type** | **String** | | [optional] |
9
+ | **text_value** | **String** | | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'sendpost_ruby_sdk'
15
+
16
+ instance = Sendpost::DomainReturnPath.new(
17
+ host: sp-bounces.hooli.com,
18
+ type: CNAME,
19
+ text_value: sp.sendpost.email
20
+ )
21
+ ```
22
+
data/docs/DomainSpf.md ADDED
@@ -0,0 +1,22 @@
1
+ # Sendpost::DomainSpf
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **host** | **String** | | [optional] |
8
+ | **type** | **String** | | [optional] |
9
+ | **text_value** | **String** | | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'sendpost_ruby_sdk'
15
+
16
+ instance = Sendpost::DomainSpf.new(
17
+ host: sp-bounce.example.com,
18
+ type: CNAME,
19
+ text_value: sp.sendpost.info
20
+ )
21
+ ```
22
+
@@ -0,0 +1,22 @@
1
+ # Sendpost::DomainTrack
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **host** | **String** | | [optional] |
8
+ | **type** | **String** | | [optional] |
9
+ | **text_value** | **String** | | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'sendpost_ruby_sdk'
15
+
16
+ instance = Sendpost::DomainTrack.new(
17
+ host: track.hooli.com,
18
+ type: CNAME,
19
+ text_value: api.sendpost.io
20
+ )
21
+ ```
22
+
data/docs/EIP.md ADDED
@@ -0,0 +1,18 @@
1
+ # Sendpost::EIP
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **public_ip** | **String** | list of IP resources which are a part of the IP Pool containing public IP information. Note that the IPs specified in the IPPool should have been allocated in advance for your account | |
8
+
9
+ ## Example
10
+
11
+ ```ruby
12
+ require 'sendpost_ruby_sdk'
13
+
14
+ instance = Sendpost::EIP.new(
15
+ public_ip: 52.13.11.14
16
+ )
17
+ ```
18
+
@@ -1,4 +1,4 @@
1
- # Sendpost::From
1
+ # Sendpost::EmailAddress
2
2
 
3
3
  ## Properties
4
4
 
@@ -12,9 +12,9 @@
12
12
  ```ruby
13
13
  require 'sendpost_ruby_sdk'
14
14
 
15
- instance = Sendpost::From.new(
16
- email: gavin@hooli.com,
17
- name: Gavin Belson
15
+ instance = Sendpost::EmailAddress.new(
16
+ email: null,
17
+ name: null
18
18
  )
19
19
  ```
20
20
 
data/docs/EmailApi.md CHANGED
@@ -4,33 +4,37 @@ All URIs are relative to *https://api.sendpost.io/api/v1*
4
4
 
5
5
  | Method | HTTP request | Description |
6
6
  | ------ | ------------ | ----------- |
7
- | [**send_email**](EmailApi.md#send_email) | **POST** /subaccount/email/ | |
8
- | [**send_email_with_template**](EmailApi.md#send_email_with_template) | **POST** /subaccount/email/template | |
7
+ | [**send_email**](EmailApi.md#send_email) | **POST** /subaccount/email/ | Send Email |
8
+ | [**send_email_with_template**](EmailApi.md#send_email_with_template) | **POST** /subaccount/email/template | Send Email With Template |
9
9
 
10
10
 
11
11
  ## send_email
12
12
 
13
- > <Array<EmailResponse>> send_email(x_sub_account_api_key, opts)
13
+ > <Array<EmailResponse>> send_email(email_message_object)
14
14
 
15
+ Send Email
15
16
 
16
-
17
- Send Email To Contacts
17
+ Use this API to send either a single or batch email.
18
18
 
19
19
  ### Examples
20
20
 
21
21
  ```ruby
22
22
  require 'time'
23
23
  require 'sendpost_ruby_sdk'
24
+ # setup authorization
25
+ Sendpost.configure do |config|
26
+ # Configure API key authorization: subAccountAuth
27
+ config.api_key['X-SubAccount-ApiKey'] = 'YOUR API KEY'
28
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
29
+ # config.api_key_prefix['X-SubAccount-ApiKey'] = 'Bearer'
30
+ end
24
31
 
25
32
  api_instance = Sendpost::EmailApi.new
26
- x_sub_account_api_key = 'x_sub_account_api_key_example' # String | Sub-Account API Key
27
- opts = {
28
- email_message: Sendpost::EmailMessage.new # EmailMessage | Email message
29
- }
33
+ email_message_object = Sendpost::EmailMessageObject.new # EmailMessageObject | Email message details
30
34
 
31
35
  begin
32
-
33
- result = api_instance.send_email(x_sub_account_api_key, opts)
36
+ # Send Email
37
+ result = api_instance.send_email(email_message_object)
34
38
  p result
35
39
  rescue Sendpost::ApiError => e
36
40
  puts "Error when calling EmailApi->send_email: #{e}"
@@ -41,12 +45,12 @@ end
41
45
 
42
46
  This returns an Array which contains the response data, status code and headers.
43
47
 
44
- > <Array(<Array<EmailResponse>>, Integer, Hash)> send_email_with_http_info(x_sub_account_api_key, opts)
48
+ > <Array(<Array<EmailResponse>>, Integer, Hash)> send_email_with_http_info(email_message_object)
45
49
 
46
50
  ```ruby
47
51
  begin
48
-
49
- data, status_code, headers = api_instance.send_email_with_http_info(x_sub_account_api_key, opts)
52
+ # Send Email
53
+ data, status_code, headers = api_instance.send_email_with_http_info(email_message_object)
50
54
  p status_code # => 2xx
51
55
  p headers # => { ... }
52
56
  p data # => <Array<EmailResponse>>
@@ -59,8 +63,7 @@ end
59
63
 
60
64
  | Name | Type | Description | Notes |
61
65
  | ---- | ---- | ----------- | ----- |
62
- | **x_sub_account_api_key** | **String** | Sub-Account API Key | |
63
- | **email_message** | [**EmailMessage**](EmailMessage.md) | Email message | [optional] |
66
+ | **email_message_object** | [**EmailMessageObject**](EmailMessageObject.md) | Email message details | |
64
67
 
65
68
  ### Return type
66
69
 
@@ -68,7 +71,7 @@ end
68
71
 
69
72
  ### Authorization
70
73
 
71
- No authorization required
74
+ [subAccountAuth](../README.md#subAccountAuth)
72
75
 
73
76
  ### HTTP request headers
74
77
 
@@ -78,27 +81,31 @@ No authorization required
78
81
 
79
82
  ## send_email_with_template
80
83
 
81
- > <Array<EmailResponse>> send_email_with_template(x_sub_account_api_key, opts)
84
+ > <Array<EmailResponse>> send_email_with_template(email_message_with_template)
82
85
 
86
+ Send Email With Template
83
87
 
84
-
85
- Send Email To Contacts With Template
88
+ Use this API to send an email with a predefined template. This makes it easy to integrate transactional emails with minimal code.
86
89
 
87
90
  ### Examples
88
91
 
89
92
  ```ruby
90
93
  require 'time'
91
94
  require 'sendpost_ruby_sdk'
95
+ # setup authorization
96
+ Sendpost.configure do |config|
97
+ # Configure API key authorization: subAccountAuth
98
+ config.api_key['X-SubAccount-ApiKey'] = 'YOUR API KEY'
99
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
100
+ # config.api_key_prefix['X-SubAccount-ApiKey'] = 'Bearer'
101
+ end
92
102
 
93
103
  api_instance = Sendpost::EmailApi.new
94
- x_sub_account_api_key = 'x_sub_account_api_key_example' # String | Sub-Account API Key
95
- opts = {
96
- email_message: Sendpost::EmailMessage.new # EmailMessage | Email message
97
- }
104
+ email_message_with_template = Sendpost::EmailMessageWithTemplate.new # EmailMessageWithTemplate | Email message details with template information
98
105
 
99
106
  begin
100
-
101
- result = api_instance.send_email_with_template(x_sub_account_api_key, opts)
107
+ # Send Email With Template
108
+ result = api_instance.send_email_with_template(email_message_with_template)
102
109
  p result
103
110
  rescue Sendpost::ApiError => e
104
111
  puts "Error when calling EmailApi->send_email_with_template: #{e}"
@@ -109,12 +116,12 @@ end
109
116
 
110
117
  This returns an Array which contains the response data, status code and headers.
111
118
 
112
- > <Array(<Array<EmailResponse>>, Integer, Hash)> send_email_with_template_with_http_info(x_sub_account_api_key, opts)
119
+ > <Array(<Array<EmailResponse>>, Integer, Hash)> send_email_with_template_with_http_info(email_message_with_template)
113
120
 
114
121
  ```ruby
115
122
  begin
116
-
117
- data, status_code, headers = api_instance.send_email_with_template_with_http_info(x_sub_account_api_key, opts)
123
+ # Send Email With Template
124
+ data, status_code, headers = api_instance.send_email_with_template_with_http_info(email_message_with_template)
118
125
  p status_code # => 2xx
119
126
  p headers # => { ... }
120
127
  p data # => <Array<EmailResponse>>
@@ -127,8 +134,7 @@ end
127
134
 
128
135
  | Name | Type | Description | Notes |
129
136
  | ---- | ---- | ----------- | ----- |
130
- | **x_sub_account_api_key** | **String** | Sub-Account API Key | |
131
- | **email_message** | [**EmailMessage**](EmailMessage.md) | Email message | [optional] |
137
+ | **email_message_with_template** | [**EmailMessageWithTemplate**](EmailMessageWithTemplate.md) | Email message details with template information | |
132
138
 
133
139
  ### Return type
134
140
 
@@ -136,7 +142,7 @@ end
136
142
 
137
143
  ### Authorization
138
144
 
139
- No authorization required
145
+ [subAccountAuth](../README.md#subAccountAuth)
140
146
 
141
147
  ### HTTP request headers
142
148