sendpost_ruby_sdk 2.0.0 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +613 -529
- data/docs/AccountCycleUsage.md +18 -0
- data/docs/AccountStats.md +3 -3
- data/docs/AccountWebhookWithStats.md +58 -0
- data/docs/AggregateStat.md +14 -14
- data/docs/AggregateStats.md +22 -22
- data/docs/Attachment.md +4 -4
- data/docs/BlacklistLinks.md +20 -0
- data/docs/BlacklistResource.md +38 -0
- data/docs/BlacklistedOn.md +20 -0
- data/docs/CopyTo.md +6 -6
- data/docs/CreateDomainRequest.md +2 -2
- data/docs/CreateSuppressionRequest.md +4 -4
- data/docs/CreateSuppressionRequestHardBounceInner.md +1 -1
- data/docs/CreateSuppressionRequestManualInner.md +1 -1
- data/docs/CreateSuppressionRequestSpamComplaintInner.md +1 -1
- data/docs/CreateSuppressionRequestUnsubscribeInner.md +1 -1
- data/docs/DailyStatistics.md +38 -0
- data/docs/DateStat.md +40 -0
- data/docs/DeleteResponse.md +4 -4
- data/docs/DeleteSubAccountResponse.md +4 -4
- data/docs/{DeleteSuppression200ResponseInner.md → DeleteSuppression200Response.md} +2 -4
- data/docs/DeleteSuppressionRequest.md +1 -1
- data/docs/{EmailMessageReplyTo.md → DeleteSuppressionRequestSuppressionsInner.md} +3 -5
- data/docs/DeleteWebhookResponse.md +3 -3
- data/docs/Device.md +2 -2
- data/docs/DnsRecord.md +22 -0
- data/docs/Domain.md +24 -28
- data/docs/DomainApi.md +66 -66
- data/docs/DomainStat.md +46 -0
- data/docs/EIP.md +1 -1
- data/docs/EmailAddress.md +4 -4
- data/docs/EmailApi.md +4 -4
- data/docs/EmailMessage.md +30 -30
- data/docs/EmailMessageObject.md +33 -26
- data/docs/EmailMessageWithTemplate.md +32 -27
- data/docs/EmailResponse.md +10 -10
- data/docs/EmailTypeStat.md +40 -0
- data/docs/ErrorResponse.md +18 -0
- data/docs/ErrorResponseError.md +26 -0
- data/docs/ErrorResponseErrorDetailsInner.md +20 -0
- data/docs/Event.md +18 -36
- data/docs/EventMetadata.md +14 -14
- data/docs/GeoLocation.md +8 -8
- data/docs/GroupStat.md +40 -0
- data/docs/IP.md +13 -43
- data/docs/IPAllocationRequest.md +4 -4
- data/docs/IPApi.md +19 -19
- data/docs/IPDeletionResponse.md +2 -2
- data/docs/IPPool.md +13 -21
- data/docs/IPPoolCreateRequest.md +10 -8
- data/docs/IPPoolDeleteResponse.md +2 -2
- data/docs/IPPoolStat.md +44 -0
- data/docs/IPPoolUpdateRequest.md +13 -7
- data/docs/IPPoolsApi.md +26 -19
- data/docs/IPStat.md +46 -0
- data/docs/IPUpdateRequest.md +2 -2
- data/docs/Label.md +10 -6
- data/docs/Member.md +15 -21
- data/docs/Message.md +37 -53
- data/docs/MessageApi.md +83 -3
- data/docs/NewSubAccount.md +18 -0
- data/docs/NewWebhook.md +46 -0
- data/docs/Os.md +26 -0
- data/docs/PostmasterDomainStat.md +30 -0
- data/docs/ProviderStat.md +40 -0
- data/docs/RAIPPoolStat.md +20 -0
- data/docs/RDStat.md +20 -0
- data/docs/RIPStat.md +20 -0
- data/docs/RStat.md +20 -0
- data/docs/Recipient.md +8 -8
- data/docs/SDStat.md +42 -0
- data/docs/SMTPAuth.md +5 -9
- data/docs/SeedContactStats.md +28 -0
- data/docs/Stat.md +22 -4
- data/docs/StatsAApi.md +24 -24
- data/docs/StatsApi.md +19 -19
- data/docs/SubAccount.md +13 -27
- data/docs/SubAccountApi.md +23 -23
- data/docs/SubAccountStat.md +44 -0
- data/docs/SubAccountStatForPool.md +42 -0
- data/docs/Suppression.md +14 -10
- data/docs/SuppressionApi.md +19 -19
- data/docs/TPSPStat.md +42 -0
- data/docs/UpdateSubAccount.md +2 -2
- data/docs/UpdateWebhook.md +23 -23
- data/docs/UserAgent.md +7 -7
- data/docs/ValidationStat.md +32 -0
- data/docs/Webhook.md +31 -29
- data/docs/WebhookApi.md +28 -28
- data/docs/WebhookObject.md +20 -0
- data/docs/WebhookReferenceApi.md +71 -0
- data/lib/sendpost_ruby_sdk/api/domain_api.rb +84 -84
- data/lib/sendpost_ruby_sdk/api/email_api.rb +6 -6
- data/lib/sendpost_ruby_sdk/api/ip_api.rb +24 -24
- data/lib/sendpost_ruby_sdk/api/ip_pools_api.rb +25 -25
- data/lib/sendpost_ruby_sdk/api/message_api.rb +83 -6
- data/lib/sendpost_ruby_sdk/api/stats_a_api.rb +30 -30
- data/lib/sendpost_ruby_sdk/api/stats_api.rb +24 -24
- data/lib/sendpost_ruby_sdk/api/sub_account_api.rb +33 -33
- data/lib/sendpost_ruby_sdk/api/suppression_api.rb +23 -23
- data/lib/sendpost_ruby_sdk/api/webhook_api.rb +36 -36
- data/lib/sendpost_ruby_sdk/api/webhook_reference_api.rb +82 -0
- data/lib/sendpost_ruby_sdk/api_client.rb +2 -2
- data/lib/sendpost_ruby_sdk/api_error.rb +2 -2
- data/lib/sendpost_ruby_sdk/configuration.rb +2 -2
- data/lib/sendpost_ruby_sdk/models/account_cycle_usage.rb +222 -0
- data/lib/sendpost_ruby_sdk/models/account_stats.rb +5 -3
- data/lib/sendpost_ruby_sdk/models/account_webhook_with_stats.rb +463 -0
- data/lib/sendpost_ruby_sdk/models/aggregate_stat.rb +37 -29
- data/lib/sendpost_ruby_sdk/models/aggregate_stats.rb +43 -24
- data/lib/sendpost_ruby_sdk/models/attachment.rb +48 -4
- data/lib/sendpost_ruby_sdk/models/blacklist_links.rb +232 -0
- data/lib/sendpost_ruby_sdk/models/blacklist_resource.rb +323 -0
- data/lib/sendpost_ruby_sdk/models/blacklisted_on.rb +232 -0
- data/lib/sendpost_ruby_sdk/models/copy_to.rb +42 -3
- data/lib/sendpost_ruby_sdk/models/create_domain_request.rb +32 -3
- data/lib/sendpost_ruby_sdk/models/create_suppression_request.rb +6 -6
- data/lib/sendpost_ruby_sdk/models/create_suppression_request_hard_bounce_inner.rb +2 -2
- data/lib/sendpost_ruby_sdk/models/create_suppression_request_manual_inner.rb +2 -2
- data/lib/sendpost_ruby_sdk/models/create_suppression_request_spam_complaint_inner.rb +2 -2
- data/lib/sendpost_ruby_sdk/models/create_suppression_request_unsubscribe_inner.rb +2 -2
- data/lib/sendpost_ruby_sdk/models/daily_statistics.rb +322 -0
- data/lib/sendpost_ruby_sdk/models/date_stat.rb +339 -0
- data/lib/sendpost_ruby_sdk/models/delete_response.rb +5 -4
- data/lib/sendpost_ruby_sdk/models/delete_sub_account_response.rb +5 -4
- data/lib/sendpost_ruby_sdk/models/delete_suppression200_response.rb +221 -0
- data/lib/sendpost_ruby_sdk/models/delete_suppression_request.rb +4 -3
- data/lib/sendpost_ruby_sdk/models/delete_suppression_request_suppressions_inner.rb +220 -0
- data/lib/sendpost_ruby_sdk/models/delete_webhook_response.rb +5 -4
- data/lib/sendpost_ruby_sdk/models/device.rb +5 -3
- data/lib/sendpost_ruby_sdk/models/dns_record.rb +276 -0
- data/lib/sendpost_ruby_sdk/models/domain.rb +42 -56
- data/lib/sendpost_ruby_sdk/models/domain_stat.rb +369 -0
- data/lib/sendpost_ruby_sdk/models/eip.rb +4 -3
- data/lib/sendpost_ruby_sdk/models/email_address.rb +41 -2
- data/lib/sendpost_ruby_sdk/models/email_message.rb +26 -9
- data/lib/sendpost_ruby_sdk/models/email_message_object.rb +123 -3
- data/lib/sendpost_ruby_sdk/models/email_message_with_template.rb +121 -12
- data/lib/sendpost_ruby_sdk/models/email_response.rb +8 -4
- data/lib/sendpost_ruby_sdk/models/email_type_stat.rb +339 -0
- data/lib/sendpost_ruby_sdk/models/error_response.rb +221 -0
- data/lib/sendpost_ruby_sdk/models/error_response_error.rb +297 -0
- data/lib/sendpost_ruby_sdk/models/error_response_error_details_inner.rb +231 -0
- data/lib/sendpost_ruby_sdk/models/event.rb +94 -118
- data/lib/sendpost_ruby_sdk/models/event_metadata.rb +15 -5
- data/lib/sendpost_ruby_sdk/models/geo_location.rb +20 -14
- data/lib/sendpost_ruby_sdk/models/group_stat.rb +339 -0
- data/lib/sendpost_ruby_sdk/models/ip.rb +72 -223
- data/lib/sendpost_ruby_sdk/models/ip_allocation_request.rb +29 -33
- data/lib/sendpost_ruby_sdk/models/ip_deletion_response.rb +5 -4
- data/lib/sendpost_ruby_sdk/models/ip_pool.rb +100 -66
- data/lib/sendpost_ruby_sdk/models/ip_pool_create_request.rb +101 -9
- data/lib/sendpost_ruby_sdk/models/ip_pool_delete_response.rb +5 -2
- data/lib/sendpost_ruby_sdk/models/ip_pool_stat.rb +359 -0
- data/lib/sendpost_ruby_sdk/models/ip_pool_update_request.rb +97 -7
- data/lib/sendpost_ruby_sdk/models/ip_stat.rb +369 -0
- data/lib/sendpost_ruby_sdk/models/ip_update_request.rb +4 -20
- data/lib/sendpost_ruby_sdk/models/label.rb +101 -6
- data/lib/sendpost_ruby_sdk/models/member.rb +49 -57
- data/lib/sendpost_ruby_sdk/models/message.rb +39 -120
- data/lib/sendpost_ruby_sdk/models/new_sub_account.rb +257 -0
- data/lib/sendpost_ruby_sdk/models/new_webhook.rb +407 -0
- data/lib/sendpost_ruby_sdk/models/os.rb +262 -0
- data/lib/sendpost_ruby_sdk/models/postmaster_domain_stat.rb +282 -0
- data/lib/sendpost_ruby_sdk/models/provider_stat.rb +339 -0
- data/lib/sendpost_ruby_sdk/models/r_stat.rb +231 -0
- data/lib/sendpost_ruby_sdk/models/raip_pool_stat.rb +231 -0
- data/lib/sendpost_ruby_sdk/models/rd_stat.rb +231 -0
- data/lib/sendpost_ruby_sdk/models/recipient.rb +82 -3
- data/lib/sendpost_ruby_sdk/models/rip_stat.rb +231 -0
- data/lib/sendpost_ruby_sdk/models/sd_stat.rb +349 -0
- data/lib/sendpost_ruby_sdk/models/seed_contact_stats.rb +281 -0
- data/lib/sendpost_ruby_sdk/models/smtp_auth.rb +10 -29
- data/lib/sendpost_ruby_sdk/models/stat.rb +108 -16
- data/lib/sendpost_ruby_sdk/models/sub_account.rb +57 -115
- data/lib/sendpost_ruby_sdk/models/sub_account_stat.rb +359 -0
- data/lib/sendpost_ruby_sdk/models/sub_account_stat_for_pool.rb +349 -0
- data/lib/sendpost_ruby_sdk/models/suppression.rb +82 -15
- data/lib/sendpost_ruby_sdk/models/tpsp_stat.rb +349 -0
- data/lib/sendpost_ruby_sdk/models/update_sub_account.rb +32 -3
- data/lib/sendpost_ruby_sdk/models/update_webhook.rb +83 -37
- data/lib/sendpost_ruby_sdk/models/user_agent.rb +11 -6
- data/lib/sendpost_ruby_sdk/models/validation_stat.rb +292 -0
- data/lib/sendpost_ruby_sdk/models/webhook.rb +108 -67
- data/lib/sendpost_ruby_sdk/models/webhook_object.rb +232 -0
- data/lib/sendpost_ruby_sdk/version.rb +3 -3
- data/lib/sendpost_ruby_sdk.rb +36 -26
- data/sendpost_ruby_sdk.gemspec +39 -0
- data/spec/api/webhook_reference_api_spec.rb +46 -0
- data/spec/models/account_cycle_usage_spec.rb +36 -0
- data/spec/models/account_webhook_with_stats_spec.rb +160 -0
- data/spec/models/blacklist_links_spec.rb +42 -0
- data/spec/models/blacklist_resource_spec.rb +96 -0
- data/spec/models/blacklisted_on_spec.rb +42 -0
- data/spec/models/daily_statistics_spec.rb +96 -0
- data/spec/models/date_stat_spec.rb +102 -0
- data/spec/models/delete_suppression200_response_spec.rb +36 -0
- data/spec/models/delete_suppression_request_suppressions_inner_spec.rb +36 -0
- data/spec/models/dns_record_spec.rb +52 -0
- data/spec/models/domain_stat_spec.rb +120 -0
- data/spec/models/email_type_stat_spec.rb +102 -0
- data/spec/models/error_response_error_details_inner_spec.rb +42 -0
- data/spec/models/error_response_error_spec.rb +64 -0
- data/spec/models/error_response_spec.rb +36 -0
- data/spec/models/group_stat_spec.rb +102 -0
- data/spec/models/ip_pool_stat_spec.rb +114 -0
- data/spec/models/ip_stat_spec.rb +120 -0
- data/spec/models/new_sub_account_spec.rb +36 -0
- data/spec/models/new_webhook_spec.rb +120 -0
- data/spec/models/os_spec.rb +60 -0
- data/spec/models/postmaster_domain_stat_spec.rb +72 -0
- data/spec/models/provider_stat_spec.rb +102 -0
- data/spec/models/r_stat_spec.rb +42 -0
- data/spec/models/raip_pool_stat_spec.rb +42 -0
- data/spec/models/rd_stat_spec.rb +42 -0
- data/spec/models/rip_stat_spec.rb +42 -0
- data/spec/models/sd_stat_spec.rb +108 -0
- data/spec/models/seed_contact_stats_spec.rb +66 -0
- data/spec/models/sub_account_stat_for_pool_spec.rb +108 -0
- data/spec/models/sub_account_stat_spec.rb +114 -0
- data/spec/models/tpsp_stat_spec.rb +108 -0
- data/spec/models/validation_stat_spec.rb +78 -0
- data/spec/models/webhook_object_spec.rb +42 -0
- data/spec/spec_helper.rb +2 -2
- metadata +144 -212
- data/LICENSE +0 -21
- data/docs/AccountStatsStat.md +0 -38
- data/docs/AggregatedEmailStats.md +0 -38
- data/docs/AutoWarmupPlan.md +0 -80
- data/docs/CreateSubAccountRequest.md +0 -18
- data/docs/CreateWebhookRequest.md +0 -46
- data/docs/DomainDkim.md +0 -22
- data/docs/DomainDmarc.md +0 -22
- data/docs/DomainGpt.md +0 -22
- data/docs/DomainReturnPath.md +0 -22
- data/docs/DomainTrack.md +0 -22
- data/docs/EmailMessageFrom.md +0 -20
- data/docs/EmailMessageToInner.md +0 -26
- data/docs/EmailMessageToInnerBccInner.md +0 -22
- data/docs/EmailMessageToInnerCcInner.md +0 -22
- data/docs/EmailStats.md +0 -20
- data/docs/EmailStatsStats.md +0 -38
- data/docs/MessageHeaderTo.md +0 -26
- data/docs/MessageTo.md +0 -26
- data/docs/OperatingSystem.md +0 -26
- data/docs/Person.md +0 -20
- data/docs/StatStats.md +0 -38
- data/docs/ThirdPartySendingProvider.md +0 -38
- data/lib/sendpost_ruby_sdk/models/account_stats_stat.rb +0 -310
- data/lib/sendpost_ruby_sdk/models/aggregated_email_stats.rb +0 -321
- data/lib/sendpost_ruby_sdk/models/auto_warmup_plan.rb +0 -531
- data/lib/sendpost_ruby_sdk/models/create_sub_account_request.rb +0 -221
- data/lib/sendpost_ruby_sdk/models/create_webhook_request.rb +0 -361
- data/lib/sendpost_ruby_sdk/models/delete_suppression200_response_inner.rb +0 -231
- data/lib/sendpost_ruby_sdk/models/domain_dkim.rb +0 -239
- data/lib/sendpost_ruby_sdk/models/domain_dmarc.rb +0 -239
- data/lib/sendpost_ruby_sdk/models/domain_gpt.rb +0 -239
- data/lib/sendpost_ruby_sdk/models/domain_return_path.rb +0 -239
- data/lib/sendpost_ruby_sdk/models/domain_track.rb +0 -239
- data/lib/sendpost_ruby_sdk/models/email_message_from.rb +0 -229
- data/lib/sendpost_ruby_sdk/models/email_message_reply_to.rb +0 -229
- data/lib/sendpost_ruby_sdk/models/email_message_to_inner.rb +0 -262
- data/lib/sendpost_ruby_sdk/models/email_message_to_inner_bcc_inner.rb +0 -240
- data/lib/sendpost_ruby_sdk/models/email_message_to_inner_cc_inner.rb +0 -240
- data/lib/sendpost_ruby_sdk/models/email_stats.rb +0 -230
- data/lib/sendpost_ruby_sdk/models/email_stats_stats.rb +0 -321
- data/lib/sendpost_ruby_sdk/models/message_header_to.rb +0 -268
- data/lib/sendpost_ruby_sdk/models/message_to.rb +0 -268
- data/lib/sendpost_ruby_sdk/models/operating_system.rb +0 -256
- data/lib/sendpost_ruby_sdk/models/person.rb +0 -231
- data/lib/sendpost_ruby_sdk/models/stat_stats.rb +0 -321
- data/lib/sendpost_ruby_sdk/models/third_party_sending_provider.rb +0 -310
- data/spec/api/domain_api_spec.rb +0 -85
- data/spec/api/email_api_spec.rb +0 -59
- data/spec/api/ip_api_spec.rb +0 -98
- data/spec/api/ip_pools_api_spec.rb +0 -98
- data/spec/api/message_api_spec.rb +0 -47
- data/spec/api/stats_a_api_spec.rb +0 -89
- data/spec/api/stats_api_spec.rb +0 -78
- data/spec/api/sub_account_api_spec.rb +0 -98
- data/spec/api/suppression_api_spec.rb +0 -76
- data/spec/api/webhook_api_spec.rb +0 -98
- data/spec/models/account_stats_spec.rb +0 -42
- data/spec/models/account_stats_stat_spec.rb +0 -96
- data/spec/models/aggregate_stat_spec.rb +0 -96
- data/spec/models/aggregate_stats_spec.rb +0 -96
- data/spec/models/aggregated_email_stats_spec.rb +0 -96
- data/spec/models/attachment_spec.rb +0 -42
- data/spec/models/auto_warmup_plan_spec.rb +0 -222
- data/spec/models/copy_to_spec.rb +0 -48
- data/spec/models/create_domain_request_spec.rb +0 -36
- data/spec/models/create_sub_account_request_spec.rb +0 -36
- data/spec/models/create_suppression_request_hard_bounce_inner_spec.rb +0 -36
- data/spec/models/create_suppression_request_manual_inner_spec.rb +0 -36
- data/spec/models/create_suppression_request_spam_complaint_inner_spec.rb +0 -36
- data/spec/models/create_suppression_request_spec.rb +0 -54
- data/spec/models/create_suppression_request_unsubscribe_inner_spec.rb +0 -36
- data/spec/models/create_webhook_request_spec.rb +0 -120
- data/spec/models/delete_response_spec.rb +0 -42
- data/spec/models/delete_sub_account_response_spec.rb +0 -42
- data/spec/models/delete_suppression200_response_inner_spec.rb +0 -42
- data/spec/models/delete_suppression_request_spec.rb +0 -36
- data/spec/models/delete_webhook_response_spec.rb +0 -42
- data/spec/models/device_spec.rb +0 -36
- data/spec/models/domain_dkim_spec.rb +0 -48
- data/spec/models/domain_dmarc_spec.rb +0 -48
- data/spec/models/domain_gpt_spec.rb +0 -48
- data/spec/models/domain_return_path_spec.rb +0 -48
- data/spec/models/domain_spec.rb +0 -150
- data/spec/models/domain_track_spec.rb +0 -48
- data/spec/models/eip_spec.rb +0 -36
- data/spec/models/email_address_spec.rb +0 -42
- data/spec/models/email_message_from_spec.rb +0 -42
- data/spec/models/email_message_object_spec.rb +0 -120
- data/spec/models/email_message_reply_to_spec.rb +0 -42
- data/spec/models/email_message_spec.rb +0 -138
- data/spec/models/email_message_to_inner_bcc_inner_spec.rb +0 -48
- data/spec/models/email_message_to_inner_cc_inner_spec.rb +0 -48
- data/spec/models/email_message_to_inner_spec.rb +0 -60
- data/spec/models/email_message_with_template_spec.rb +0 -138
- data/spec/models/email_response_spec.rb +0 -60
- data/spec/models/email_stats_spec.rb +0 -42
- data/spec/models/email_stats_stats_spec.rb +0 -96
- data/spec/models/event_metadata_spec.rb +0 -84
- data/spec/models/event_spec.rb +0 -150
- data/spec/models/geo_location_spec.rb +0 -60
- data/spec/models/ip_allocation_request_spec.rb +0 -42
- data/spec/models/ip_deletion_response_spec.rb +0 -42
- data/spec/models/ip_pool_create_request_spec.rb +0 -66
- data/spec/models/ip_pool_delete_response_spec.rb +0 -42
- data/spec/models/ip_pool_spec.rb +0 -108
- data/spec/models/ip_pool_update_request_spec.rb +0 -54
- data/spec/models/ip_spec.rb +0 -168
- data/spec/models/ip_update_request_spec.rb +0 -36
- data/spec/models/label_spec.rb +0 -48
- data/spec/models/member_spec.rb +0 -102
- data/spec/models/message_header_to_spec.rb +0 -60
- data/spec/models/message_spec.rb +0 -210
- data/spec/models/message_to_spec.rb +0 -60
- data/spec/models/operating_system_spec.rb +0 -60
- data/spec/models/person_spec.rb +0 -42
- data/spec/models/recipient_spec.rb +0 -60
- data/spec/models/smtp_auth_spec.rb +0 -60
- data/spec/models/stat_spec.rb +0 -42
- data/spec/models/stat_stats_spec.rb +0 -96
- data/spec/models/sub_account_spec.rb +0 -130
- data/spec/models/suppression_spec.rb +0 -60
- data/spec/models/third_party_sending_provider_spec.rb +0 -96
- data/spec/models/update_sub_account_spec.rb +0 -36
- data/spec/models/update_webhook_spec.rb +0 -120
- data/spec/models/user_agent_spec.rb +0 -54
- data/spec/models/webhook_spec.rb +0 -144
data/docs/Stat.md
CHANGED
|
@@ -4,8 +4,17 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **
|
|
8
|
-
| **
|
|
7
|
+
| **processed** | **Integer** | Total number of emails accepted by SendPost API for processing. This is the starting point - all emails submitted through the API. | [optional] |
|
|
8
|
+
| **sent** | **Integer** | Number of emails sent to recipient mail servers. sent = processed - dropped - smtpDropped | [optional] |
|
|
9
|
+
| **dropped** | **Integer** | Number of emails dropped before sending. Common reasons: - Recipient email in suppression list (hard bounce, spam complaint, unsubscribe) - Invalid recipient email format - Sender domain not verified | [optional] |
|
|
10
|
+
| **smtp_dropped** | **Integer** | Number of emails dropped at SMTP level due to policy violations or rate limiting by the receiving server before delivery attempt completed. | [optional] |
|
|
11
|
+
| **delivered** | **Integer** | Number of emails successfully delivered to recipient mail servers. Note: Delivered means accepted by the server, not necessarily in inbox. | [optional] |
|
|
12
|
+
| **soft_bounced** | **Integer** | Number of temporary delivery failures (soft bounces). Common causes: - Recipient mailbox full - Server temporarily unavailable - Message too large SendPost automatically retries soft bounces. | [optional] |
|
|
13
|
+
| **hard_bounced** | **Integer** | Number of permanent delivery failures (hard bounces). Common causes: - Recipient email doesn't exist - Domain doesn't exist - Recipient has blocked sender Hard bounced addresses are automatically added to suppression list. | [optional] |
|
|
14
|
+
| **opened** | **Integer** | Number of emails opened (tracking pixel loaded). Requires trackOpens=true. Note: Some email clients block tracking pixels. | [optional] |
|
|
15
|
+
| **clicked** | **Integer** | Number of emails with at least one link clicked. Requires trackClicks=true. | [optional] |
|
|
16
|
+
| **unsubscribed** | **Integer** | Number of recipients who clicked the unsubscribe link. Unsubscribed addresses are automatically added to suppression list. | [optional] |
|
|
17
|
+
| **spam** | **Integer** | Number of spam complaints (recipient marked email as spam). High spam rates can severely impact your sender reputation. Target: Keep spam rate below 0.1%. | [optional] |
|
|
9
18
|
|
|
10
19
|
## Example
|
|
11
20
|
|
|
@@ -13,8 +22,17 @@
|
|
|
13
22
|
require 'sendpost_ruby_sdk'
|
|
14
23
|
|
|
15
24
|
instance = Sendpost::Stat.new(
|
|
16
|
-
|
|
17
|
-
|
|
25
|
+
processed: 225,
|
|
26
|
+
sent: 220,
|
|
27
|
+
dropped: 10,
|
|
28
|
+
smtp_dropped: 5,
|
|
29
|
+
delivered: 200,
|
|
30
|
+
soft_bounced: 5,
|
|
31
|
+
hard_bounced: 10,
|
|
32
|
+
opened: 150,
|
|
33
|
+
clicked: 50,
|
|
34
|
+
unsubscribed: 6,
|
|
35
|
+
spam: 2
|
|
18
36
|
)
|
|
19
37
|
```
|
|
20
38
|
|
data/docs/StatsAApi.md
CHANGED
|
@@ -16,7 +16,7 @@ All URIs are relative to *https://api.sendpost.io/api/v1*
|
|
|
16
16
|
|
|
17
17
|
Get Account Aggregate Stats
|
|
18
18
|
|
|
19
|
-
Retrieve
|
|
19
|
+
Retrieve summarized email statistics across all sub-accounts for a date range. Returns a single aggregated record—perfect for high-level reporting and dashboards. **Use Cases:** - Annual email program review - Quarterly business reports - Month-over-month comparison - Board-level metrics - ROI calculations for email program **Example:** Get full year stats for 2024: ``` GET /account/stat/aggregate?from=2024-01-01&to=2024-12-31 ``` **Note:** Maximum date range is 366 days (1 year).
|
|
20
20
|
|
|
21
21
|
### Examples
|
|
22
22
|
|
|
@@ -32,8 +32,8 @@ Sendpost.configure do |config|
|
|
|
32
32
|
end
|
|
33
33
|
|
|
34
34
|
api_instance = Sendpost::StatsAApi.new
|
|
35
|
-
from = Date.parse('
|
|
36
|
-
to = Date.parse('
|
|
35
|
+
from = Date.parse('2024-01-01') # Date | Start date for aggregation (inclusive). Format YYYY-MM-DD.
|
|
36
|
+
to = Date.parse('2024-12-31') # Date | End date for aggregation (inclusive). Max 366 days from `from` date.
|
|
37
37
|
|
|
38
38
|
begin
|
|
39
39
|
# Get Account Aggregate Stats
|
|
@@ -66,8 +66,8 @@ end
|
|
|
66
66
|
|
|
67
67
|
| Name | Type | Description | Notes |
|
|
68
68
|
| ---- | ---- | ----------- | ----- |
|
|
69
|
-
| **from** | **Date** |
|
|
70
|
-
| **to** | **Date** |
|
|
69
|
+
| **from** | **Date** | Start date for aggregation (inclusive). Format YYYY-MM-DD. | |
|
|
70
|
+
| **to** | **Date** | End date for aggregation (inclusive). Max 366 days from `from` date. | |
|
|
71
71
|
|
|
72
72
|
### Return type
|
|
73
73
|
|
|
@@ -89,7 +89,7 @@ end
|
|
|
89
89
|
|
|
90
90
|
Get Account Group Aggregate Stats
|
|
91
91
|
|
|
92
|
-
|
|
92
|
+
Retrieve summarized email statistics for a specific group across all sub-accounts. Returns a single aggregated record for the group—ideal for campaign reporting. **Use Cases:** - Annual performance report for a specific product integration - Compare total metrics for different campaigns - Summarize email performance for a specific customer segment - Calculate ROI for a marketing campaign by group **Example:** Get yearly stats for Shopify integration: ``` GET /account/stat/aggregate/group?group=shopify&from=2024-01-01&to=2024-12-31 ``` **Note:** Maximum date range is 366 days (1 year).
|
|
93
93
|
|
|
94
94
|
### Examples
|
|
95
95
|
|
|
@@ -105,9 +105,9 @@ Sendpost.configure do |config|
|
|
|
105
105
|
end
|
|
106
106
|
|
|
107
107
|
api_instance = Sendpost::StatsAApi.new
|
|
108
|
-
group = 'shopify' # String |
|
|
109
|
-
from = Date.parse('
|
|
110
|
-
to = Date.parse('
|
|
108
|
+
group = 'shopify' # String | The group/tag name to filter and aggregate statistics by.
|
|
109
|
+
from = Date.parse('2024-01-01') # Date | Start date for aggregation (inclusive). Format YYYY-MM-DD.
|
|
110
|
+
to = Date.parse('2024-12-31') # Date | End date for aggregation (inclusive). Max 366 days from `from` date.
|
|
111
111
|
|
|
112
112
|
begin
|
|
113
113
|
# Get Account Group Aggregate Stats
|
|
@@ -140,9 +140,9 @@ end
|
|
|
140
140
|
|
|
141
141
|
| Name | Type | Description | Notes |
|
|
142
142
|
| ---- | ---- | ----------- | ----- |
|
|
143
|
-
| **group** | **String** |
|
|
144
|
-
| **from** | **Date** |
|
|
145
|
-
| **to** | **Date** |
|
|
143
|
+
| **group** | **String** | The group/tag name to filter and aggregate statistics by. | |
|
|
144
|
+
| **from** | **Date** | Start date for aggregation (inclusive). Format YYYY-MM-DD. | |
|
|
145
|
+
| **to** | **Date** | End date for aggregation (inclusive). Max 366 days from `from` date. | |
|
|
146
146
|
|
|
147
147
|
### Return type
|
|
148
148
|
|
|
@@ -164,7 +164,7 @@ end
|
|
|
164
164
|
|
|
165
165
|
List Account Group Stats
|
|
166
166
|
|
|
167
|
-
|
|
167
|
+
Retrieve daily email statistics for a specific group across all sub-accounts. Returns one record per day, filtered by the group/tag you specify. **What are Groups?** Groups (tags) are labels attached to emails when sending. They enable segmented analytics across your entire account. **Common Group Strategies:** | Strategy | Example Groups | |----------|----------------| | By Product | `shopify`, `wordpress`, `api-direct` | | By Type | `transactional`, `marketing`, `alerts` | | By Team | `sales-team`, `support`, `engineering` | | By Campaign | `black-friday-2024`, `summer-sale` | **Use Cases:** - Compare performance across products/integrations - Track specific campaign performance account-wide - Analyze transactional vs marketing metrics - Benchmark different teams' email performance **Note:** Maximum date range is 31 days.
|
|
168
168
|
|
|
169
169
|
### Examples
|
|
170
170
|
|
|
@@ -180,9 +180,9 @@ Sendpost.configure do |config|
|
|
|
180
180
|
end
|
|
181
181
|
|
|
182
182
|
api_instance = Sendpost::StatsAApi.new
|
|
183
|
-
group = 'shopify' # String |
|
|
184
|
-
from = Date.parse('
|
|
185
|
-
to = Date.parse('
|
|
183
|
+
group = 'shopify' # String | The group/tag name to filter statistics by.
|
|
184
|
+
from = Date.parse('2024-01-01') # Date | Start date for stats retrieval (inclusive). Format YYYY-MM-DD.
|
|
185
|
+
to = Date.parse('2024-01-31') # Date | End date for stats retrieval (inclusive). Max 31 days from `from` date.
|
|
186
186
|
|
|
187
187
|
begin
|
|
188
188
|
# List Account Group Stats
|
|
@@ -215,9 +215,9 @@ end
|
|
|
215
215
|
|
|
216
216
|
| Name | Type | Description | Notes |
|
|
217
217
|
| ---- | ---- | ----------- | ----- |
|
|
218
|
-
| **group** | **String** |
|
|
219
|
-
| **from** | **Date** |
|
|
220
|
-
| **to** | **Date** |
|
|
218
|
+
| **group** | **String** | The group/tag name to filter statistics by. | |
|
|
219
|
+
| **from** | **Date** | Start date for stats retrieval (inclusive). Format YYYY-MM-DD. | |
|
|
220
|
+
| **to** | **Date** | End date for stats retrieval (inclusive). Max 31 days from `from` date. | |
|
|
221
221
|
|
|
222
222
|
### Return type
|
|
223
223
|
|
|
@@ -239,7 +239,7 @@ end
|
|
|
239
239
|
|
|
240
240
|
List Account Stats
|
|
241
241
|
|
|
242
|
-
Retrieve email statistics for all sub-accounts
|
|
242
|
+
Retrieve daily email statistics aggregated across all sub-accounts. Returns one record per day within the date range—ideal for organization-wide reporting. **Metrics Per Day:** | Metric | Description | |--------|-------------| | `processed` | Total emails submitted across all sub-accounts | | `delivered` | Successfully delivered to recipients | | `dropped` | Blocked before sending | | `hardBounced` | Permanent delivery failures | | `softBounced` | Temporary delivery failures | | `opens` | Total email opens | | `clicks` | Total link clicks | | `unsubscribed` | Recipients who unsubscribed | | `spams` | Spam complaints received | **Use Cases:** - Organization-wide email performance dashboard - Billing and usage tracking across all sub-accounts - Executive reporting for email program health - Trend analysis across your entire email operation **Note:** Maximum date range is 31 days.
|
|
243
243
|
|
|
244
244
|
### Examples
|
|
245
245
|
|
|
@@ -255,8 +255,8 @@ Sendpost.configure do |config|
|
|
|
255
255
|
end
|
|
256
256
|
|
|
257
257
|
api_instance = Sendpost::StatsAApi.new
|
|
258
|
-
from = Date.parse('
|
|
259
|
-
to = Date.parse('
|
|
258
|
+
from = Date.parse('2024-01-01') # Date | Start date for stats retrieval (inclusive). Format YYYY-MM-DD.
|
|
259
|
+
to = Date.parse('2024-01-31') # Date | End date for stats retrieval (inclusive). Max 31 days from `from` date.
|
|
260
260
|
|
|
261
261
|
begin
|
|
262
262
|
# List Account Stats
|
|
@@ -289,8 +289,8 @@ end
|
|
|
289
289
|
|
|
290
290
|
| Name | Type | Description | Notes |
|
|
291
291
|
| ---- | ---- | ----------- | ----- |
|
|
292
|
-
| **from** | **Date** |
|
|
293
|
-
| **to** | **Date** |
|
|
292
|
+
| **from** | **Date** | Start date for stats retrieval (inclusive). Format YYYY-MM-DD. | |
|
|
293
|
+
| **to** | **Date** | End date for stats retrieval (inclusive). Max 31 days from `from` date. | |
|
|
294
294
|
|
|
295
295
|
### Return type
|
|
296
296
|
|
data/docs/StatsApi.md
CHANGED
|
@@ -15,7 +15,7 @@ All URIs are relative to *https://api.sendpost.io/api/v1*
|
|
|
15
15
|
|
|
16
16
|
Get Aggregate Stats
|
|
17
17
|
|
|
18
|
-
|
|
18
|
+
Retrieve summarized email statistics for a sub-account over a date range. Unlike daily stats, this returns a single record with totals across all days—ideal for high-level reporting. **Response includes total counts for:** - `processed` - Total emails submitted - `delivered` - Successfully delivered - `dropped` - Blocked before sending - `hardBounced` / `softBounced` - Bounce breakdowns - `opens` / `clicks` - Engagement totals - `unsubscribed` / `spams` - Negative signals **Use Cases:** - Monthly performance reports - Executive dashboards - Billing period summaries - Year-over-year comparisons - SLA compliance reports **Example:** To get Q1 2024 totals: ``` GET /account/subaccount/stat/11/aggregate?from=2024-01-01&to=2024-03-31 ``` **Note:** Maximum date range is 366 days (1 year).
|
|
19
19
|
|
|
20
20
|
### Examples
|
|
21
21
|
|
|
@@ -31,9 +31,9 @@ Sendpost.configure do |config|
|
|
|
31
31
|
end
|
|
32
32
|
|
|
33
33
|
api_instance = Sendpost::StatsApi.new
|
|
34
|
-
from = Date.parse('
|
|
35
|
-
to = Date.parse('
|
|
36
|
-
subaccount_id = 11 # Integer | The ID of the
|
|
34
|
+
from = Date.parse('2024-01-01') # Date | Start date for aggregation (inclusive). Format YYYY-MM-DD.
|
|
35
|
+
to = Date.parse('2024-03-31') # Date | End date for aggregation (inclusive). Max 366 days from `from` date.
|
|
36
|
+
subaccount_id = 11 # Integer | The unique ID of the sub-account.
|
|
37
37
|
|
|
38
38
|
begin
|
|
39
39
|
# Get Aggregate Stats
|
|
@@ -66,9 +66,9 @@ end
|
|
|
66
66
|
|
|
67
67
|
| Name | Type | Description | Notes |
|
|
68
68
|
| ---- | ---- | ----------- | ----- |
|
|
69
|
-
| **from** | **Date** | Start date for
|
|
70
|
-
| **to** | **Date** |
|
|
71
|
-
| **subaccount_id** | **Integer** | The ID of the
|
|
69
|
+
| **from** | **Date** | Start date for aggregation (inclusive). Format YYYY-MM-DD. | |
|
|
70
|
+
| **to** | **Date** | End date for aggregation (inclusive). Max 366 days from `from` date. | |
|
|
71
|
+
| **subaccount_id** | **Integer** | The unique ID of the sub-account. | |
|
|
72
72
|
|
|
73
73
|
### Return type
|
|
74
74
|
|
|
@@ -90,7 +90,7 @@ end
|
|
|
90
90
|
|
|
91
91
|
List Stats
|
|
92
92
|
|
|
93
|
-
|
|
93
|
+
Retrieve daily email statistics for a specific sub-account. Returns one record per day within the date range, perfect for charting trends and identifying patterns. **Metrics Per Day:** | Metric | Description | |--------|-------------| | `processed` | Emails submitted to SendPost | | `delivered` | Successfully delivered to recipient's mailbox | | `dropped` | Blocked before sending (suppressed, invalid, etc.) | | `hardBounced` | Permanent failures (invalid address, domain doesn't exist) | | `softBounced` | Temporary failures (mailbox full, server down) | | `opens` | Total email opens (includes multiple opens per recipient) | | `clicks` | Total link clicks | | `unsubscribed` | Recipients who unsubscribed | | `spams` | Emails marked as spam by recipients | **Key Rates to Calculate:** - Delivery Rate = `delivered / processed × 100` - Open Rate = `opens / delivered × 100` - Click Rate = `clicks / delivered × 100` - Bounce Rate = `(hardBounced + softBounced) / processed × 100` **Use Cases:** - Daily performance dashboard - Week-over-week trend analysis - Identifying delivery issues early - SLA monitoring and reporting **Note:** Maximum date range is 31 days. Both `from` and `to` dates are inclusive.
|
|
94
94
|
|
|
95
95
|
### Examples
|
|
96
96
|
|
|
@@ -106,9 +106,9 @@ Sendpost.configure do |config|
|
|
|
106
106
|
end
|
|
107
107
|
|
|
108
108
|
api_instance = Sendpost::StatsApi.new
|
|
109
|
-
from = Date.parse('
|
|
110
|
-
to = Date.parse('
|
|
111
|
-
subaccount_id = 11 # Integer | The ID of the
|
|
109
|
+
from = Date.parse('2024-01-01') # Date | Start date for stats retrieval (inclusive). Format YYYY-MM-DD.
|
|
110
|
+
to = Date.parse('2024-01-31') # Date | End date for stats retrieval (inclusive). Must be after `from` date with max 31 days range.
|
|
111
|
+
subaccount_id = 11 # Integer | The unique ID of the sub-account to retrieve stats for.
|
|
112
112
|
|
|
113
113
|
begin
|
|
114
114
|
# List Stats
|
|
@@ -141,9 +141,9 @@ end
|
|
|
141
141
|
|
|
142
142
|
| Name | Type | Description | Notes |
|
|
143
143
|
| ---- | ---- | ----------- | ----- |
|
|
144
|
-
| **from** | **Date** | Start date for stats retrieval. | |
|
|
145
|
-
| **to** | **Date** |
|
|
146
|
-
| **subaccount_id** | **Integer** | The ID of the
|
|
144
|
+
| **from** | **Date** | Start date for stats retrieval (inclusive). Format YYYY-MM-DD. | |
|
|
145
|
+
| **to** | **Date** | End date for stats retrieval (inclusive). Must be after `from` date with max 31 days range. | |
|
|
146
|
+
| **subaccount_id** | **Integer** | The unique ID of the sub-account to retrieve stats for. | |
|
|
147
147
|
|
|
148
148
|
### Return type
|
|
149
149
|
|
|
@@ -165,7 +165,7 @@ end
|
|
|
165
165
|
|
|
166
166
|
Get Group Aggregate Stats
|
|
167
167
|
|
|
168
|
-
|
|
168
|
+
Retrieve aggregated email statistics filtered by a specific group/tag. Groups are labels you assign when sending emails to categorize and segment your analytics. **What are Groups?** Groups (also called tags) are strings you attach to emails when sending. They help you: - Track different email types (transactional vs marketing) - Segment by campaign or feature - Compare performance across categories **Setting Groups When Sending:** ```json { \"from\": { \"email\": \"orders@shop.com\" }, \"to\": [{ \"email\": \"customer@example.com\" }], \"subject\": \"Order Confirmation\", \"groups\": [\"order-confirmations\", \"transactional\"] } ``` **Use Cases:** - Compare welcome email vs password reset performance - Track marketing campaign performance by campaign ID - Measure transactional vs promotional email metrics - Analyze A/B test results by variant group **Example:** Get stats for \"welcome-emails\" group: ``` GET /account/subaccount/stat/11/group?group=welcome-emails&from=2024-01-01&to=2024-03-31 ``` **Note:** Maximum date range is 366 days.
|
|
169
169
|
|
|
170
170
|
### Examples
|
|
171
171
|
|
|
@@ -181,8 +181,8 @@ Sendpost.configure do |config|
|
|
|
181
181
|
end
|
|
182
182
|
|
|
183
183
|
api_instance = Sendpost::StatsApi.new
|
|
184
|
-
group = '
|
|
185
|
-
from = Date.parse('
|
|
184
|
+
group = 'order-confirmations' # String | The group/tag name to filter statistics by. Must match the group name used when sending emails.
|
|
185
|
+
from = Date.parse('2024-01-01') # Date | Start date for aggregation (inclusive). Format YYYY-MM-DD.
|
|
186
186
|
to = Date.parse('2013-10-20') # Date | The ending date for the aggregated stats (Note: `from` should be earlier than `to` and the date range should not exceed 366 days)
|
|
187
187
|
subaccount_id = 11 # Integer | The ID of the subaccount to retrieve
|
|
188
188
|
|
|
@@ -217,8 +217,8 @@ end
|
|
|
217
217
|
|
|
218
218
|
| Name | Type | Description | Notes |
|
|
219
219
|
| ---- | ---- | ----------- | ----- |
|
|
220
|
-
| **group** | **String** |
|
|
221
|
-
| **from** | **Date** |
|
|
220
|
+
| **group** | **String** | The group/tag name to filter statistics by. Must match the group name used when sending emails. | |
|
|
221
|
+
| **from** | **Date** | Start date for aggregation (inclusive). Format YYYY-MM-DD. | |
|
|
222
222
|
| **to** | **Date** | The ending date for the aggregated stats (Note: `from` should be earlier than `to` and the date range should not exceed 366 days) | |
|
|
223
223
|
| **subaccount_id** | **Integer** | The ID of the subaccount to retrieve | |
|
|
224
224
|
|
data/docs/SubAccount.md
CHANGED
|
@@ -4,22 +4,15 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **id** | **Integer** | Unique
|
|
8
|
-
| **
|
|
9
|
-
| **name** | **String** |
|
|
10
|
-
| **
|
|
11
|
-
| **
|
|
12
|
-
| **
|
|
13
|
-
| **
|
|
14
|
-
| **
|
|
15
|
-
| **
|
|
16
|
-
| **updated_by** | **Hash<String, Object>** | Member who updated the sub-account | [optional] |
|
|
17
|
-
| **blocked** | **Boolean** | Indicates whether the sub-account is blocked | [optional] |
|
|
18
|
-
| **blocked_at** | **Integer** | UNIX epoch nano timestamp when the sub-account was blocked (0 if not blocked) | [optional] |
|
|
19
|
-
| **block_reason** | **String** | Reason for blocking the sub-account | [optional] |
|
|
20
|
-
| **hb_exempt** | **Boolean** | Indicates whether the sub-account is exempt from hard bounce tracking | [optional] |
|
|
21
|
-
| **generate_weekly_report** | **Boolean** | Indicates whether weekly reports are generated for this sub-account | [optional] |
|
|
22
|
-
| **handlers** | **Array<String>** | Handlers associated with the sub-account | [optional] |
|
|
7
|
+
| **id** | **Integer** | Unique identifier for the sub-account | [optional] |
|
|
8
|
+
| **account_id** | **Integer** | Identifier of the parent account this sub-account belongs to | [optional] |
|
|
9
|
+
| **name** | **String** | Display name for the sub-account. Must be unique within your account. Use descriptive names. | [optional] |
|
|
10
|
+
| **api_key** | **String** | API key for this sub-account. Use this as the `X-SubAccount-ApiKey` header when making API calls for this sub-account (sending emails, managing domains, etc.). **Security:** Treat this like a password. Rotate if compromised. | [optional] |
|
|
11
|
+
| **type** | **Integer** | Type of sub-account: - `0` = Default (the primary sub-account created with your account) - `1` = Custom (additional sub-accounts you create) Note: The default sub-account cannot be deleted. | [optional] |
|
|
12
|
+
| **is_plus** | **Boolean** | Whether this sub-account belongs to a SendX Plus customer. SendX Plus is a premium tier that provides enhanced features and support. | [optional] |
|
|
13
|
+
| **labels** | [**Array<Label>**](Label.md) | Custom labels for organizing and filtering sub-accounts | [optional] |
|
|
14
|
+
| **blocked** | **Boolean** | Whether the sub-account is blocked from sending. A blocked sub-account cannot send emails. Common reasons: - High bounce/spam rates - Billing issues - Policy violations - Manual suspension by administrator | [optional] |
|
|
15
|
+
| **created** | **Integer** | UNIX epoch timestamp in nanoseconds when the sub-account was created | [optional] |
|
|
23
16
|
|
|
24
17
|
## Example
|
|
25
18
|
|
|
@@ -28,21 +21,14 @@ require 'sendpost_ruby_sdk'
|
|
|
28
21
|
|
|
29
22
|
instance = Sendpost::SubAccount.new(
|
|
30
23
|
id: 50441,
|
|
24
|
+
account_id: 4021,
|
|
25
|
+
name: Transactional - Production,
|
|
31
26
|
api_key: pR0YIuxYSbVwmQi2Y8Qs,
|
|
32
|
-
name: API,
|
|
33
|
-
labels: [],
|
|
34
|
-
smtp_auths: null,
|
|
35
27
|
type: 1,
|
|
36
28
|
is_plus: false,
|
|
37
|
-
|
|
38
|
-
created_by: null,
|
|
39
|
-
updated_by: null,
|
|
29
|
+
labels: null,
|
|
40
30
|
blocked: false,
|
|
41
|
-
|
|
42
|
-
block_reason: ,
|
|
43
|
-
hb_exempt: false,
|
|
44
|
-
generate_weekly_report: false,
|
|
45
|
-
handlers: []
|
|
31
|
+
created: 1704067200000000000
|
|
46
32
|
)
|
|
47
33
|
```
|
|
48
34
|
|
data/docs/SubAccountApi.md
CHANGED
|
@@ -13,11 +13,11 @@ All URIs are relative to *https://api.sendpost.io/api/v1*
|
|
|
13
13
|
|
|
14
14
|
## create_sub_account
|
|
15
15
|
|
|
16
|
-
> <SubAccount> create_sub_account(
|
|
16
|
+
> <SubAccount> create_sub_account(new_sub_account)
|
|
17
17
|
|
|
18
18
|
Create Sub-Account
|
|
19
19
|
|
|
20
|
-
|
|
20
|
+
Create a new sub-account to segment your email sending. Each sub-account gets its own API key, suppression list, and statistics. **What You Get:** - Unique `X-SubAccount-ApiKey` for authentication - Isolated email statistics - Separate suppression management - Independent domain configuration - Optional SMTP credentials **Naming Best Practices:** - Use descriptive names: `Transactional_Orders`, `Marketing_Newsletter` - Include environment: `Production_Alerts`, `Staging_Tests` - For multi-tenant: `Client_CompanyName` **Use Cases:** - New application or microservice needing email - Onboarding a new client in multi-tenant setup - Creating isolated testing environment - Separating email streams for analytics
|
|
21
21
|
|
|
22
22
|
### Examples
|
|
23
23
|
|
|
@@ -33,11 +33,11 @@ Sendpost.configure do |config|
|
|
|
33
33
|
end
|
|
34
34
|
|
|
35
35
|
api_instance = Sendpost::SubAccountApi.new
|
|
36
|
-
|
|
36
|
+
new_sub_account = Sendpost::NewSubAccount.new({name: 'Marketing - Production'}) # NewSubAccount |
|
|
37
37
|
|
|
38
38
|
begin
|
|
39
39
|
# Create Sub-Account
|
|
40
|
-
result = api_instance.create_sub_account(
|
|
40
|
+
result = api_instance.create_sub_account(new_sub_account)
|
|
41
41
|
p result
|
|
42
42
|
rescue Sendpost::ApiError => e
|
|
43
43
|
puts "Error when calling SubAccountApi->create_sub_account: #{e}"
|
|
@@ -48,12 +48,12 @@ end
|
|
|
48
48
|
|
|
49
49
|
This returns an Array which contains the response data, status code and headers.
|
|
50
50
|
|
|
51
|
-
> <Array(<SubAccount>, Integer, Hash)> create_sub_account_with_http_info(
|
|
51
|
+
> <Array(<SubAccount>, Integer, Hash)> create_sub_account_with_http_info(new_sub_account)
|
|
52
52
|
|
|
53
53
|
```ruby
|
|
54
54
|
begin
|
|
55
55
|
# Create Sub-Account
|
|
56
|
-
data, status_code, headers = api_instance.create_sub_account_with_http_info(
|
|
56
|
+
data, status_code, headers = api_instance.create_sub_account_with_http_info(new_sub_account)
|
|
57
57
|
p status_code # => 2xx
|
|
58
58
|
p headers # => { ... }
|
|
59
59
|
p data # => <SubAccount>
|
|
@@ -66,7 +66,7 @@ end
|
|
|
66
66
|
|
|
67
67
|
| Name | Type | Description | Notes |
|
|
68
68
|
| ---- | ---- | ----------- | ----- |
|
|
69
|
-
| **
|
|
69
|
+
| **new_sub_account** | [**NewSubAccount**](NewSubAccount.md) | | |
|
|
70
70
|
|
|
71
71
|
### Return type
|
|
72
72
|
|
|
@@ -88,7 +88,7 @@ end
|
|
|
88
88
|
|
|
89
89
|
Delete Sub-Account
|
|
90
90
|
|
|
91
|
-
|
|
91
|
+
Remove a sub-account from your organization. This action is irreversible. **⚠️ Before Deleting:** - Export any needed statistics or suppression lists - Update applications using this sub-account's API key - Ensure no active email sending relies on this sub-account **What Gets Deleted:** - All sub-account configuration - Associated API keys (will stop working) - Statistics are retained for your account records **Note:** The default sub-account (type `0`) cannot be deleted.
|
|
92
92
|
|
|
93
93
|
### Examples
|
|
94
94
|
|
|
@@ -104,7 +104,7 @@ Sendpost.configure do |config|
|
|
|
104
104
|
end
|
|
105
105
|
|
|
106
106
|
api_instance = Sendpost::SubAccountApi.new
|
|
107
|
-
subaccount_id = 12 # Integer | The ID of the sub-account to delete.
|
|
107
|
+
subaccount_id = 12 # Integer | The unique ID of the sub-account to delete.
|
|
108
108
|
|
|
109
109
|
begin
|
|
110
110
|
# Delete Sub-Account
|
|
@@ -137,7 +137,7 @@ end
|
|
|
137
137
|
|
|
138
138
|
| Name | Type | Description | Notes |
|
|
139
139
|
| ---- | ---- | ----------- | ----- |
|
|
140
|
-
| **subaccount_id** | **Integer** | The ID of the sub-account to delete. | |
|
|
140
|
+
| **subaccount_id** | **Integer** | The unique ID of the sub-account to delete. | |
|
|
141
141
|
|
|
142
142
|
### Return type
|
|
143
143
|
|
|
@@ -159,7 +159,7 @@ end
|
|
|
159
159
|
|
|
160
160
|
List Sub-Accounts
|
|
161
161
|
|
|
162
|
-
|
|
162
|
+
Retrieve all sub-accounts under your main account. Sub-accounts allow you to segment email sending for different applications, brands, or use cases. **Sub-Account Types:** | Type | Value | Description | |------|-------|-------------| | Default | `0` | Primary sub-account created with your account (cannot be deleted) | | Custom | `1` | Additional sub-accounts you create | **Each Sub-Account Has:** - Unique `X-SubAccount-ApiKey` for API authentication - Independent suppression list - Isolated email statistics - Own domain configurations - SMTP credentials (if enabled) **Use Cases:** - Separate transactional and marketing emails - Multi-tenant SaaS applications (one sub-account per customer) - Different brands or product lines - Development/staging/production environments **Note:** `isPlus` indicates SendX Plus customers with premium features.
|
|
163
163
|
|
|
164
164
|
### Examples
|
|
165
165
|
|
|
@@ -176,9 +176,9 @@ end
|
|
|
176
176
|
|
|
177
177
|
api_instance = Sendpost::SubAccountApi.new
|
|
178
178
|
opts = {
|
|
179
|
-
limit: 10, # Integer | Number of records to return per request.
|
|
180
|
-
offset: 0, # Integer | Number of initial records to skip.
|
|
181
|
-
search: '
|
|
179
|
+
limit: 10, # Integer | Number of records to return per request. Default 20.
|
|
180
|
+
offset: 0, # Integer | Number of initial records to skip for pagination.
|
|
181
|
+
search: 'Production' # String | Case-insensitive search against sub-account names.
|
|
182
182
|
}
|
|
183
183
|
|
|
184
184
|
begin
|
|
@@ -212,9 +212,9 @@ end
|
|
|
212
212
|
|
|
213
213
|
| Name | Type | Description | Notes |
|
|
214
214
|
| ---- | ---- | ----------- | ----- |
|
|
215
|
-
| **limit** | **Integer** | Number of records to return per request. | [optional] |
|
|
216
|
-
| **offset** | **Integer** | Number of initial records to skip. | [optional] |
|
|
217
|
-
| **search** | **String** | Case-insensitive search against
|
|
215
|
+
| **limit** | **Integer** | Number of records to return per request. Default 20. | [optional][default to 20] |
|
|
216
|
+
| **offset** | **Integer** | Number of initial records to skip for pagination. | [optional][default to 0] |
|
|
217
|
+
| **search** | **String** | Case-insensitive search against sub-account names. | [optional] |
|
|
218
218
|
|
|
219
219
|
### Return type
|
|
220
220
|
|
|
@@ -236,7 +236,7 @@ end
|
|
|
236
236
|
|
|
237
237
|
Get Sub-Account
|
|
238
238
|
|
|
239
|
-
|
|
239
|
+
Retrieve detailed information about a specific sub-account, including API keys, SMTP credentials, and configuration. **Response Includes:** - Sub-account name and ID - API key for sub-account authentication - SMTP credentials (if enabled) - Team members with access - Labels/tags for categorization - Creation timestamp
|
|
240
240
|
|
|
241
241
|
### Examples
|
|
242
242
|
|
|
@@ -252,7 +252,7 @@ Sendpost.configure do |config|
|
|
|
252
252
|
end
|
|
253
253
|
|
|
254
254
|
api_instance = Sendpost::SubAccountApi.new
|
|
255
|
-
subaccount_id = 11 # Integer | The ID of the sub-account to retrieve.
|
|
255
|
+
subaccount_id = 11 # Integer | The unique ID of the sub-account to retrieve.
|
|
256
256
|
|
|
257
257
|
begin
|
|
258
258
|
# Get Sub-Account
|
|
@@ -285,7 +285,7 @@ end
|
|
|
285
285
|
|
|
286
286
|
| Name | Type | Description | Notes |
|
|
287
287
|
| ---- | ---- | ----------- | ----- |
|
|
288
|
-
| **subaccount_id** | **Integer** | The ID of the sub-account to retrieve. | |
|
|
288
|
+
| **subaccount_id** | **Integer** | The unique ID of the sub-account to retrieve. | |
|
|
289
289
|
|
|
290
290
|
### Return type
|
|
291
291
|
|
|
@@ -307,7 +307,7 @@ end
|
|
|
307
307
|
|
|
308
308
|
Update Sub-Account
|
|
309
309
|
|
|
310
|
-
|
|
310
|
+
Modify settings for an existing sub-account. Use this to rename sub-accounts, update labels, or modify configuration. **What Can Be Updated:** - Sub-account name - Labels/tags for categorization - Other configuration settings **Use Cases:** - Rename sub-account for clarity - Update labels for organizational changes - Modify settings after initial setup
|
|
311
311
|
|
|
312
312
|
### Examples
|
|
313
313
|
|
|
@@ -324,7 +324,7 @@ end
|
|
|
324
324
|
|
|
325
325
|
api_instance = Sendpost::SubAccountApi.new
|
|
326
326
|
update_sub_account = Sendpost::UpdateSubAccount.new # UpdateSubAccount |
|
|
327
|
-
subaccount_id = 12 # Integer | The ID of the sub-account to update.
|
|
327
|
+
subaccount_id = 12 # Integer | The unique ID of the sub-account to update.
|
|
328
328
|
|
|
329
329
|
begin
|
|
330
330
|
# Update Sub-Account
|
|
@@ -358,7 +358,7 @@ end
|
|
|
358
358
|
| Name | Type | Description | Notes |
|
|
359
359
|
| ---- | ---- | ----------- | ----- |
|
|
360
360
|
| **update_sub_account** | [**UpdateSubAccount**](UpdateSubAccount.md) | | |
|
|
361
|
-
| **subaccount_id** | **Integer** | The ID of the sub-account to update. | |
|
|
361
|
+
| **subaccount_id** | **Integer** | The unique ID of the sub-account to update. | |
|
|
362
362
|
|
|
363
363
|
### Return type
|
|
364
364
|
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Sendpost::SubAccountStat
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **processed** | **Integer** | Total number of emails accepted by SendPost API for processing. This is the starting point - all emails submitted through the API. | [optional] |
|
|
8
|
+
| **sent** | **Integer** | Number of emails sent to recipient mail servers. sent = processed - dropped - smtpDropped | [optional] |
|
|
9
|
+
| **dropped** | **Integer** | Number of emails dropped before sending. Common reasons: - Recipient email in suppression list (hard bounce, spam complaint, unsubscribe) - Invalid recipient email format - Sender domain not verified | [optional] |
|
|
10
|
+
| **smtp_dropped** | **Integer** | Number of emails dropped at SMTP level due to policy violations or rate limiting by the receiving server before delivery attempt completed. | [optional] |
|
|
11
|
+
| **delivered** | **Integer** | Number of emails successfully delivered to recipient mail servers. Note: Delivered means accepted by the server, not necessarily in inbox. | [optional] |
|
|
12
|
+
| **soft_bounced** | **Integer** | Number of temporary delivery failures (soft bounces). Common causes: - Recipient mailbox full - Server temporarily unavailable - Message too large SendPost automatically retries soft bounces. | [optional] |
|
|
13
|
+
| **hard_bounced** | **Integer** | Number of permanent delivery failures (hard bounces). Common causes: - Recipient email doesn't exist - Domain doesn't exist - Recipient has blocked sender Hard bounced addresses are automatically added to suppression list. | [optional] |
|
|
14
|
+
| **opened** | **Integer** | Number of emails opened (tracking pixel loaded). Requires trackOpens=true. Note: Some email clients block tracking pixels. | [optional] |
|
|
15
|
+
| **clicked** | **Integer** | Number of emails with at least one link clicked. Requires trackClicks=true. | [optional] |
|
|
16
|
+
| **unsubscribed** | **Integer** | Number of recipients who clicked the unsubscribe link. Unsubscribed addresses are automatically added to suppression list. | [optional] |
|
|
17
|
+
| **spam** | **Integer** | Number of spam complaints (recipient marked email as spam). High spam rates can severely impact your sender reputation. Target: Keep spam rate below 0.1%. | [optional] |
|
|
18
|
+
| **sub_account_id** | **Integer** | Unique identifier of the sub-account. | [optional] |
|
|
19
|
+
| **sub_account_name** | **String** | Human-readable name of the sub-account. | [optional] |
|
|
20
|
+
| **blocked** | **Boolean** | Whether the sub-account is currently blocked from sending. | [optional] |
|
|
21
|
+
|
|
22
|
+
## Example
|
|
23
|
+
|
|
24
|
+
```ruby
|
|
25
|
+
require 'sendpost_ruby_sdk'
|
|
26
|
+
|
|
27
|
+
instance = Sendpost::SubAccountStat.new(
|
|
28
|
+
processed: 225,
|
|
29
|
+
sent: 220,
|
|
30
|
+
dropped: 10,
|
|
31
|
+
smtp_dropped: 5,
|
|
32
|
+
delivered: 200,
|
|
33
|
+
soft_bounced: 5,
|
|
34
|
+
hard_bounced: 10,
|
|
35
|
+
opened: 150,
|
|
36
|
+
clicked: 50,
|
|
37
|
+
unsubscribed: 6,
|
|
38
|
+
spam: 2,
|
|
39
|
+
sub_account_id: 42,
|
|
40
|
+
sub_account_name: Marketing,
|
|
41
|
+
blocked: false
|
|
42
|
+
)
|
|
43
|
+
```
|
|
44
|
+
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# Sendpost::SubAccountStatForPool
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **processed** | **Integer** | Total number of emails accepted by SendPost API for processing. This is the starting point - all emails submitted through the API. | [optional] |
|
|
8
|
+
| **sent** | **Integer** | Number of emails sent to recipient mail servers. sent = processed - dropped - smtpDropped | [optional] |
|
|
9
|
+
| **dropped** | **Integer** | Number of emails dropped before sending. Common reasons: - Recipient email in suppression list (hard bounce, spam complaint, unsubscribe) - Invalid recipient email format - Sender domain not verified | [optional] |
|
|
10
|
+
| **smtp_dropped** | **Integer** | Number of emails dropped at SMTP level due to policy violations or rate limiting by the receiving server before delivery attempt completed. | [optional] |
|
|
11
|
+
| **delivered** | **Integer** | Number of emails successfully delivered to recipient mail servers. Note: Delivered means accepted by the server, not necessarily in inbox. | [optional] |
|
|
12
|
+
| **soft_bounced** | **Integer** | Number of temporary delivery failures (soft bounces). Common causes: - Recipient mailbox full - Server temporarily unavailable - Message too large SendPost automatically retries soft bounces. | [optional] |
|
|
13
|
+
| **hard_bounced** | **Integer** | Number of permanent delivery failures (hard bounces). Common causes: - Recipient email doesn't exist - Domain doesn't exist - Recipient has blocked sender Hard bounced addresses are automatically added to suppression list. | [optional] |
|
|
14
|
+
| **opened** | **Integer** | Number of emails opened (tracking pixel loaded). Requires trackOpens=true. Note: Some email clients block tracking pixels. | [optional] |
|
|
15
|
+
| **clicked** | **Integer** | Number of emails with at least one link clicked. Requires trackClicks=true. | [optional] |
|
|
16
|
+
| **unsubscribed** | **Integer** | Number of recipients who clicked the unsubscribe link. Unsubscribed addresses are automatically added to suppression list. | [optional] |
|
|
17
|
+
| **spam** | **Integer** | Number of spam complaints (recipient marked email as spam). High spam rates can severely impact your sender reputation. Target: Keep spam rate below 0.1%. | [optional] |
|
|
18
|
+
| **sub_account_id** | **Integer** | Unique identifier of the sub-account. | [optional] |
|
|
19
|
+
| **name** | **String** | Human-readable name of the sub-account. | [optional] |
|
|
20
|
+
|
|
21
|
+
## Example
|
|
22
|
+
|
|
23
|
+
```ruby
|
|
24
|
+
require 'sendpost_ruby_sdk'
|
|
25
|
+
|
|
26
|
+
instance = Sendpost::SubAccountStatForPool.new(
|
|
27
|
+
processed: 225,
|
|
28
|
+
sent: 220,
|
|
29
|
+
dropped: 10,
|
|
30
|
+
smtp_dropped: 5,
|
|
31
|
+
delivered: 200,
|
|
32
|
+
soft_bounced: 5,
|
|
33
|
+
hard_bounced: 10,
|
|
34
|
+
opened: 150,
|
|
35
|
+
clicked: 50,
|
|
36
|
+
unsubscribed: 6,
|
|
37
|
+
spam: 2,
|
|
38
|
+
sub_account_id: 42,
|
|
39
|
+
name: Marketing
|
|
40
|
+
)
|
|
41
|
+
```
|
|
42
|
+
|