sentdm 0.26.0 → 0.28.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/CHANGELOG.md +40 -0
- data/README.md +1 -27
- data/lib/sentdm/client.rb +71 -8
- data/lib/sentdm/internal/type/base_model.rb +5 -5
- data/lib/sentdm/models/contact_create_response.rb +249 -0
- data/lib/sentdm/models/contact_delete_params.rb +16 -2
- data/lib/sentdm/models/contact_list_response.rb +299 -16
- data/lib/sentdm/models/contact_retrieve_message_summary_response.rb +186 -0
- data/lib/sentdm/models/contact_retrieve_response.rb +249 -0
- data/lib/sentdm/models/contact_update_response.rb +249 -0
- data/lib/sentdm/models/conversation_list_messages_response.rb +436 -0
- data/lib/sentdm/models/conversation_list_response.rb +433 -0
- data/lib/sentdm/models/inbound_message_event.rb +52 -0
- data/lib/sentdm/models/inbound_message_event_payload.rb +81 -0
- data/lib/sentdm/models/me_retrieve_response.rb +242 -12
- data/lib/sentdm/models/message_event.rb +53 -0
- data/lib/sentdm/models/message_event_payload.rb +92 -0
- data/lib/sentdm/models/message_retrieve_activities_response.rb +165 -7
- data/lib/sentdm/models/message_retrieve_status_response.rb +74 -6
- data/lib/sentdm/models/message_send_response.rb +113 -28
- data/lib/sentdm/models/number_lookup_response.rb +74 -6
- data/lib/sentdm/models/profile_complete_response.rb +74 -6
- data/lib/sentdm/models/profile_create_params.rb +378 -26
- data/lib/sentdm/models/profile_create_response.rb +760 -0
- data/lib/sentdm/models/profile_delete_params.rb +16 -2
- data/lib/sentdm/models/profile_list_response.rb +825 -14
- data/lib/sentdm/models/profile_retrieve_response.rb +762 -0
- data/lib/sentdm/models/profile_update_params.rb +391 -24
- data/lib/sentdm/models/profile_update_response.rb +760 -0
- data/lib/sentdm/models/profiles/campaign_create_params.rb +156 -3
- data/lib/sentdm/models/profiles/campaign_create_response.rb +420 -0
- data/lib/sentdm/models/profiles/campaign_delete_params.rb +17 -2
- data/lib/sentdm/models/profiles/campaign_list_response.rb +421 -0
- data/lib/sentdm/models/profiles/campaign_update_params.rb +156 -3
- data/lib/sentdm/models/profiles/campaign_update_response.rb +420 -0
- data/lib/sentdm/models/template_create_response.rb +209 -0
- data/lib/sentdm/models/template_event.rb +52 -0
- data/lib/sentdm/models/template_event_payload.rb +88 -0
- data/lib/sentdm/models/template_list_params.rb +9 -2
- data/lib/sentdm/models/template_list_response.rb +262 -16
- data/lib/sentdm/models/template_retrieve_response.rb +209 -0
- data/lib/sentdm/models/template_update_response.rb +209 -0
- data/lib/sentdm/models/user_invite_response.rb +201 -0
- data/lib/sentdm/models/user_list_response.rb +259 -14
- data/lib/sentdm/models/user_remove_params.rb +16 -2
- data/lib/sentdm/models/user_retrieve_response.rb +201 -0
- data/lib/sentdm/models/user_update_role_response.rb +201 -0
- data/lib/sentdm/models/webhook_create_response.rb +229 -0
- data/lib/sentdm/models/webhook_list_event_types_response.rb +213 -13
- data/lib/sentdm/models/webhook_list_events_response.rb +207 -16
- data/lib/sentdm/models/webhook_list_response.rb +280 -15
- data/lib/sentdm/models/webhook_retrieve_response.rb +229 -0
- data/lib/sentdm/models/webhook_rotate_secret_params.rb +17 -2
- data/lib/sentdm/models/webhook_rotate_secret_response.rb +74 -6
- data/lib/sentdm/models/webhook_test_response.rb +74 -6
- data/lib/sentdm/models/webhook_toggle_status_response.rb +229 -0
- data/lib/sentdm/models/webhook_update_response.rb +229 -0
- data/lib/sentdm/models.rb +11 -51
- data/lib/sentdm/resources/contacts.rb +30 -13
- data/lib/sentdm/resources/conversations.rb +12 -4
- data/lib/sentdm/resources/me.rb +6 -1
- data/lib/sentdm/resources/messages.rb +17 -5
- data/lib/sentdm/resources/numbers.rb +6 -1
- data/lib/sentdm/resources/profiles/campaigns.rb +47 -9
- data/lib/sentdm/resources/profiles.rb +137 -61
- data/lib/sentdm/resources/templates.rb +14 -8
- data/lib/sentdm/resources/users.rb +15 -10
- data/lib/sentdm/resources/webhooks.rb +19 -9
- data/lib/sentdm/version.rb +1 -1
- data/lib/sentdm.rb +28 -32
- data/rbi/sentdm/client.rbi +71 -8
- data/rbi/sentdm/models/contact_create_response.rbi +407 -0
- data/rbi/sentdm/models/contact_delete_params.rbi +19 -2
- data/rbi/sentdm/models/contact_list_response.rbi +527 -21
- data/rbi/sentdm/models/contact_retrieve_message_summary_response.rbi +397 -0
- data/rbi/sentdm/models/contact_retrieve_response.rbi +409 -0
- data/rbi/sentdm/models/contact_update_response.rbi +407 -0
- data/rbi/sentdm/models/conversation_list_messages_response.rbi +843 -0
- data/rbi/sentdm/models/conversation_list_response.rbi +819 -0
- data/rbi/sentdm/models/inbound_message_event.rbi +88 -0
- data/rbi/sentdm/models/inbound_message_event_payload.rbi +122 -0
- data/rbi/sentdm/models/me_retrieve_response.rbi +367 -16
- data/rbi/sentdm/models/message_event.rbi +86 -0
- data/rbi/sentdm/models/message_event_payload.rbi +132 -0
- data/rbi/sentdm/models/message_retrieve_activities_response.rbi +335 -11
- data/rbi/sentdm/models/message_retrieve_status_response.rbi +148 -8
- data/rbi/sentdm/models/message_send_response.rbi +178 -32
- data/rbi/sentdm/models/number_lookup_response.rbi +135 -8
- data/rbi/sentdm/models/profile_complete_response.rbi +137 -8
- data/rbi/sentdm/models/profile_create_params.rbi +592 -42
- data/rbi/sentdm/models/profile_create_response.rbi +1226 -0
- data/rbi/sentdm/models/profile_delete_params.rbi +19 -2
- data/rbi/sentdm/models/profile_list_response.rbi +1366 -18
- data/rbi/sentdm/models/profile_retrieve_response.rbi +1230 -0
- data/rbi/sentdm/models/profile_update_params.rbi +610 -30
- data/rbi/sentdm/models/profile_update_response.rbi +1226 -0
- data/rbi/sentdm/models/profiles/campaign_create_params.rbi +218 -4
- data/rbi/sentdm/models/profiles/campaign_create_response.rbi +674 -0
- data/rbi/sentdm/models/profiles/campaign_delete_params.rbi +14 -1
- data/rbi/sentdm/models/profiles/campaign_list_response.rbi +667 -0
- data/rbi/sentdm/models/profiles/campaign_update_params.rbi +218 -4
- data/rbi/sentdm/models/profiles/campaign_update_response.rbi +674 -0
- data/rbi/sentdm/models/template_create_response.rbi +349 -0
- data/rbi/sentdm/models/template_event.rbi +84 -0
- data/rbi/sentdm/models/template_event_payload.rbi +131 -0
- data/rbi/sentdm/models/template_list_params.rbi +10 -2
- data/rbi/sentdm/models/template_list_response.rbi +469 -21
- data/rbi/sentdm/models/template_retrieve_response.rbi +355 -0
- data/rbi/sentdm/models/template_update_response.rbi +349 -0
- data/rbi/sentdm/models/user_invite_response.rbi +336 -0
- data/rbi/sentdm/models/user_list_response.rbi +463 -18
- data/rbi/sentdm/models/user_remove_params.rbi +19 -2
- data/rbi/sentdm/models/user_retrieve_response.rbi +336 -0
- data/rbi/sentdm/models/user_update_role_response.rbi +341 -0
- data/rbi/sentdm/models/webhook_create_response.rbi +361 -0
- data/rbi/sentdm/models/webhook_list_event_types_response.rbi +433 -16
- data/rbi/sentdm/models/webhook_list_events_response.rbi +379 -19
- data/rbi/sentdm/models/webhook_list_response.rbi +480 -19
- data/rbi/sentdm/models/webhook_retrieve_response.rbi +363 -0
- data/rbi/sentdm/models/webhook_rotate_secret_params.rbi +14 -1
- data/rbi/sentdm/models/webhook_rotate_secret_response.rbi +148 -8
- data/rbi/sentdm/models/webhook_test_response.rbi +135 -8
- data/rbi/sentdm/models/webhook_toggle_status_response.rbi +379 -0
- data/rbi/sentdm/models/webhook_update_response.rbi +361 -0
- data/rbi/sentdm/models.rbi +11 -53
- data/rbi/sentdm/resources/contacts.rbi +24 -9
- data/rbi/sentdm/resources/conversations.rbi +10 -2
- data/rbi/sentdm/resources/me.rbi +6 -1
- data/rbi/sentdm/resources/messages.rbi +17 -5
- data/rbi/sentdm/resources/numbers.rbi +6 -1
- data/rbi/sentdm/resources/profiles/campaigns.rbi +36 -6
- data/rbi/sentdm/resources/profiles.rbi +177 -68
- data/rbi/sentdm/resources/templates.rbi +15 -5
- data/rbi/sentdm/resources/users.rbi +12 -6
- data/rbi/sentdm/resources/webhooks.rbi +15 -5
- data/sig/sentdm/models/contact_create_response.rbs +216 -0
- data/sig/sentdm/models/contact_delete_params.rbs +10 -6
- data/sig/sentdm/models/contact_list_response.rbs +263 -20
- data/sig/sentdm/models/contact_retrieve_message_summary_response.rbs +182 -0
- data/sig/sentdm/models/contact_retrieve_response.rbs +216 -0
- data/sig/sentdm/models/contact_update_response.rbs +216 -0
- data/sig/sentdm/models/conversation_list_messages_response.rbs +404 -0
- data/sig/sentdm/models/conversation_list_response.rbs +404 -0
- data/sig/sentdm/models/inbound_message_event.rbs +39 -0
- data/sig/sentdm/models/inbound_message_event_payload.rbs +69 -0
- data/sig/sentdm/models/me_retrieve_response.rbs +176 -18
- data/sig/sentdm/models/message_event.rbs +39 -0
- data/sig/sentdm/models/message_event_payload.rbs +72 -0
- data/sig/sentdm/models/message_retrieve_activities_response.rbs +147 -12
- data/sig/sentdm/models/message_retrieve_status_response.rbs +71 -9
- data/sig/sentdm/models/message_send_response.rbs +71 -9
- data/sig/sentdm/models/number_lookup_response.rbs +71 -9
- data/sig/sentdm/models/profile_complete_response.rbs +71 -9
- data/sig/sentdm/models/profile_create_params.rbs +271 -24
- data/sig/sentdm/models/profile_create_response.rbs +559 -0
- data/sig/sentdm/models/profile_delete_params.rbs +10 -6
- data/sig/sentdm/models/profile_list_response.rbs +615 -15
- data/sig/sentdm/models/profile_retrieve_response.rbs +559 -0
- data/sig/sentdm/models/profile_update_params.rbs +263 -12
- data/sig/sentdm/models/profile_update_response.rbs +559 -0
- data/sig/sentdm/models/profiles/campaign_create_params.rbs +108 -4
- data/sig/sentdm/models/profiles/campaign_create_response.rbs +357 -0
- data/sig/sentdm/models/profiles/campaign_delete_params.rbs +15 -8
- data/sig/sentdm/models/profiles/campaign_list_response.rbs +357 -0
- data/sig/sentdm/models/profiles/campaign_update_params.rbs +108 -4
- data/sig/sentdm/models/profiles/campaign_update_response.rbs +357 -0
- data/sig/sentdm/models/template_create_response.rbs +182 -0
- data/sig/sentdm/models/template_event.rbs +39 -0
- data/sig/sentdm/models/template_event_payload.rbs +76 -0
- data/sig/sentdm/models/template_list_response.rbs +230 -19
- data/sig/sentdm/models/template_retrieve_response.rbs +182 -0
- data/sig/sentdm/models/template_update_response.rbs +182 -0
- data/sig/sentdm/models/user_invite_response.rbs +177 -0
- data/sig/sentdm/models/user_list_response.rbs +233 -15
- data/sig/sentdm/models/user_remove_params.rbs +10 -6
- data/sig/sentdm/models/user_retrieve_response.rbs +177 -0
- data/sig/sentdm/models/user_update_role_response.rbs +177 -0
- data/sig/sentdm/models/webhook_create_response.rbs +208 -0
- data/sig/sentdm/models/webhook_list_event_types_response.rbs +203 -15
- data/sig/sentdm/models/webhook_list_events_response.rbs +160 -19
- data/sig/sentdm/models/webhook_list_response.rbs +255 -20
- data/sig/sentdm/models/webhook_retrieve_response.rbs +208 -0
- data/sig/sentdm/models/webhook_rotate_secret_params.rbs +17 -8
- data/sig/sentdm/models/webhook_rotate_secret_response.rbs +71 -9
- data/sig/sentdm/models/webhook_test_response.rbs +71 -9
- data/sig/sentdm/models/webhook_toggle_status_response.rbs +208 -0
- data/sig/sentdm/models/webhook_update_response.rbs +208 -0
- data/sig/sentdm/models.rbs +11 -51
- data/sig/sentdm/resources/contacts.rbs +4 -4
- data/sig/sentdm/resources/conversations.rbs +2 -2
- data/sig/sentdm/resources/profiles/campaigns.rbs +5 -5
- data/sig/sentdm/resources/profiles.rbs +11 -11
- data/sig/sentdm/resources/templates.rbs +3 -3
- data/sig/sentdm/resources/users.rbs +3 -3
- data/sig/sentdm/resources/webhooks.rbs +4 -4
- metadata +86 -98
- data/lib/sentdm/models/api_meta.rb +0 -34
- data/lib/sentdm/models/api_response_of_contact.rb +0 -46
- data/lib/sentdm/models/api_response_of_contact_message_summary.rb +0 -43
- data/lib/sentdm/models/api_response_of_conversation_messages_list.rb +0 -43
- data/lib/sentdm/models/api_response_of_profile_detail.rb +0 -43
- data/lib/sentdm/models/api_response_of_user.rb +0 -43
- data/lib/sentdm/models/api_response_template.rb +0 -43
- data/lib/sentdm/models/api_response_webhook.rb +0 -43
- data/lib/sentdm/models/billing_contact_info.rb +0 -47
- data/lib/sentdm/models/brand_business_info.rb +0 -114
- data/lib/sentdm/models/brand_compliance_info.rb +0 -67
- data/lib/sentdm/models/brand_contact_info.rb +0 -58
- data/lib/sentdm/models/brands_brand_data.rb +0 -34
- data/lib/sentdm/models/contact_message_summary.rb +0 -76
- data/lib/sentdm/models/contact_response.rb +0 -126
- data/lib/sentdm/models/conversation_messages_list.rb +0 -245
- data/lib/sentdm/models/error_detail.rb +0 -42
- data/lib/sentdm/models/mutation_request.rb +0 -20
- data/lib/sentdm/models/pagination_meta.rb +0 -80
- data/lib/sentdm/models/payment_details.rb +0 -44
- data/lib/sentdm/models/profile_detail.rb +0 -597
- data/lib/sentdm/models/profile_settings.rb +0 -66
- data/lib/sentdm/models/profiles/api_response_of_brand_campaign.rb +0 -45
- data/lib/sentdm/models/profiles/api_response_of_list_of_brand_campaign.rb +0 -45
- data/lib/sentdm/models/profiles/brand_campaign.rb +0 -247
- data/lib/sentdm/models/profiles/campaign_data.rb +0 -130
- data/lib/sentdm/models/profiles/campaign_use_case.rb +0 -71
- data/lib/sentdm/models/profiles/campaign_use_case_data.rb +0 -29
- data/lib/sentdm/models/template.rb +0 -90
- data/lib/sentdm/models/user_response.rb +0 -82
- data/lib/sentdm/models/webhook_event_type.rb +0 -45
- data/lib/sentdm/models/webhook_response.rb +0 -95
- data/rbi/sentdm/models/api_meta.rbi +0 -55
- data/rbi/sentdm/models/api_response_of_contact.rbi +0 -74
- data/rbi/sentdm/models/api_response_of_contact_message_summary.rbi +0 -79
- data/rbi/sentdm/models/api_response_of_conversation_messages_list.rbi +0 -79
- data/rbi/sentdm/models/api_response_of_profile_detail.rbi +0 -74
- data/rbi/sentdm/models/api_response_of_user.rbi +0 -74
- data/rbi/sentdm/models/api_response_template.rbi +0 -74
- data/rbi/sentdm/models/api_response_webhook.rbi +0 -74
- data/rbi/sentdm/models/billing_contact_info.rbi +0 -65
- data/rbi/sentdm/models/brand_business_info.rbi +0 -162
- data/rbi/sentdm/models/brand_compliance_info.rbi +0 -84
- data/rbi/sentdm/models/brand_contact_info.rbi +0 -78
- data/rbi/sentdm/models/brands_brand_data.rbi +0 -65
- data/rbi/sentdm/models/contact_message_summary.rbi +0 -144
- data/rbi/sentdm/models/contact_response.rbi +0 -183
- data/rbi/sentdm/models/conversation_messages_list.rbi +0 -419
- data/rbi/sentdm/models/error_detail.rbi +0 -66
- data/rbi/sentdm/models/mutation_request.rbi +0 -32
- data/rbi/sentdm/models/pagination_meta.rbi +0 -135
- data/rbi/sentdm/models/payment_details.rbi +0 -59
- data/rbi/sentdm/models/profile_detail.rbi +0 -866
- data/rbi/sentdm/models/profile_settings.rbi +0 -86
- data/rbi/sentdm/models/profiles/api_response_of_brand_campaign.rbi +0 -81
- data/rbi/sentdm/models/profiles/api_response_of_list_of_brand_campaign.rbi +0 -76
- data/rbi/sentdm/models/profiles/brand_campaign.rbi +0 -299
- data/rbi/sentdm/models/profiles/campaign_data.rbi +0 -146
- data/rbi/sentdm/models/profiles/campaign_use_case.rbi +0 -110
- data/rbi/sentdm/models/profiles/campaign_use_case_data.rbi +0 -51
- data/rbi/sentdm/models/template.rbi +0 -129
- data/rbi/sentdm/models/user_response.rbi +0 -118
- data/rbi/sentdm/models/webhook_event_type.rbi +0 -74
- data/rbi/sentdm/models/webhook_response.rbi +0 -140
- data/sig/sentdm/models/api_meta.rbs +0 -27
- data/sig/sentdm/models/api_response_of_contact.rbs +0 -39
- data/sig/sentdm/models/api_response_of_contact_message_summary.rbs +0 -39
- data/sig/sentdm/models/api_response_of_conversation_messages_list.rbs +0 -39
- data/sig/sentdm/models/api_response_of_profile_detail.rbs +0 -39
- data/sig/sentdm/models/api_response_of_user.rbs +0 -39
- data/sig/sentdm/models/api_response_template.rbs +0 -39
- data/sig/sentdm/models/api_response_webhook.rbs +0 -39
- data/sig/sentdm/models/billing_contact_info.rbs +0 -30
- data/sig/sentdm/models/brand_business_info.rbs +0 -89
- data/sig/sentdm/models/brand_compliance_info.rbs +0 -50
- data/sig/sentdm/models/brand_contact_info.rbs +0 -45
- data/sig/sentdm/models/brands_brand_data.rbs +0 -30
- data/sig/sentdm/models/contact_message_summary.rbs +0 -84
- data/sig/sentdm/models/contact_response.rbs +0 -111
- data/sig/sentdm/models/conversation_messages_list.rbs +0 -240
- data/sig/sentdm/models/error_detail.rbs +0 -39
- data/sig/sentdm/models/mutation_request.rbs +0 -15
- data/sig/sentdm/models/pagination_meta.rbs +0 -67
- data/sig/sentdm/models/payment_details.rbs +0 -30
- data/sig/sentdm/models/profile_detail.rbs +0 -469
- data/sig/sentdm/models/profile_settings.rbs +0 -50
- data/sig/sentdm/models/profiles/api_response_of_brand_campaign.rbs +0 -41
- data/sig/sentdm/models/profiles/api_response_of_list_of_brand_campaign.rbs +0 -41
- data/sig/sentdm/models/profiles/brand_campaign.rbs +0 -194
- data/sig/sentdm/models/profiles/campaign_data.rbs +0 -87
- data/sig/sentdm/models/profiles/campaign_use_case.rbs +0 -66
- data/sig/sentdm/models/profiles/campaign_use_case_data.rbs +0 -27
- data/sig/sentdm/models/template.rbs +0 -79
- data/sig/sentdm/models/user_response.rbs +0 -72
- data/sig/sentdm/models/webhook_event_type.rbs +0 -51
- data/sig/sentdm/models/webhook_response.rbs +0 -103
|
@@ -0,0 +1,420 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sentdm
|
|
4
|
+
module Models
|
|
5
|
+
module Profiles
|
|
6
|
+
# @see Sentdm::Resources::Profiles::Campaigns#update
|
|
7
|
+
class CampaignUpdateResponse < Sentdm::Internal::Type::BaseModel
|
|
8
|
+
# @!attribute data
|
|
9
|
+
# A 10DLC campaign registered for a brand.
|
|
10
|
+
#
|
|
11
|
+
# @return [Sentdm::Models::Profiles::CampaignUpdateResponse::Data, nil]
|
|
12
|
+
optional :data, -> { Sentdm::Models::Profiles::CampaignUpdateResponse::Data }, nil?: true
|
|
13
|
+
|
|
14
|
+
# @!attribute error
|
|
15
|
+
# Error information
|
|
16
|
+
#
|
|
17
|
+
# @return [Sentdm::Models::Profiles::CampaignUpdateResponse::Error, nil]
|
|
18
|
+
optional :error, -> { Sentdm::Models::Profiles::CampaignUpdateResponse::Error }, nil?: true
|
|
19
|
+
|
|
20
|
+
# @!attribute meta
|
|
21
|
+
# Request and response metadata
|
|
22
|
+
#
|
|
23
|
+
# @return [Sentdm::Models::Profiles::CampaignUpdateResponse::Meta, nil]
|
|
24
|
+
optional :meta, -> { Sentdm::Models::Profiles::CampaignUpdateResponse::Meta }
|
|
25
|
+
|
|
26
|
+
# @!attribute success
|
|
27
|
+
# Indicates whether the request was successful
|
|
28
|
+
#
|
|
29
|
+
# @return [Boolean, nil]
|
|
30
|
+
optional :success, Sentdm::Internal::Type::Boolean
|
|
31
|
+
|
|
32
|
+
# @!method initialize(data: nil, error: nil, meta: nil, success: nil)
|
|
33
|
+
# Standard API response envelope for all v3 endpoints
|
|
34
|
+
#
|
|
35
|
+
# @param data [Sentdm::Models::Profiles::CampaignUpdateResponse::Data, nil] A 10DLC campaign registered for a brand.
|
|
36
|
+
#
|
|
37
|
+
# @param error [Sentdm::Models::Profiles::CampaignUpdateResponse::Error, nil] Error information
|
|
38
|
+
#
|
|
39
|
+
# @param meta [Sentdm::Models::Profiles::CampaignUpdateResponse::Meta] Request and response metadata
|
|
40
|
+
#
|
|
41
|
+
# @param success [Boolean] Indicates whether the request was successful
|
|
42
|
+
|
|
43
|
+
# @see Sentdm::Models::Profiles::CampaignUpdateResponse#data
|
|
44
|
+
class Data < Sentdm::Internal::Type::BaseModel
|
|
45
|
+
# @!attribute id
|
|
46
|
+
#
|
|
47
|
+
# @return [String, nil]
|
|
48
|
+
optional :id, String
|
|
49
|
+
|
|
50
|
+
# @!attribute billed_date
|
|
51
|
+
#
|
|
52
|
+
# @return [Time, nil]
|
|
53
|
+
optional :billed_date, Time, api_name: :billedDate, nil?: true
|
|
54
|
+
|
|
55
|
+
# @!attribute brand_id
|
|
56
|
+
#
|
|
57
|
+
# @return [String, nil]
|
|
58
|
+
optional :brand_id, String, api_name: :brandId, nil?: true
|
|
59
|
+
|
|
60
|
+
# @!attribute cost
|
|
61
|
+
#
|
|
62
|
+
# @return [Float, nil]
|
|
63
|
+
optional :cost, Float, nil?: true
|
|
64
|
+
|
|
65
|
+
# @!attribute created_at
|
|
66
|
+
#
|
|
67
|
+
# @return [Time, nil]
|
|
68
|
+
optional :created_at, Time, api_name: :createdAt
|
|
69
|
+
|
|
70
|
+
# @!attribute customer_id
|
|
71
|
+
#
|
|
72
|
+
# @return [String, nil]
|
|
73
|
+
optional :customer_id, String, api_name: :customerId
|
|
74
|
+
|
|
75
|
+
# @!attribute dca_elections_complete
|
|
76
|
+
# True once every carrier has completed its DCA election and the campaign is
|
|
77
|
+
# operationally ready for traffic.
|
|
78
|
+
#
|
|
79
|
+
# @return [Boolean, nil]
|
|
80
|
+
optional :dca_elections_complete,
|
|
81
|
+
Sentdm::Internal::Type::Boolean,
|
|
82
|
+
api_name: :dcaElectionsComplete,
|
|
83
|
+
nil?: true
|
|
84
|
+
|
|
85
|
+
# @!attribute dca_elections_completed_at
|
|
86
|
+
#
|
|
87
|
+
# @return [Time, nil]
|
|
88
|
+
optional :dca_elections_completed_at, Time, api_name: :dcaElectionsCompletedAt, nil?: true
|
|
89
|
+
|
|
90
|
+
# @!attribute description
|
|
91
|
+
#
|
|
92
|
+
# @return [String, nil]
|
|
93
|
+
optional :description, String
|
|
94
|
+
|
|
95
|
+
# @!attribute has_submission_transaction
|
|
96
|
+
# True when the one-time campaign submission fee has already been charged.
|
|
97
|
+
#
|
|
98
|
+
# @return [Boolean, nil]
|
|
99
|
+
optional :has_submission_transaction,
|
|
100
|
+
Sentdm::Internal::Type::Boolean,
|
|
101
|
+
api_name: :hasSubmissionTransaction
|
|
102
|
+
|
|
103
|
+
# @!attribute help_keywords
|
|
104
|
+
#
|
|
105
|
+
# @return [String, nil]
|
|
106
|
+
optional :help_keywords, String, api_name: :helpKeywords, nil?: true
|
|
107
|
+
|
|
108
|
+
# @!attribute help_message
|
|
109
|
+
#
|
|
110
|
+
# @return [String, nil]
|
|
111
|
+
optional :help_message, String, api_name: :helpMessage, nil?: true
|
|
112
|
+
|
|
113
|
+
# @!attribute message_flow
|
|
114
|
+
#
|
|
115
|
+
# @return [String, nil]
|
|
116
|
+
optional :message_flow, String, api_name: :messageFlow, nil?: true
|
|
117
|
+
|
|
118
|
+
# @!attribute name
|
|
119
|
+
#
|
|
120
|
+
# @return [String, nil]
|
|
121
|
+
optional :name, String
|
|
122
|
+
|
|
123
|
+
# @!attribute optin_keywords
|
|
124
|
+
#
|
|
125
|
+
# @return [String, nil]
|
|
126
|
+
optional :optin_keywords, String, api_name: :optinKeywords, nil?: true
|
|
127
|
+
|
|
128
|
+
# @!attribute optin_message
|
|
129
|
+
#
|
|
130
|
+
# @return [String, nil]
|
|
131
|
+
optional :optin_message, String, api_name: :optinMessage, nil?: true
|
|
132
|
+
|
|
133
|
+
# @!attribute optout_keywords
|
|
134
|
+
#
|
|
135
|
+
# @return [String, nil]
|
|
136
|
+
optional :optout_keywords, String, api_name: :optoutKeywords, nil?: true
|
|
137
|
+
|
|
138
|
+
# @!attribute optout_message
|
|
139
|
+
#
|
|
140
|
+
# @return [String, nil]
|
|
141
|
+
optional :optout_message, String, api_name: :optoutMessage, nil?: true
|
|
142
|
+
|
|
143
|
+
# @!attribute privacy_policy_link
|
|
144
|
+
#
|
|
145
|
+
# @return [String, nil]
|
|
146
|
+
optional :privacy_policy_link, String, api_name: :privacyPolicyLink, nil?: true
|
|
147
|
+
|
|
148
|
+
# @!attribute status
|
|
149
|
+
#
|
|
150
|
+
# @return [Symbol, Sentdm::Models::Profiles::CampaignUpdateResponse::Data::Status, nil]
|
|
151
|
+
optional :status, enum: -> { Sentdm::Models::Profiles::CampaignUpdateResponse::Data::Status }, nil?: true
|
|
152
|
+
|
|
153
|
+
# @!attribute submitted_at
|
|
154
|
+
#
|
|
155
|
+
# @return [Time, nil]
|
|
156
|
+
optional :submitted_at, Time, api_name: :submittedAt, nil?: true
|
|
157
|
+
|
|
158
|
+
# @!attribute submitted_to_tcr
|
|
159
|
+
#
|
|
160
|
+
# @return [Boolean, nil]
|
|
161
|
+
optional :submitted_to_tcr, Sentdm::Internal::Type::Boolean, api_name: :submittedToTCR
|
|
162
|
+
|
|
163
|
+
# @!attribute tcr_campaign_id
|
|
164
|
+
# The Campaign Registry identifier, once the campaign has been accepted.
|
|
165
|
+
#
|
|
166
|
+
# @return [String, nil]
|
|
167
|
+
optional :tcr_campaign_id, String, api_name: :tcrCampaignId, nil?: true
|
|
168
|
+
|
|
169
|
+
# @!attribute tcr_sync_error
|
|
170
|
+
# Surfaced so customers can see why a submission did not reach the registry.
|
|
171
|
+
#
|
|
172
|
+
# @return [String, nil]
|
|
173
|
+
optional :tcr_sync_error, String, api_name: :tcrSyncError, nil?: true
|
|
174
|
+
|
|
175
|
+
# @!attribute terms_and_conditions_link
|
|
176
|
+
#
|
|
177
|
+
# @return [String, nil]
|
|
178
|
+
optional :terms_and_conditions_link, String, api_name: :termsAndConditionsLink, nil?: true
|
|
179
|
+
|
|
180
|
+
# @!attribute type
|
|
181
|
+
# Campaign type (for example KYC or App).
|
|
182
|
+
#
|
|
183
|
+
# @return [String, nil]
|
|
184
|
+
optional :type, String
|
|
185
|
+
|
|
186
|
+
# @!attribute updated_at
|
|
187
|
+
#
|
|
188
|
+
# @return [Time, nil]
|
|
189
|
+
optional :updated_at, Time, api_name: :updatedAt, nil?: true
|
|
190
|
+
|
|
191
|
+
# @!attribute use_cases
|
|
192
|
+
#
|
|
193
|
+
# @return [Array<Sentdm::Models::Profiles::CampaignUpdateResponse::Data::UseCase>, nil]
|
|
194
|
+
optional :use_cases,
|
|
195
|
+
-> { Sentdm::Internal::Type::ArrayOf[Sentdm::Models::Profiles::CampaignUpdateResponse::Data::UseCase] },
|
|
196
|
+
api_name: :useCases
|
|
197
|
+
|
|
198
|
+
# @!attribute volume
|
|
199
|
+
# Expected messaging volume for this campaign — customer-supplied on
|
|
200
|
+
# create/update, and the input to both the TCR usecase classification (LOW_VOLUME
|
|
201
|
+
# vs MIXED/specific) and the campaign fee tier. Surfaced so customers can read
|
|
202
|
+
# back the value they set.
|
|
203
|
+
#
|
|
204
|
+
# @return [String, nil]
|
|
205
|
+
optional :volume, String, nil?: true
|
|
206
|
+
|
|
207
|
+
# @!method initialize(id: nil, billed_date: nil, brand_id: nil, cost: nil, created_at: nil, customer_id: nil, dca_elections_complete: nil, dca_elections_completed_at: nil, description: nil, has_submission_transaction: nil, help_keywords: nil, help_message: nil, message_flow: nil, name: nil, optin_keywords: nil, optin_message: nil, optout_keywords: nil, optout_message: nil, privacy_policy_link: nil, status: nil, submitted_at: nil, submitted_to_tcr: nil, tcr_campaign_id: nil, tcr_sync_error: nil, terms_and_conditions_link: nil, type: nil, updated_at: nil, use_cases: nil, volume: nil)
|
|
208
|
+
# Some parameter documentations has been truncated, see
|
|
209
|
+
# {Sentdm::Models::Profiles::CampaignUpdateResponse::Data} for more details.
|
|
210
|
+
#
|
|
211
|
+
# A 10DLC campaign registered for a brand.
|
|
212
|
+
#
|
|
213
|
+
# @param id [String]
|
|
214
|
+
#
|
|
215
|
+
# @param billed_date [Time, nil]
|
|
216
|
+
#
|
|
217
|
+
# @param brand_id [String, nil]
|
|
218
|
+
#
|
|
219
|
+
# @param cost [Float, nil]
|
|
220
|
+
#
|
|
221
|
+
# @param created_at [Time]
|
|
222
|
+
#
|
|
223
|
+
# @param customer_id [String]
|
|
224
|
+
#
|
|
225
|
+
# @param dca_elections_complete [Boolean, nil] True once every carrier has completed its DCA election and the campaign is
|
|
226
|
+
#
|
|
227
|
+
# @param dca_elections_completed_at [Time, nil]
|
|
228
|
+
#
|
|
229
|
+
# @param description [String]
|
|
230
|
+
#
|
|
231
|
+
# @param has_submission_transaction [Boolean] True when the one-time campaign submission fee has already been charged.
|
|
232
|
+
#
|
|
233
|
+
# @param help_keywords [String, nil]
|
|
234
|
+
#
|
|
235
|
+
# @param help_message [String, nil]
|
|
236
|
+
#
|
|
237
|
+
# @param message_flow [String, nil]
|
|
238
|
+
#
|
|
239
|
+
# @param name [String]
|
|
240
|
+
#
|
|
241
|
+
# @param optin_keywords [String, nil]
|
|
242
|
+
#
|
|
243
|
+
# @param optin_message [String, nil]
|
|
244
|
+
#
|
|
245
|
+
# @param optout_keywords [String, nil]
|
|
246
|
+
#
|
|
247
|
+
# @param optout_message [String, nil]
|
|
248
|
+
#
|
|
249
|
+
# @param privacy_policy_link [String, nil]
|
|
250
|
+
#
|
|
251
|
+
# @param status [Symbol, Sentdm::Models::Profiles::CampaignUpdateResponse::Data::Status, nil]
|
|
252
|
+
#
|
|
253
|
+
# @param submitted_at [Time, nil]
|
|
254
|
+
#
|
|
255
|
+
# @param submitted_to_tcr [Boolean]
|
|
256
|
+
#
|
|
257
|
+
# @param tcr_campaign_id [String, nil] The Campaign Registry identifier, once the campaign has been accepted.
|
|
258
|
+
#
|
|
259
|
+
# @param tcr_sync_error [String, nil] Surfaced so customers can see why a submission did not reach the registry.
|
|
260
|
+
#
|
|
261
|
+
# @param terms_and_conditions_link [String, nil]
|
|
262
|
+
#
|
|
263
|
+
# @param type [String] Campaign type (for example KYC or App).
|
|
264
|
+
#
|
|
265
|
+
# @param updated_at [Time, nil]
|
|
266
|
+
#
|
|
267
|
+
# @param use_cases [Array<Sentdm::Models::Profiles::CampaignUpdateResponse::Data::UseCase>]
|
|
268
|
+
#
|
|
269
|
+
# @param volume [String, nil] Expected messaging volume for this campaign — customer-supplied on create/update
|
|
270
|
+
|
|
271
|
+
# @see Sentdm::Models::Profiles::CampaignUpdateResponse::Data#status
|
|
272
|
+
module Status
|
|
273
|
+
extend Sentdm::Internal::Type::Enum
|
|
274
|
+
|
|
275
|
+
SENT_CREATED = :SENT_CREATED
|
|
276
|
+
ACTIVE = :ACTIVE
|
|
277
|
+
EXPIRED = :EXPIRED
|
|
278
|
+
|
|
279
|
+
# @!method self.values
|
|
280
|
+
# @return [Array<Symbol>]
|
|
281
|
+
end
|
|
282
|
+
|
|
283
|
+
class UseCase < Sentdm::Internal::Type::BaseModel
|
|
284
|
+
# @!attribute id
|
|
285
|
+
#
|
|
286
|
+
# @return [String, nil]
|
|
287
|
+
optional :id, String
|
|
288
|
+
|
|
289
|
+
# @!attribute campaign_id
|
|
290
|
+
#
|
|
291
|
+
# @return [String, nil]
|
|
292
|
+
optional :campaign_id, String, api_name: :campaignId
|
|
293
|
+
|
|
294
|
+
# @!attribute created_at
|
|
295
|
+
#
|
|
296
|
+
# @return [Time, nil]
|
|
297
|
+
optional :created_at, Time, api_name: :createdAt
|
|
298
|
+
|
|
299
|
+
# @!attribute customer_id
|
|
300
|
+
#
|
|
301
|
+
# @return [String, nil]
|
|
302
|
+
optional :customer_id, String, api_name: :customerId
|
|
303
|
+
|
|
304
|
+
# @!attribute messaging_use_case_us
|
|
305
|
+
#
|
|
306
|
+
# @return [Symbol, Sentdm::Models::Profiles::MessagingUseCaseUs, nil]
|
|
307
|
+
optional :messaging_use_case_us,
|
|
308
|
+
enum: -> { Sentdm::Profiles::MessagingUseCaseUs },
|
|
309
|
+
api_name: :messagingUseCaseUs
|
|
310
|
+
|
|
311
|
+
# @!attribute sample_messages
|
|
312
|
+
# Sample messages submitted to the registry for this use case.
|
|
313
|
+
#
|
|
314
|
+
# @return [Array<String>, nil]
|
|
315
|
+
optional :sample_messages, Sentdm::Internal::Type::ArrayOf[String], api_name: :sampleMessages
|
|
316
|
+
|
|
317
|
+
# @!attribute updated_at
|
|
318
|
+
#
|
|
319
|
+
# @return [Time, nil]
|
|
320
|
+
optional :updated_at, Time, api_name: :updatedAt, nil?: true
|
|
321
|
+
|
|
322
|
+
# @!method initialize(id: nil, campaign_id: nil, created_at: nil, customer_id: nil, messaging_use_case_us: nil, sample_messages: nil, updated_at: nil)
|
|
323
|
+
# Customer-facing use-case representation for the public v3 campaign contract.
|
|
324
|
+
# Exists for the same reason as BrandCampaignV3Response: nesting the
|
|
325
|
+
# TcrCampaignUseCase database entity in a public response means any column added
|
|
326
|
+
# to that table silently becomes part of the customer-facing contract. This DTO is
|
|
327
|
+
# an explicit allowlist, so a new column stays invisible until it is added here on
|
|
328
|
+
# purpose. This mirrors exactly the fields the entity already serialized, so it
|
|
329
|
+
# removes nothing from the current response shape. It only closes the future-leak
|
|
330
|
+
# path.
|
|
331
|
+
#
|
|
332
|
+
# @param id [String]
|
|
333
|
+
#
|
|
334
|
+
# @param campaign_id [String]
|
|
335
|
+
#
|
|
336
|
+
# @param created_at [Time]
|
|
337
|
+
#
|
|
338
|
+
# @param customer_id [String]
|
|
339
|
+
#
|
|
340
|
+
# @param messaging_use_case_us [Symbol, Sentdm::Models::Profiles::MessagingUseCaseUs]
|
|
341
|
+
#
|
|
342
|
+
# @param sample_messages [Array<String>] Sample messages submitted to the registry for this use case.
|
|
343
|
+
#
|
|
344
|
+
# @param updated_at [Time, nil]
|
|
345
|
+
end
|
|
346
|
+
end
|
|
347
|
+
|
|
348
|
+
# @see Sentdm::Models::Profiles::CampaignUpdateResponse#error
|
|
349
|
+
class Error < Sentdm::Internal::Type::BaseModel
|
|
350
|
+
# @!attribute code
|
|
351
|
+
# Machine-readable error code (e.g., "RESOURCE_001")
|
|
352
|
+
#
|
|
353
|
+
# @return [String, nil]
|
|
354
|
+
optional :code, String
|
|
355
|
+
|
|
356
|
+
# @!attribute details
|
|
357
|
+
# Additional validation error details (field-level errors)
|
|
358
|
+
#
|
|
359
|
+
# @return [Hash{Symbol=>Array<String>}, nil]
|
|
360
|
+
optional :details,
|
|
361
|
+
Sentdm::Internal::Type::HashOf[Sentdm::Internal::Type::ArrayOf[String]],
|
|
362
|
+
nil?: true
|
|
363
|
+
|
|
364
|
+
# @!attribute doc_url
|
|
365
|
+
# URL to documentation about this error
|
|
366
|
+
#
|
|
367
|
+
# @return [String, nil]
|
|
368
|
+
optional :doc_url, String, nil?: true
|
|
369
|
+
|
|
370
|
+
# @!attribute message
|
|
371
|
+
# Human-readable error message
|
|
372
|
+
#
|
|
373
|
+
# @return [String, nil]
|
|
374
|
+
optional :message, String
|
|
375
|
+
|
|
376
|
+
# @!method initialize(code: nil, details: nil, doc_url: nil, message: nil)
|
|
377
|
+
# Error information
|
|
378
|
+
#
|
|
379
|
+
# @param code [String] Machine-readable error code (e.g., "RESOURCE_001")
|
|
380
|
+
#
|
|
381
|
+
# @param details [Hash{Symbol=>Array<String>}, nil] Additional validation error details (field-level errors)
|
|
382
|
+
#
|
|
383
|
+
# @param doc_url [String, nil] URL to documentation about this error
|
|
384
|
+
#
|
|
385
|
+
# @param message [String] Human-readable error message
|
|
386
|
+
end
|
|
387
|
+
|
|
388
|
+
# @see Sentdm::Models::Profiles::CampaignUpdateResponse#meta
|
|
389
|
+
class Meta < Sentdm::Internal::Type::BaseModel
|
|
390
|
+
# @!attribute request_id
|
|
391
|
+
# Unique identifier for this request (for tracing and support)
|
|
392
|
+
#
|
|
393
|
+
# @return [String, nil]
|
|
394
|
+
optional :request_id, String
|
|
395
|
+
|
|
396
|
+
# @!attribute timestamp
|
|
397
|
+
# Server timestamp when the response was generated
|
|
398
|
+
#
|
|
399
|
+
# @return [Time, nil]
|
|
400
|
+
optional :timestamp, Time
|
|
401
|
+
|
|
402
|
+
# @!attribute version
|
|
403
|
+
# API version used for this request
|
|
404
|
+
#
|
|
405
|
+
# @return [String, nil]
|
|
406
|
+
optional :version, String
|
|
407
|
+
|
|
408
|
+
# @!method initialize(request_id: nil, timestamp: nil, version: nil)
|
|
409
|
+
# Request and response metadata
|
|
410
|
+
#
|
|
411
|
+
# @param request_id [String] Unique identifier for this request (for tracing and support)
|
|
412
|
+
#
|
|
413
|
+
# @param timestamp [Time] Server timestamp when the response was generated
|
|
414
|
+
#
|
|
415
|
+
# @param version [String] API version used for this request
|
|
416
|
+
end
|
|
417
|
+
end
|
|
418
|
+
end
|
|
419
|
+
end
|
|
420
|
+
end
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sentdm
|
|
4
|
+
module Models
|
|
5
|
+
# @see Sentdm::Resources::Templates#create
|
|
6
|
+
class TemplateCreateResponse < Sentdm::Internal::Type::BaseModel
|
|
7
|
+
# @!attribute data
|
|
8
|
+
# Template response for v3 API
|
|
9
|
+
#
|
|
10
|
+
# @return [Sentdm::Models::TemplateCreateResponse::Data, nil]
|
|
11
|
+
optional :data, -> { Sentdm::Models::TemplateCreateResponse::Data }, nil?: true
|
|
12
|
+
|
|
13
|
+
# @!attribute error
|
|
14
|
+
# Error information
|
|
15
|
+
#
|
|
16
|
+
# @return [Sentdm::Models::TemplateCreateResponse::Error, nil]
|
|
17
|
+
optional :error, -> { Sentdm::Models::TemplateCreateResponse::Error }, nil?: true
|
|
18
|
+
|
|
19
|
+
# @!attribute meta
|
|
20
|
+
# Request and response metadata
|
|
21
|
+
#
|
|
22
|
+
# @return [Sentdm::Models::TemplateCreateResponse::Meta, nil]
|
|
23
|
+
optional :meta, -> { Sentdm::Models::TemplateCreateResponse::Meta }
|
|
24
|
+
|
|
25
|
+
# @!attribute success
|
|
26
|
+
# Indicates whether the request was successful
|
|
27
|
+
#
|
|
28
|
+
# @return [Boolean, nil]
|
|
29
|
+
optional :success, Sentdm::Internal::Type::Boolean
|
|
30
|
+
|
|
31
|
+
# @!method initialize(data: nil, error: nil, meta: nil, success: nil)
|
|
32
|
+
# Standard API response envelope for all v3 endpoints
|
|
33
|
+
#
|
|
34
|
+
# @param data [Sentdm::Models::TemplateCreateResponse::Data, nil] Template response for v3 API
|
|
35
|
+
#
|
|
36
|
+
# @param error [Sentdm::Models::TemplateCreateResponse::Error, nil] Error information
|
|
37
|
+
#
|
|
38
|
+
# @param meta [Sentdm::Models::TemplateCreateResponse::Meta] Request and response metadata
|
|
39
|
+
#
|
|
40
|
+
# @param success [Boolean] Indicates whether the request was successful
|
|
41
|
+
|
|
42
|
+
# @see Sentdm::Models::TemplateCreateResponse#data
|
|
43
|
+
class Data < Sentdm::Internal::Type::BaseModel
|
|
44
|
+
# @!attribute customer_id
|
|
45
|
+
# Which customer owns this — the key's own, or the profile named in x-profile-id.
|
|
46
|
+
# Says whose resource this is, which the resource's own id does not.
|
|
47
|
+
#
|
|
48
|
+
# @return [String]
|
|
49
|
+
required :customer_id, String
|
|
50
|
+
|
|
51
|
+
# @!attribute id
|
|
52
|
+
# Unique template identifier
|
|
53
|
+
#
|
|
54
|
+
# @return [String, nil]
|
|
55
|
+
optional :id, String
|
|
56
|
+
|
|
57
|
+
# @!attribute category
|
|
58
|
+
# Template category: MARKETING, UTILITY, AUTHENTICATION
|
|
59
|
+
#
|
|
60
|
+
# @return [String, nil]
|
|
61
|
+
optional :category, String
|
|
62
|
+
|
|
63
|
+
# @!attribute channels
|
|
64
|
+
# Supported channels: sms, whatsapp
|
|
65
|
+
#
|
|
66
|
+
# @return [Array<String>, nil]
|
|
67
|
+
optional :channels, Sentdm::Internal::Type::ArrayOf[String], nil?: true
|
|
68
|
+
|
|
69
|
+
# @!attribute created_at
|
|
70
|
+
# When the template was created
|
|
71
|
+
#
|
|
72
|
+
# @return [Time, nil]
|
|
73
|
+
optional :created_at, Time
|
|
74
|
+
|
|
75
|
+
# @!attribute is_published
|
|
76
|
+
# Whether the template is published and active
|
|
77
|
+
#
|
|
78
|
+
# @return [Boolean, nil]
|
|
79
|
+
optional :is_published, Sentdm::Internal::Type::Boolean
|
|
80
|
+
|
|
81
|
+
# @!attribute language
|
|
82
|
+
# Template language code (e.g., en_US)
|
|
83
|
+
#
|
|
84
|
+
# @return [String, nil]
|
|
85
|
+
optional :language, String
|
|
86
|
+
|
|
87
|
+
# @!attribute name
|
|
88
|
+
# Template display name
|
|
89
|
+
#
|
|
90
|
+
# @return [String, nil]
|
|
91
|
+
optional :name, String
|
|
92
|
+
|
|
93
|
+
# @!attribute status
|
|
94
|
+
# Template status: APPROVED, PENDING, REJECTED
|
|
95
|
+
#
|
|
96
|
+
# @return [String, nil]
|
|
97
|
+
optional :status, String
|
|
98
|
+
|
|
99
|
+
# @!attribute updated_at
|
|
100
|
+
# When the template was last updated
|
|
101
|
+
#
|
|
102
|
+
# @return [Time, nil]
|
|
103
|
+
optional :updated_at, Time, nil?: true
|
|
104
|
+
|
|
105
|
+
# @!attribute variables
|
|
106
|
+
# Template variables for personalization
|
|
107
|
+
#
|
|
108
|
+
# @return [Array<String>, nil]
|
|
109
|
+
optional :variables, Sentdm::Internal::Type::ArrayOf[String], nil?: true
|
|
110
|
+
|
|
111
|
+
# @!method initialize(customer_id:, id: nil, category: nil, channels: nil, created_at: nil, is_published: nil, language: nil, name: nil, status: nil, updated_at: nil, variables: nil)
|
|
112
|
+
# Some parameter documentations has been truncated, see
|
|
113
|
+
# {Sentdm::Models::TemplateCreateResponse::Data} for more details.
|
|
114
|
+
#
|
|
115
|
+
# Template response for v3 API
|
|
116
|
+
#
|
|
117
|
+
# @param customer_id [String] Which customer owns this — the key's own, or the profile named in x-profile-id.
|
|
118
|
+
#
|
|
119
|
+
# @param id [String] Unique template identifier
|
|
120
|
+
#
|
|
121
|
+
# @param category [String] Template category: MARKETING, UTILITY, AUTHENTICATION
|
|
122
|
+
#
|
|
123
|
+
# @param channels [Array<String>, nil] Supported channels: sms, whatsapp
|
|
124
|
+
#
|
|
125
|
+
# @param created_at [Time] When the template was created
|
|
126
|
+
#
|
|
127
|
+
# @param is_published [Boolean] Whether the template is published and active
|
|
128
|
+
#
|
|
129
|
+
# @param language [String] Template language code (e.g., en_US)
|
|
130
|
+
#
|
|
131
|
+
# @param name [String] Template display name
|
|
132
|
+
#
|
|
133
|
+
# @param status [String] Template status: APPROVED, PENDING, REJECTED
|
|
134
|
+
#
|
|
135
|
+
# @param updated_at [Time, nil] When the template was last updated
|
|
136
|
+
#
|
|
137
|
+
# @param variables [Array<String>, nil] Template variables for personalization
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
# @see Sentdm::Models::TemplateCreateResponse#error
|
|
141
|
+
class Error < Sentdm::Internal::Type::BaseModel
|
|
142
|
+
# @!attribute code
|
|
143
|
+
# Machine-readable error code (e.g., "RESOURCE_001")
|
|
144
|
+
#
|
|
145
|
+
# @return [String, nil]
|
|
146
|
+
optional :code, String
|
|
147
|
+
|
|
148
|
+
# @!attribute details
|
|
149
|
+
# Additional validation error details (field-level errors)
|
|
150
|
+
#
|
|
151
|
+
# @return [Hash{Symbol=>Array<String>}, nil]
|
|
152
|
+
optional :details, Sentdm::Internal::Type::HashOf[Sentdm::Internal::Type::ArrayOf[String]], nil?: true
|
|
153
|
+
|
|
154
|
+
# @!attribute doc_url
|
|
155
|
+
# URL to documentation about this error
|
|
156
|
+
#
|
|
157
|
+
# @return [String, nil]
|
|
158
|
+
optional :doc_url, String, nil?: true
|
|
159
|
+
|
|
160
|
+
# @!attribute message
|
|
161
|
+
# Human-readable error message
|
|
162
|
+
#
|
|
163
|
+
# @return [String, nil]
|
|
164
|
+
optional :message, String
|
|
165
|
+
|
|
166
|
+
# @!method initialize(code: nil, details: nil, doc_url: nil, message: nil)
|
|
167
|
+
# Error information
|
|
168
|
+
#
|
|
169
|
+
# @param code [String] Machine-readable error code (e.g., "RESOURCE_001")
|
|
170
|
+
#
|
|
171
|
+
# @param details [Hash{Symbol=>Array<String>}, nil] Additional validation error details (field-level errors)
|
|
172
|
+
#
|
|
173
|
+
# @param doc_url [String, nil] URL to documentation about this error
|
|
174
|
+
#
|
|
175
|
+
# @param message [String] Human-readable error message
|
|
176
|
+
end
|
|
177
|
+
|
|
178
|
+
# @see Sentdm::Models::TemplateCreateResponse#meta
|
|
179
|
+
class Meta < Sentdm::Internal::Type::BaseModel
|
|
180
|
+
# @!attribute request_id
|
|
181
|
+
# Unique identifier for this request (for tracing and support)
|
|
182
|
+
#
|
|
183
|
+
# @return [String, nil]
|
|
184
|
+
optional :request_id, String
|
|
185
|
+
|
|
186
|
+
# @!attribute timestamp
|
|
187
|
+
# Server timestamp when the response was generated
|
|
188
|
+
#
|
|
189
|
+
# @return [Time, nil]
|
|
190
|
+
optional :timestamp, Time
|
|
191
|
+
|
|
192
|
+
# @!attribute version
|
|
193
|
+
# API version used for this request
|
|
194
|
+
#
|
|
195
|
+
# @return [String, nil]
|
|
196
|
+
optional :version, String
|
|
197
|
+
|
|
198
|
+
# @!method initialize(request_id: nil, timestamp: nil, version: nil)
|
|
199
|
+
# Request and response metadata
|
|
200
|
+
#
|
|
201
|
+
# @param request_id [String] Unique identifier for this request (for tracing and support)
|
|
202
|
+
#
|
|
203
|
+
# @param timestamp [Time] Server timestamp when the response was generated
|
|
204
|
+
#
|
|
205
|
+
# @param version [String] API version used for this request
|
|
206
|
+
end
|
|
207
|
+
end
|
|
208
|
+
end
|
|
209
|
+
end
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sentdm
|
|
4
|
+
module Models
|
|
5
|
+
class TemplateEvent < Sentdm::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute event
|
|
7
|
+
# The specific event within the family, for example message.delivered or
|
|
8
|
+
# message.received. Absent on events that have no subtype, so treat it as
|
|
9
|
+
# optional.
|
|
10
|
+
#
|
|
11
|
+
# @return [String, nil]
|
|
12
|
+
optional :event, String, nil?: true
|
|
13
|
+
|
|
14
|
+
# @!attribute field
|
|
15
|
+
# The event family, for example message or templates. Route on this first, then on
|
|
16
|
+
# event for the specific change.
|
|
17
|
+
#
|
|
18
|
+
# @return [String, nil]
|
|
19
|
+
optional :field, String
|
|
20
|
+
|
|
21
|
+
# @!attribute payload
|
|
22
|
+
# Body of a template status event. Delivered when a template's review outcome
|
|
23
|
+
# changes, so you can react without polling.
|
|
24
|
+
#
|
|
25
|
+
# @return [Sentdm::Models::TemplateEventPayload, nil]
|
|
26
|
+
optional :payload, -> { Sentdm::TemplateEventPayload }, nil?: true
|
|
27
|
+
|
|
28
|
+
# @!attribute timestamp
|
|
29
|
+
# When Sent emitted the event, in UTC (yyyy-MM-ddTHH:mm:ssZ). This is the emission
|
|
30
|
+
# time, not the time the underlying change happened. Use the timestamp inside the
|
|
31
|
+
# payload for the latter.
|
|
32
|
+
#
|
|
33
|
+
# @return [String, nil]
|
|
34
|
+
optional :timestamp, String
|
|
35
|
+
|
|
36
|
+
# @!method initialize(event: nil, field: nil, payload: nil, timestamp: nil)
|
|
37
|
+
# Some parameter documentations has been truncated, see
|
|
38
|
+
# {Sentdm::Models::TemplateEvent} for more details.
|
|
39
|
+
#
|
|
40
|
+
# The envelope Sent POSTs to a subscribed webhook endpoint. Every event shares
|
|
41
|
+
# this shape and varies only in Payload.
|
|
42
|
+
#
|
|
43
|
+
# @param event [String, nil] The specific event within the family, for example message.delivered or
|
|
44
|
+
#
|
|
45
|
+
# @param field [String] The event family, for example message or templates. Route on this first, then
|
|
46
|
+
#
|
|
47
|
+
# @param payload [Sentdm::Models::TemplateEventPayload, nil] Body of a template status event. Delivered when a template's review outcome chan
|
|
48
|
+
#
|
|
49
|
+
# @param timestamp [String] When Sent emitted the event, in UTC (yyyy-MM-ddTHH:mm:ssZ). This is the emission
|
|
50
|
+
end
|
|
51
|
+
end
|
|
52
|
+
end
|