sentdm 0.3.1 → 0.5.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 +16 -0
- data/README.md +1 -27
- data/lib/sentdm/client.rb +5 -9
- data/lib/sentdm/internal/type/base_model.rb +5 -5
- data/lib/sentdm/models/api_meta.rb +1 -9
- data/lib/sentdm/models/{api_response_contact.rb → api_response_of_contact.rb} +4 -4
- data/lib/sentdm/models/base_dto.rb +30 -0
- data/lib/sentdm/models/billing_contact_info.rb +47 -0
- data/lib/sentdm/models/brands_brand_data.rb +274 -0
- data/lib/sentdm/models/contact_create_params.rb +13 -6
- data/lib/sentdm/models/contact_delete_params.rb +9 -2
- data/lib/sentdm/models/contact_list_params.rb +10 -2
- data/lib/sentdm/models/contact_list_response.rb +3 -3
- data/lib/sentdm/models/{contact.rb → contact_response.rb} +1 -1
- data/lib/sentdm/models/contact_retrieve_params.rb +7 -1
- data/lib/sentdm/models/contact_update_params.rb +13 -6
- data/lib/sentdm/models/me_retrieve_params.rb +7 -1
- data/lib/sentdm/models/me_retrieve_response.rb +152 -7
- data/lib/sentdm/models/message_retrieve_activities_params.rb +7 -1
- data/lib/sentdm/models/message_retrieve_activities_response.rb +19 -5
- data/lib/sentdm/models/message_retrieve_status_params.rb +7 -1
- data/lib/sentdm/models/message_retrieve_status_response.rb +8 -1
- data/lib/sentdm/models/message_send_params.rb +17 -10
- data/lib/sentdm/models/mutation_request_base.rb +20 -0
- data/lib/sentdm/models/{lookup_retrieve_phone_info_params.rb → number_lookup_params.rb} +9 -3
- data/lib/sentdm/models/{lookup_retrieve_phone_info_response.rb → number_lookup_response.rb} +21 -21
- data/lib/sentdm/models/payment_details.rb +44 -0
- data/lib/sentdm/models/{profile_complete_params.rb → profile_complete_setup_params.rb} +16 -9
- data/lib/sentdm/models/{profile_complete_response.rb → profile_complete_setup_response.rb} +1 -1
- data/lib/sentdm/models/profile_create_params.rb +111 -11
- data/lib/sentdm/models/profile_delete_params.rb +18 -18
- data/lib/sentdm/models/profile_detail.rb +483 -68
- data/lib/sentdm/models/profile_list_params.rb +7 -1
- data/lib/sentdm/models/profile_retrieve_params.rb +7 -1
- data/lib/sentdm/models/profile_update_params.rb +60 -22
- data/lib/sentdm/models/{brands/api_response_tcr_campaign_with_use_cases.rb → profiles/api_response_of_tcr_campaign_with_use_cases.rb} +6 -6
- data/lib/sentdm/models/profiles/campaign_create_params.rb +57 -0
- data/lib/sentdm/models/{brands → profiles}/campaign_data.rb +28 -7
- data/lib/sentdm/models/profiles/campaign_delete_params.rb +50 -0
- data/lib/sentdm/models/profiles/campaign_list_params.rb +28 -0
- data/lib/sentdm/models/{brands → profiles}/campaign_list_response.rb +5 -5
- data/lib/sentdm/models/profiles/campaign_update_params.rb +64 -0
- data/lib/sentdm/models/{brands → profiles}/messaging_use_case_us.rb +1 -1
- data/lib/sentdm/models/{brands → profiles}/tcr_campaign_with_use_cases.rb +15 -15
- data/lib/sentdm/models/template_create_params.rb +17 -10
- data/lib/sentdm/models/template_definition.rb +255 -15
- data/lib/sentdm/models/template_delete_params.rb +13 -6
- data/lib/sentdm/models/template_list_params.rb +18 -2
- data/lib/sentdm/models/template_retrieve_params.rb +7 -1
- data/lib/sentdm/models/template_update_params.rb +17 -10
- data/lib/sentdm/models/template_variable.rb +7 -1
- data/lib/sentdm/models/user_invite_params.rb +13 -6
- data/lib/sentdm/models/user_list_params.rb +7 -1
- data/lib/sentdm/models/user_remove_params.rb +17 -17
- data/lib/sentdm/models/user_retrieve_params.rb +7 -1
- data/lib/sentdm/models/user_update_role_params.rb +15 -16
- data/lib/sentdm/models/webhook_create_params.rb +13 -6
- data/lib/sentdm/models/webhook_delete_params.rb +7 -1
- data/lib/sentdm/models/webhook_list_event_types_params.rb +7 -1
- data/lib/sentdm/models/webhook_list_events_params.rb +7 -1
- data/lib/sentdm/models/webhook_list_params.rb +7 -1
- data/lib/sentdm/models/webhook_retrieve_params.rb +7 -1
- data/lib/sentdm/models/webhook_rotate_secret_params.rb +8 -2
- data/lib/sentdm/models/webhook_test_params.rb +13 -6
- data/lib/sentdm/models/webhook_toggle_status_params.rb +13 -6
- data/lib/sentdm/models/webhook_update_params.rb +13 -6
- data/lib/sentdm/models.rb +14 -38
- data/lib/sentdm/resources/contacts.rb +49 -26
- data/lib/sentdm/resources/me.rb +24 -5
- data/lib/sentdm/resources/messages.rb +24 -8
- data/lib/sentdm/resources/numbers.rb +44 -0
- data/lib/sentdm/resources/profiles/campaigns.rb +160 -0
- data/lib/sentdm/resources/profiles.rb +125 -36
- data/lib/sentdm/resources/templates.rb +47 -24
- data/lib/sentdm/resources/users.rb +40 -23
- data/lib/sentdm/resources/webhooks.rb +92 -34
- data/lib/sentdm/version.rb +1 -1
- data/lib/sentdm.rb +22 -35
- data/rbi/sentdm/client.rbi +4 -7
- data/rbi/sentdm/models/api_meta.rbi +4 -18
- data/rbi/sentdm/models/{api_response_brand_with_kyc.rbi → api_response_of_contact.rbi} +6 -6
- data/rbi/sentdm/models/base_dto.rbi +49 -0
- data/rbi/sentdm/models/billing_contact_info.rbi +65 -0
- data/rbi/sentdm/models/brands_brand_data.rbi +406 -0
- data/rbi/sentdm/models/contact_create_params.rbi +19 -10
- data/rbi/sentdm/models/contact_delete_params.rbi +10 -1
- data/rbi/sentdm/models/contact_list_params.rbi +11 -0
- data/rbi/sentdm/models/contact_list_response.rbi +4 -4
- data/rbi/sentdm/models/{contact.rbi → contact_response.rbi} +4 -2
- data/rbi/sentdm/models/contact_retrieve_params.rbi +13 -2
- data/rbi/sentdm/models/contact_update_params.rbi +19 -10
- data/rbi/sentdm/models/me_retrieve_params.rbi +16 -5
- data/rbi/sentdm/models/me_retrieve_response.rbi +316 -16
- data/rbi/sentdm/models/message_retrieve_activities_params.rbi +13 -2
- data/rbi/sentdm/models/message_retrieve_activities_response.rbi +18 -6
- data/rbi/sentdm/models/message_retrieve_status_params.rbi +13 -2
- data/rbi/sentdm/models/message_retrieve_status_response.rbi +6 -0
- data/rbi/sentdm/models/message_send_params.rbi +22 -13
- data/rbi/sentdm/models/mutation_request_base.rbi +32 -0
- data/rbi/sentdm/models/{lookup_retrieve_phone_info_params.rbi → number_lookup_params.rbi} +15 -7
- data/rbi/sentdm/models/{lookup_retrieve_phone_info_response.rbi → number_lookup_response.rbi} +16 -33
- data/rbi/sentdm/models/payment_details.rbi +59 -0
- data/rbi/sentdm/models/{profile_complete_params.rbi → profile_complete_setup_params.rbi} +21 -12
- data/rbi/sentdm/models/{profile_complete_response.rbi → profile_complete_setup_response.rbi} +1 -1
- data/rbi/sentdm/models/profile_create_params.rbi +189 -15
- data/rbi/sentdm/models/profile_delete_params.rbi +36 -24
- data/rbi/sentdm/models/profile_detail.rbi +725 -111
- data/rbi/sentdm/models/profile_list_params.rbi +16 -5
- data/rbi/sentdm/models/profile_retrieve_params.rbi +13 -2
- data/rbi/sentdm/models/profile_update_params.rbi +97 -30
- data/rbi/sentdm/models/{brands/api_response_tcr_campaign_with_use_cases.rbi → profiles/api_response_of_tcr_campaign_with_use_cases.rbi} +7 -7
- data/rbi/sentdm/models/{brands → profiles}/campaign_create_params.rbi +29 -20
- data/rbi/sentdm/models/{brands → profiles}/campaign_data.rbi +51 -16
- data/rbi/sentdm/models/{brands → profiles}/campaign_delete_params.rbi +23 -12
- data/rbi/sentdm/models/profiles/campaign_list_params.rbi +51 -0
- data/rbi/sentdm/models/{brands → profiles}/campaign_list_response.rbi +7 -5
- data/rbi/sentdm/models/{brands → profiles}/campaign_update_params.rbi +29 -20
- data/rbi/sentdm/models/{brands → profiles}/messaging_use_case_us.rbi +20 -16
- data/rbi/sentdm/models/{brands → profiles}/tcr_campaign_with_use_cases.rbi +35 -29
- data/rbi/sentdm/models/template_create_params.rbi +22 -13
- data/rbi/sentdm/models/template_definition.rbi +405 -74
- data/rbi/sentdm/models/template_delete_params.rbi +19 -10
- data/rbi/sentdm/models/template_list_params.rbi +19 -0
- data/rbi/sentdm/models/template_retrieve_params.rbi +13 -2
- data/rbi/sentdm/models/template_update_params.rbi +22 -13
- data/rbi/sentdm/models/template_variable.rbi +6 -0
- data/rbi/sentdm/models/user_invite_params.rbi +19 -10
- data/rbi/sentdm/models/user_list_params.rbi +16 -5
- data/rbi/sentdm/models/user_remove_params.rbi +35 -23
- data/rbi/sentdm/models/user_retrieve_params.rbi +13 -2
- data/rbi/sentdm/models/user_update_role_params.rbi +23 -25
- data/rbi/sentdm/models/webhook_create_params.rbi +19 -10
- data/rbi/sentdm/models/webhook_delete_params.rbi +13 -2
- data/rbi/sentdm/models/webhook_list_event_types_params.rbi +16 -5
- data/rbi/sentdm/models/webhook_list_events_params.rbi +16 -1
- data/rbi/sentdm/models/webhook_list_params.rbi +9 -0
- data/rbi/sentdm/models/webhook_retrieve_params.rbi +13 -2
- data/rbi/sentdm/models/webhook_rotate_secret_params.rbi +16 -2
- data/rbi/sentdm/models/webhook_test_params.rbi +19 -10
- data/rbi/sentdm/models/webhook_toggle_status_params.rbi +19 -10
- data/rbi/sentdm/models/webhook_update_params.rbi +19 -10
- data/rbi/sentdm/models.rbi +14 -38
- data/rbi/sentdm/resources/contacts.rbi +40 -15
- data/rbi/sentdm/resources/me.rbi +25 -7
- data/rbi/sentdm/resources/messages.rbi +17 -4
- data/rbi/sentdm/resources/numbers.rbi +32 -0
- data/rbi/sentdm/resources/profiles/campaigns.rbi +127 -0
- data/rbi/sentdm/resources/profiles.rbi +179 -39
- data/rbi/sentdm/resources/templates.rbi +47 -19
- data/rbi/sentdm/resources/users.rbi +47 -25
- data/rbi/sentdm/resources/webhooks.rbi +92 -20
- data/sig/sentdm/client.rbs +2 -4
- data/sig/sentdm/models/api_meta.rbs +2 -16
- data/sig/sentdm/models/{api_response_contact.rbs → api_response_of_contact.rbs} +6 -6
- data/sig/sentdm/models/base_dto.rbs +25 -0
- data/sig/sentdm/models/billing_contact_info.rbs +30 -0
- data/sig/sentdm/models/brands_brand_data.rbs +210 -0
- data/sig/sentdm/models/contact_create_params.rbs +16 -5
- data/sig/sentdm/models/contact_delete_params.rbs +12 -2
- data/sig/sentdm/models/contact_list_params.rbs +8 -1
- data/sig/sentdm/models/contact_list_response.rbs +7 -5
- data/sig/sentdm/models/{contact.rbs → contact_response.rbs} +2 -2
- data/sig/sentdm/models/contact_retrieve_params.rbs +12 -2
- data/sig/sentdm/models/contact_update_params.rbs +13 -6
- data/sig/sentdm/models/me_retrieve_params.rbs +14 -3
- data/sig/sentdm/models/me_retrieve_response.rbs +134 -7
- data/sig/sentdm/models/message_retrieve_activities_params.rbs +12 -2
- data/sig/sentdm/models/message_retrieve_activities_response.rbs +9 -4
- data/sig/sentdm/models/message_retrieve_status_params.rbs +12 -2
- data/sig/sentdm/models/message_retrieve_status_response.rbs +5 -0
- data/sig/sentdm/models/message_send_params.rbs +15 -8
- data/sig/sentdm/models/mutation_request_base.rbs +15 -0
- data/sig/sentdm/models/{lookup_retrieve_phone_info_params.rbs → number_lookup_params.rbs} +10 -3
- data/sig/sentdm/models/{lookup_retrieve_phone_info_response.rbs → number_lookup_response.rbs} +14 -16
- data/sig/sentdm/models/payment_details.rbs +30 -0
- data/sig/sentdm/models/{profile_complete_params.rbs → profile_complete_setup_params.rbs} +15 -8
- data/sig/sentdm/models/profile_complete_setup_response.rbs +5 -0
- data/sig/sentdm/models/profile_create_params.rbs +57 -7
- data/sig/sentdm/models/profile_delete_params.rbs +23 -13
- data/sig/sentdm/models/profile_detail.rbs +374 -68
- data/sig/sentdm/models/profile_list_params.rbs +14 -3
- data/sig/sentdm/models/profile_retrieve_params.rbs +8 -1
- data/sig/sentdm/models/profile_update_params.rbs +32 -17
- data/sig/sentdm/models/{brands/api_response_tcr_campaign_with_use_cases.rbs → profiles/api_response_of_tcr_campaign_with_use_cases.rbs} +7 -7
- data/sig/sentdm/models/profiles/campaign_create_params.rbs +54 -0
- data/sig/sentdm/models/{brands → profiles}/campaign_data.rbs +27 -5
- data/sig/sentdm/models/{brands → profiles}/campaign_delete_params.rbs +17 -10
- data/sig/sentdm/models/{brands → profiles}/campaign_list_params.rbs +12 -5
- data/sig/sentdm/models/{brands → profiles}/campaign_list_response.rbs +5 -5
- data/sig/sentdm/models/{brands → profiles}/campaign_update_params.rbs +22 -15
- data/sig/sentdm/models/{brands → profiles}/messaging_use_case_us.rbs +2 -2
- data/sig/sentdm/models/{brands → profiles}/tcr_campaign_with_use_cases.rbs +29 -29
- data/sig/sentdm/models/template_create_params.rbs +15 -8
- data/sig/sentdm/models/template_definition.rbs +233 -20
- data/sig/sentdm/models/template_delete_params.rbs +16 -5
- data/sig/sentdm/models/template_list_params.rbs +13 -1
- data/sig/sentdm/models/template_retrieve_params.rbs +12 -2
- data/sig/sentdm/models/template_update_params.rbs +15 -8
- data/sig/sentdm/models/template_variable.rbs +5 -0
- data/sig/sentdm/models/user_invite_params.rbs +13 -6
- data/sig/sentdm/models/user_list_params.rbs +14 -3
- data/sig/sentdm/models/user_remove_params.rbs +23 -13
- data/sig/sentdm/models/user_retrieve_params.rbs +8 -1
- data/sig/sentdm/models/user_update_role_params.rbs +17 -17
- data/sig/sentdm/models/webhook_create_params.rbs +13 -6
- data/sig/sentdm/models/webhook_delete_params.rbs +12 -2
- data/sig/sentdm/models/webhook_list_event_types_params.rbs +13 -3
- data/sig/sentdm/models/webhook_list_events_params.rbs +13 -1
- data/sig/sentdm/models/webhook_list_params.rbs +13 -1
- data/sig/sentdm/models/webhook_retrieve_params.rbs +12 -2
- data/sig/sentdm/models/webhook_rotate_secret_params.rbs +9 -2
- data/sig/sentdm/models/webhook_test_params.rbs +13 -6
- data/sig/sentdm/models/webhook_toggle_status_params.rbs +17 -5
- data/sig/sentdm/models/webhook_update_params.rbs +13 -6
- data/sig/sentdm/models.rbs +14 -32
- data/sig/sentdm/resources/contacts.rbs +10 -5
- data/sig/sentdm/resources/me.rbs +1 -0
- data/sig/sentdm/resources/messages.rbs +4 -1
- data/sig/sentdm/resources/{lookup.rbs → numbers.rbs} +4 -3
- data/sig/sentdm/resources/profiles/campaigns.rbs +42 -0
- data/sig/sentdm/resources/profiles.rbs +22 -9
- data/sig/sentdm/resources/templates.rbs +9 -3
- data/sig/sentdm/resources/users.rbs +10 -7
- data/sig/sentdm/resources/webhooks.rbs +18 -5
- metadata +67 -106
- data/lib/sentdm/models/api_response_brand_with_kyc.rb +0 -43
- data/lib/sentdm/models/brand_create_params.rb +0 -41
- data/lib/sentdm/models/brand_data.rb +0 -237
- data/lib/sentdm/models/brand_delete_params.rb +0 -34
- data/lib/sentdm/models/brand_list_params.rb +0 -14
- data/lib/sentdm/models/brand_list_response.rb +0 -43
- data/lib/sentdm/models/brand_update_params.rb +0 -48
- data/lib/sentdm/models/brand_with_kyc.rb +0 -335
- data/lib/sentdm/models/brands/base_dto.rb +0 -32
- data/lib/sentdm/models/brands/campaign_create_params.rb +0 -50
- data/lib/sentdm/models/brands/campaign_delete_params.rb +0 -43
- data/lib/sentdm/models/brands/campaign_list_params.rb +0 -22
- data/lib/sentdm/models/brands/campaign_update_params.rb +0 -57
- data/lib/sentdm/models/brands/sent_dm_services_endpoints_customer_ap_iv3_contracts_requests_campaigns_campaign_use_case_data.rb +0 -30
- data/lib/sentdm/models/mutation_request.rb +0 -20
- data/lib/sentdm/models/sent_dm_services_common_contracts_poc_os_authentication_config.rb +0 -34
- data/lib/sentdm/models/sent_dm_services_common_contracts_poc_os_template_body.rb +0 -40
- data/lib/sentdm/models/sent_dm_services_common_contracts_poc_os_template_button.rb +0 -38
- data/lib/sentdm/models/sent_dm_services_common_contracts_poc_os_template_button_props.rb +0 -81
- data/lib/sentdm/models/sent_dm_services_common_contracts_poc_os_template_footer.rb +0 -34
- data/lib/sentdm/models/sent_dm_services_common_contracts_poc_os_template_header.rb +0 -39
- data/lib/sentdm/resources/brands/campaigns.rb +0 -145
- data/lib/sentdm/resources/brands.rb +0 -130
- data/lib/sentdm/resources/lookup.rb +0 -35
- data/rbi/sentdm/models/api_response_contact.rbi +0 -74
- data/rbi/sentdm/models/brand_create_params.rbi +0 -68
- data/rbi/sentdm/models/brand_data.rbi +0 -266
- data/rbi/sentdm/models/brand_delete_params.rbi +0 -68
- data/rbi/sentdm/models/brand_list_params.rbi +0 -27
- data/rbi/sentdm/models/brand_list_response.rbi +0 -71
- data/rbi/sentdm/models/brand_update_params.rbi +0 -74
- data/rbi/sentdm/models/brand_with_kyc.rbi +0 -398
- data/rbi/sentdm/models/brands/base_dto.rbi +0 -53
- data/rbi/sentdm/models/brands/campaign_list_params.rbi +0 -37
- data/rbi/sentdm/models/brands/sent_dm_services_endpoints_customer_ap_iv3_contracts_requests_campaigns_campaign_use_case_data.rbi +0 -52
- data/rbi/sentdm/models/mutation_request.rbi +0 -32
- data/rbi/sentdm/models/sent_dm_services_common_contracts_poc_os_authentication_config.rbi +0 -56
- data/rbi/sentdm/models/sent_dm_services_common_contracts_poc_os_template_body.rbi +0 -76
- data/rbi/sentdm/models/sent_dm_services_common_contracts_poc_os_template_button.rbi +0 -79
- data/rbi/sentdm/models/sent_dm_services_common_contracts_poc_os_template_button_props.rbi +0 -104
- data/rbi/sentdm/models/sent_dm_services_common_contracts_poc_os_template_footer.rbi +0 -60
- data/rbi/sentdm/models/sent_dm_services_common_contracts_poc_os_template_header.rbi +0 -62
- data/rbi/sentdm/resources/brands/campaigns.rbi +0 -109
- data/rbi/sentdm/resources/brands.rbi +0 -95
- data/rbi/sentdm/resources/lookup.rbi +0 -24
- data/sig/sentdm/models/api_response_brand_with_kyc.rbs +0 -39
- data/sig/sentdm/models/brand_create_params.rbs +0 -36
- data/sig/sentdm/models/brand_data.rbs +0 -164
- data/sig/sentdm/models/brand_delete_params.rbs +0 -36
- data/sig/sentdm/models/brand_list_params.rbs +0 -14
- data/sig/sentdm/models/brand_list_response.rbs +0 -39
- data/sig/sentdm/models/brand_update_params.rbs +0 -45
- data/sig/sentdm/models/brand_with_kyc.rbs +0 -237
- data/sig/sentdm/models/brands/base_dto.rbs +0 -27
- data/sig/sentdm/models/brands/campaign_create_params.rbs +0 -47
- data/sig/sentdm/models/brands/sent_dm_services_endpoints_customer_ap_iv3_contracts_requests_campaigns_campaign_use_case_data.rbs +0 -27
- data/sig/sentdm/models/mutation_request.rbs +0 -15
- data/sig/sentdm/models/profile_complete_response.rbs +0 -5
- data/sig/sentdm/models/sent_dm_services_common_contracts_poc_os_authentication_config.rbs +0 -24
- data/sig/sentdm/models/sent_dm_services_common_contracts_poc_os_template_body.rbs +0 -30
- data/sig/sentdm/models/sent_dm_services_common_contracts_poc_os_template_button.rbs +0 -38
- data/sig/sentdm/models/sent_dm_services_common_contracts_poc_os_template_button_props.rbs +0 -75
- data/sig/sentdm/models/sent_dm_services_common_contracts_poc_os_template_footer.rbs +0 -32
- data/sig/sentdm/models/sent_dm_services_common_contracts_poc_os_template_header.rbs +0 -32
- data/sig/sentdm/resources/brands/campaigns.rbs +0 -38
- data/sig/sentdm/resources/brands.rbs +0 -34
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Models
|
|
5
|
-
class MutationRequest < Sentdm::Internal::Type::BaseModel
|
|
6
|
-
# @!attribute test_mode
|
|
7
|
-
# Test mode flag - when true, the operation is simulated without side effects
|
|
8
|
-
# Useful for testing integrations without actual execution
|
|
9
|
-
#
|
|
10
|
-
# @return [Boolean, nil]
|
|
11
|
-
optional :test_mode, Sentdm::Internal::Type::Boolean
|
|
12
|
-
|
|
13
|
-
# @!method initialize(test_mode: nil)
|
|
14
|
-
# Some parameter documentations has been truncated, see
|
|
15
|
-
# {Sentdm::Models::MutationRequest} for more details.
|
|
16
|
-
#
|
|
17
|
-
# @param test_mode [Boolean] Test mode flag - when true, the operation is simulated without side effects
|
|
18
|
-
end
|
|
19
|
-
end
|
|
20
|
-
end
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Models
|
|
5
|
-
class SentDmServicesCommonContractsPocOsAuthenticationConfig < Sentdm::Internal::Type::BaseModel
|
|
6
|
-
# @!attribute add_security_recommendation
|
|
7
|
-
# Whether to add the security recommendation text: "For your security, do not
|
|
8
|
-
# share this code."
|
|
9
|
-
#
|
|
10
|
-
# @return [Boolean, nil]
|
|
11
|
-
optional :add_security_recommendation,
|
|
12
|
-
Sentdm::Internal::Type::Boolean,
|
|
13
|
-
api_name: :addSecurityRecommendation
|
|
14
|
-
|
|
15
|
-
# @!attribute code_expiration_minutes
|
|
16
|
-
# Code expiration time in minutes (1-90). If set, adds footer: "This code expires
|
|
17
|
-
# in X minutes."
|
|
18
|
-
#
|
|
19
|
-
# @return [Integer, nil]
|
|
20
|
-
optional :code_expiration_minutes, Integer, api_name: :codeExpirationMinutes, nil?: true
|
|
21
|
-
|
|
22
|
-
# @!method initialize(add_security_recommendation: nil, code_expiration_minutes: nil)
|
|
23
|
-
# Some parameter documentations has been truncated, see
|
|
24
|
-
# {Sentdm::Models::SentDmServicesCommonContractsPocOsAuthenticationConfig} for
|
|
25
|
-
# more details.
|
|
26
|
-
#
|
|
27
|
-
# Configuration for AUTHENTICATION category templates
|
|
28
|
-
#
|
|
29
|
-
# @param add_security_recommendation [Boolean] Whether to add the security recommendation text: "For your security, do not shar
|
|
30
|
-
#
|
|
31
|
-
# @param code_expiration_minutes [Integer, nil] Code expiration time in minutes (1-90). If set, adds footer: "This code expires
|
|
32
|
-
end
|
|
33
|
-
end
|
|
34
|
-
end
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Models
|
|
5
|
-
class SentDmServicesCommonContractsPocOsTemplateBody < Sentdm::Internal::Type::BaseModel
|
|
6
|
-
# @!attribute multi_channel
|
|
7
|
-
# Content that will be used for all channels (SMS and WhatsApp) unless
|
|
8
|
-
# channel-specific content is provided
|
|
9
|
-
#
|
|
10
|
-
# @return [Sentdm::Models::TemplateBodyContent, nil]
|
|
11
|
-
optional :multi_channel, -> { Sentdm::TemplateBodyContent }, api_name: :multiChannel, nil?: true
|
|
12
|
-
|
|
13
|
-
# @!attribute sms
|
|
14
|
-
# SMS-specific content that overrides multi-channel content for SMS messages
|
|
15
|
-
#
|
|
16
|
-
# @return [Sentdm::Models::TemplateBodyContent, nil]
|
|
17
|
-
optional :sms, -> { Sentdm::TemplateBodyContent }, nil?: true
|
|
18
|
-
|
|
19
|
-
# @!attribute whatsapp
|
|
20
|
-
# WhatsApp-specific content that overrides multi-channel content for WhatsApp
|
|
21
|
-
# messages
|
|
22
|
-
#
|
|
23
|
-
# @return [Sentdm::Models::TemplateBodyContent, nil]
|
|
24
|
-
optional :whatsapp, -> { Sentdm::TemplateBodyContent }, nil?: true
|
|
25
|
-
|
|
26
|
-
# @!method initialize(multi_channel: nil, sms: nil, whatsapp: nil)
|
|
27
|
-
# Some parameter documentations has been truncated, see
|
|
28
|
-
# {Sentdm::Models::SentDmServicesCommonContractsPocOsTemplateBody} for more
|
|
29
|
-
# details.
|
|
30
|
-
#
|
|
31
|
-
# Body section of a message template with channel-specific content
|
|
32
|
-
#
|
|
33
|
-
# @param multi_channel [Sentdm::Models::TemplateBodyContent, nil] Content that will be used for all channels (SMS and WhatsApp) unless channel-spe
|
|
34
|
-
#
|
|
35
|
-
# @param sms [Sentdm::Models::TemplateBodyContent, nil] SMS-specific content that overrides multi-channel content for SMS messages
|
|
36
|
-
#
|
|
37
|
-
# @param whatsapp [Sentdm::Models::TemplateBodyContent, nil] WhatsApp-specific content that overrides multi-channel content for WhatsApp mess
|
|
38
|
-
end
|
|
39
|
-
end
|
|
40
|
-
end
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Models
|
|
5
|
-
class SentDmServicesCommonContractsPocOsTemplateButton < Sentdm::Internal::Type::BaseModel
|
|
6
|
-
# @!attribute id
|
|
7
|
-
# The unique identifier of the button (1-based index)
|
|
8
|
-
#
|
|
9
|
-
# @return [Integer, nil]
|
|
10
|
-
optional :id, Integer
|
|
11
|
-
|
|
12
|
-
# @!attribute props
|
|
13
|
-
# Properties specific to the button type
|
|
14
|
-
#
|
|
15
|
-
# @return [Sentdm::Models::SentDmServicesCommonContractsPocOsTemplateButtonProps, nil]
|
|
16
|
-
optional :props, -> { Sentdm::SentDmServicesCommonContractsPocOsTemplateButtonProps }
|
|
17
|
-
|
|
18
|
-
# @!attribute type
|
|
19
|
-
# The type of button (e.g., QUICK_REPLY, URL, PHONE_NUMBER, VOICE_CALL, COPY_CODE)
|
|
20
|
-
#
|
|
21
|
-
# @return [String, nil]
|
|
22
|
-
optional :type, String
|
|
23
|
-
|
|
24
|
-
# @!method initialize(id: nil, props: nil, type: nil)
|
|
25
|
-
# Some parameter documentations has been truncated, see
|
|
26
|
-
# {Sentdm::Models::SentDmServicesCommonContractsPocOsTemplateButton} for more
|
|
27
|
-
# details.
|
|
28
|
-
#
|
|
29
|
-
# Interactive button in a message template
|
|
30
|
-
#
|
|
31
|
-
# @param id [Integer] The unique identifier of the button (1-based index)
|
|
32
|
-
#
|
|
33
|
-
# @param props [Sentdm::Models::SentDmServicesCommonContractsPocOsTemplateButtonProps] Properties specific to the button type
|
|
34
|
-
#
|
|
35
|
-
# @param type [String] The type of button (e.g., QUICK_REPLY, URL, PHONE_NUMBER, VOICE_CALL, COPY_CODE)
|
|
36
|
-
end
|
|
37
|
-
end
|
|
38
|
-
end
|
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Models
|
|
5
|
-
class SentDmServicesCommonContractsPocOsTemplateButtonProps < Sentdm::Internal::Type::BaseModel
|
|
6
|
-
# @!attribute active_for
|
|
7
|
-
#
|
|
8
|
-
# @return [Integer, nil]
|
|
9
|
-
optional :active_for, Integer, api_name: :activeFor, nil?: true
|
|
10
|
-
|
|
11
|
-
# @!attribute autofill_text
|
|
12
|
-
#
|
|
13
|
-
# @return [String, nil]
|
|
14
|
-
optional :autofill_text, String, api_name: :autofillText, nil?: true
|
|
15
|
-
|
|
16
|
-
# @!attribute country_code
|
|
17
|
-
#
|
|
18
|
-
# @return [String, nil]
|
|
19
|
-
optional :country_code, String, api_name: :countryCode, nil?: true
|
|
20
|
-
|
|
21
|
-
# @!attribute offer_code
|
|
22
|
-
#
|
|
23
|
-
# @return [String, nil]
|
|
24
|
-
optional :offer_code, String, api_name: :offerCode, nil?: true
|
|
25
|
-
|
|
26
|
-
# @!attribute otp_type
|
|
27
|
-
#
|
|
28
|
-
# @return [String, nil]
|
|
29
|
-
optional :otp_type, String, api_name: :otpType, nil?: true
|
|
30
|
-
|
|
31
|
-
# @!attribute package_name
|
|
32
|
-
#
|
|
33
|
-
# @return [String, nil]
|
|
34
|
-
optional :package_name, String, api_name: :packageName, nil?: true
|
|
35
|
-
|
|
36
|
-
# @!attribute phone_number
|
|
37
|
-
#
|
|
38
|
-
# @return [String, nil]
|
|
39
|
-
optional :phone_number, String, api_name: :phoneNumber, nil?: true
|
|
40
|
-
|
|
41
|
-
# @!attribute quick_reply_type
|
|
42
|
-
#
|
|
43
|
-
# @return [String, nil]
|
|
44
|
-
optional :quick_reply_type, String, api_name: :quickReplyType, nil?: true
|
|
45
|
-
|
|
46
|
-
# @!attribute signature_hash
|
|
47
|
-
#
|
|
48
|
-
# @return [String, nil]
|
|
49
|
-
optional :signature_hash, String, api_name: :signatureHash, nil?: true
|
|
50
|
-
|
|
51
|
-
# @!attribute text
|
|
52
|
-
#
|
|
53
|
-
# @return [String, nil]
|
|
54
|
-
optional :text, String, nil?: true
|
|
55
|
-
|
|
56
|
-
# @!attribute url
|
|
57
|
-
#
|
|
58
|
-
# @return [String, nil]
|
|
59
|
-
optional :url, String, nil?: true
|
|
60
|
-
|
|
61
|
-
# @!attribute url_type
|
|
62
|
-
#
|
|
63
|
-
# @return [String, nil]
|
|
64
|
-
optional :url_type, String, api_name: :urlType, nil?: true
|
|
65
|
-
|
|
66
|
-
# @!method initialize(active_for: nil, autofill_text: nil, country_code: nil, offer_code: nil, otp_type: nil, package_name: nil, phone_number: nil, quick_reply_type: nil, signature_hash: nil, text: nil, url: nil, url_type: nil)
|
|
67
|
-
# @param active_for [Integer, nil]
|
|
68
|
-
# @param autofill_text [String, nil]
|
|
69
|
-
# @param country_code [String, nil]
|
|
70
|
-
# @param offer_code [String, nil]
|
|
71
|
-
# @param otp_type [String, nil]
|
|
72
|
-
# @param package_name [String, nil]
|
|
73
|
-
# @param phone_number [String, nil]
|
|
74
|
-
# @param quick_reply_type [String, nil]
|
|
75
|
-
# @param signature_hash [String, nil]
|
|
76
|
-
# @param text [String, nil]
|
|
77
|
-
# @param url [String, nil]
|
|
78
|
-
# @param url_type [String, nil]
|
|
79
|
-
end
|
|
80
|
-
end
|
|
81
|
-
end
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Models
|
|
5
|
-
class SentDmServicesCommonContractsPocOsTemplateFooter < Sentdm::Internal::Type::BaseModel
|
|
6
|
-
# @!attribute template
|
|
7
|
-
# The footer template text with optional variable placeholders
|
|
8
|
-
#
|
|
9
|
-
# @return [String, nil]
|
|
10
|
-
optional :template, String
|
|
11
|
-
|
|
12
|
-
# @!attribute type
|
|
13
|
-
# The type of footer (typically "text")
|
|
14
|
-
#
|
|
15
|
-
# @return [String, nil]
|
|
16
|
-
optional :type, String, nil?: true
|
|
17
|
-
|
|
18
|
-
# @!attribute variables
|
|
19
|
-
# List of variables used in the footer template
|
|
20
|
-
#
|
|
21
|
-
# @return [Array<Sentdm::Models::TemplateVariable>, nil]
|
|
22
|
-
optional :variables, -> { Sentdm::Internal::Type::ArrayOf[Sentdm::TemplateVariable] }, nil?: true
|
|
23
|
-
|
|
24
|
-
# @!method initialize(template: nil, type: nil, variables: nil)
|
|
25
|
-
# Footer section of a message template
|
|
26
|
-
#
|
|
27
|
-
# @param template [String] The footer template text with optional variable placeholders
|
|
28
|
-
#
|
|
29
|
-
# @param type [String, nil] The type of footer (typically "text")
|
|
30
|
-
#
|
|
31
|
-
# @param variables [Array<Sentdm::Models::TemplateVariable>, nil] List of variables used in the footer template
|
|
32
|
-
end
|
|
33
|
-
end
|
|
34
|
-
end
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Models
|
|
5
|
-
class SentDmServicesCommonContractsPocOsTemplateHeader < Sentdm::Internal::Type::BaseModel
|
|
6
|
-
# @!attribute template
|
|
7
|
-
# The header template text with optional variable placeholders (e.g., "Welcome to
|
|
8
|
-
# {{0:variable}}")
|
|
9
|
-
#
|
|
10
|
-
# @return [String, nil]
|
|
11
|
-
optional :template, String
|
|
12
|
-
|
|
13
|
-
# @!attribute type
|
|
14
|
-
# The type of header (e.g., "text", "image", "video", "document")
|
|
15
|
-
#
|
|
16
|
-
# @return [String, nil]
|
|
17
|
-
optional :type, String, nil?: true
|
|
18
|
-
|
|
19
|
-
# @!attribute variables
|
|
20
|
-
# List of variables used in the header template
|
|
21
|
-
#
|
|
22
|
-
# @return [Array<Sentdm::Models::TemplateVariable>, nil]
|
|
23
|
-
optional :variables, -> { Sentdm::Internal::Type::ArrayOf[Sentdm::TemplateVariable] }, nil?: true
|
|
24
|
-
|
|
25
|
-
# @!method initialize(template: nil, type: nil, variables: nil)
|
|
26
|
-
# Some parameter documentations has been truncated, see
|
|
27
|
-
# {Sentdm::Models::SentDmServicesCommonContractsPocOsTemplateHeader} for more
|
|
28
|
-
# details.
|
|
29
|
-
#
|
|
30
|
-
# Header section of a message template
|
|
31
|
-
#
|
|
32
|
-
# @param template [String] The header template text with optional variable placeholders (e.g., "Welcome to
|
|
33
|
-
#
|
|
34
|
-
# @param type [String, nil] The type of header (e.g., "text", "image", "video", "document")
|
|
35
|
-
#
|
|
36
|
-
# @param variables [Array<Sentdm::Models::TemplateVariable>, nil] List of variables used in the header template
|
|
37
|
-
end
|
|
38
|
-
end
|
|
39
|
-
end
|
|
@@ -1,145 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Resources
|
|
5
|
-
class Brands
|
|
6
|
-
# Register and manage 10DLC brands for SMS compliance
|
|
7
|
-
class Campaigns
|
|
8
|
-
# Some parameter documentations has been truncated, see
|
|
9
|
-
# {Sentdm::Models::Brands::CampaignCreateParams} for more details.
|
|
10
|
-
#
|
|
11
|
-
# Creates a new campaign scoped under a specific brand. The campaign is linked to
|
|
12
|
-
# the specified brand. Each campaign must include at least one use case with
|
|
13
|
-
# sample messages.
|
|
14
|
-
#
|
|
15
|
-
# @overload create(brand_id, campaign:, test_mode: nil, idempotency_key: nil, request_options: {})
|
|
16
|
-
#
|
|
17
|
-
# @param brand_id [String] Path param: Brand ID from route
|
|
18
|
-
#
|
|
19
|
-
# @param campaign [Sentdm::Models::Brands::CampaignData] Body param: Campaign data
|
|
20
|
-
#
|
|
21
|
-
# @param test_mode [Boolean] Body param: Test mode flag - when true, the operation is simulated without side
|
|
22
|
-
#
|
|
23
|
-
# @param idempotency_key [String] Header param: Unique key to ensure idempotent request processing. Must be 1-255
|
|
24
|
-
#
|
|
25
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
26
|
-
#
|
|
27
|
-
# @return [Sentdm::Models::Brands::APIResponseTcrCampaignWithUseCases]
|
|
28
|
-
#
|
|
29
|
-
# @see Sentdm::Models::Brands::CampaignCreateParams
|
|
30
|
-
def create(brand_id, params)
|
|
31
|
-
parsed, options = Sentdm::Brands::CampaignCreateParams.dump_request(params)
|
|
32
|
-
header_params = {idempotency_key: "idempotency-key"}
|
|
33
|
-
@client.request(
|
|
34
|
-
method: :post,
|
|
35
|
-
path: ["v3/brands/%1$s/campaigns", brand_id],
|
|
36
|
-
headers: parsed.slice(*header_params.keys).transform_keys(header_params),
|
|
37
|
-
body: parsed.except(*header_params.keys),
|
|
38
|
-
model: Sentdm::Brands::APIResponseTcrCampaignWithUseCases,
|
|
39
|
-
options: options
|
|
40
|
-
)
|
|
41
|
-
end
|
|
42
|
-
|
|
43
|
-
# Some parameter documentations has been truncated, see
|
|
44
|
-
# {Sentdm::Models::Brands::CampaignUpdateParams} for more details.
|
|
45
|
-
#
|
|
46
|
-
# Updates an existing campaign scoped under a specific brand. Cannot update
|
|
47
|
-
# campaigns that have already been submitted to TCR.
|
|
48
|
-
#
|
|
49
|
-
# @overload update(campaign_id, brand_id:, campaign:, test_mode: nil, idempotency_key: nil, request_options: {})
|
|
50
|
-
#
|
|
51
|
-
# @param campaign_id [String] Path param: Campaign ID from route
|
|
52
|
-
#
|
|
53
|
-
# @param brand_id [String] Path param: Brand ID from route
|
|
54
|
-
#
|
|
55
|
-
# @param campaign [Sentdm::Models::Brands::CampaignData] Body param: Campaign data
|
|
56
|
-
#
|
|
57
|
-
# @param test_mode [Boolean] Body param: Test mode flag - when true, the operation is simulated without side
|
|
58
|
-
#
|
|
59
|
-
# @param idempotency_key [String] Header param: Unique key to ensure idempotent request processing. Must be 1-255
|
|
60
|
-
#
|
|
61
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
62
|
-
#
|
|
63
|
-
# @return [Sentdm::Models::Brands::APIResponseTcrCampaignWithUseCases]
|
|
64
|
-
#
|
|
65
|
-
# @see Sentdm::Models::Brands::CampaignUpdateParams
|
|
66
|
-
def update(campaign_id, params)
|
|
67
|
-
parsed, options = Sentdm::Brands::CampaignUpdateParams.dump_request(params)
|
|
68
|
-
brand_id =
|
|
69
|
-
parsed.delete(:brand_id) do
|
|
70
|
-
raise ArgumentError.new("missing required path argument #{_1}")
|
|
71
|
-
end
|
|
72
|
-
header_params = {idempotency_key: "idempotency-key"}
|
|
73
|
-
@client.request(
|
|
74
|
-
method: :put,
|
|
75
|
-
path: ["v3/brands/%1$s/campaigns/%2$s", brand_id, campaign_id],
|
|
76
|
-
headers: parsed.slice(*header_params.keys).transform_keys(header_params),
|
|
77
|
-
body: parsed.except(*header_params.keys),
|
|
78
|
-
model: Sentdm::Brands::APIResponseTcrCampaignWithUseCases,
|
|
79
|
-
options: options
|
|
80
|
-
)
|
|
81
|
-
end
|
|
82
|
-
|
|
83
|
-
# Retrieves all campaigns linked to a specific brand, including their use cases
|
|
84
|
-
# and sample messages.
|
|
85
|
-
#
|
|
86
|
-
# @overload list(brand_id, request_options: {})
|
|
87
|
-
#
|
|
88
|
-
# @param brand_id [String] Brand ID from route
|
|
89
|
-
#
|
|
90
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
91
|
-
#
|
|
92
|
-
# @return [Sentdm::Models::Brands::CampaignListResponse]
|
|
93
|
-
#
|
|
94
|
-
# @see Sentdm::Models::Brands::CampaignListParams
|
|
95
|
-
def list(brand_id, params = {})
|
|
96
|
-
@client.request(
|
|
97
|
-
method: :get,
|
|
98
|
-
path: ["v3/brands/%1$s/campaigns", brand_id],
|
|
99
|
-
model: Sentdm::Models::Brands::CampaignListResponse,
|
|
100
|
-
options: params[:request_options]
|
|
101
|
-
)
|
|
102
|
-
end
|
|
103
|
-
|
|
104
|
-
# Deletes a campaign by ID within a specific brand. The brand must belong to the
|
|
105
|
-
# authenticated customer.
|
|
106
|
-
#
|
|
107
|
-
# @overload delete(campaign_id, brand_id:, body:, request_options: {})
|
|
108
|
-
#
|
|
109
|
-
# @param campaign_id [String] Path param: Campaign ID from route parameter
|
|
110
|
-
#
|
|
111
|
-
# @param brand_id [String] Path param: Brand ID from route parameter
|
|
112
|
-
#
|
|
113
|
-
# @param body [Sentdm::Models::Brands::CampaignDeleteParams::Body] Body param: Request to delete a campaign from a brand
|
|
114
|
-
#
|
|
115
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
116
|
-
#
|
|
117
|
-
# @return [nil]
|
|
118
|
-
#
|
|
119
|
-
# @see Sentdm::Models::Brands::CampaignDeleteParams
|
|
120
|
-
def delete(campaign_id, params)
|
|
121
|
-
parsed, options = Sentdm::Brands::CampaignDeleteParams.dump_request(params)
|
|
122
|
-
brand_id =
|
|
123
|
-
parsed.delete(:brand_id) do
|
|
124
|
-
raise ArgumentError.new("missing required path argument #{_1}")
|
|
125
|
-
end
|
|
126
|
-
@client.request(
|
|
127
|
-
method: :delete,
|
|
128
|
-
path: ["v3/brands/%1$s/campaigns/%2$s", brand_id, campaign_id],
|
|
129
|
-
headers: {"content-type" => "*/*"},
|
|
130
|
-
body: parsed[:body],
|
|
131
|
-
model: NilClass,
|
|
132
|
-
options: options
|
|
133
|
-
)
|
|
134
|
-
end
|
|
135
|
-
|
|
136
|
-
# @api private
|
|
137
|
-
#
|
|
138
|
-
# @param client [Sentdm::Client]
|
|
139
|
-
def initialize(client:)
|
|
140
|
-
@client = client
|
|
141
|
-
end
|
|
142
|
-
end
|
|
143
|
-
end
|
|
144
|
-
end
|
|
145
|
-
end
|
|
@@ -1,130 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Resources
|
|
5
|
-
# Register and manage 10DLC brands for SMS compliance
|
|
6
|
-
class Brands
|
|
7
|
-
# Register and manage 10DLC brands for SMS compliance
|
|
8
|
-
# @return [Sentdm::Resources::Brands::Campaigns]
|
|
9
|
-
attr_reader :campaigns
|
|
10
|
-
|
|
11
|
-
# Some parameter documentations has been truncated, see
|
|
12
|
-
# {Sentdm::Models::BrandCreateParams} for more details.
|
|
13
|
-
#
|
|
14
|
-
# Creates a new brand and associated information. This endpoint automatically sets
|
|
15
|
-
# inheritTcrBrand=false when a brand is created.
|
|
16
|
-
#
|
|
17
|
-
# @overload create(brand:, test_mode: nil, idempotency_key: nil, request_options: {})
|
|
18
|
-
#
|
|
19
|
-
# @param brand [Sentdm::Models::BrandData] Body param: Brand and KYC information
|
|
20
|
-
#
|
|
21
|
-
# @param test_mode [Boolean] Body param: Test mode flag - when true, the operation is simulated without side
|
|
22
|
-
#
|
|
23
|
-
# @param idempotency_key [String] Header param: Unique key to ensure idempotent request processing. Must be 1-255
|
|
24
|
-
#
|
|
25
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
26
|
-
#
|
|
27
|
-
# @return [Sentdm::Models::APIResponseBrandWithKYC]
|
|
28
|
-
#
|
|
29
|
-
# @see Sentdm::Models::BrandCreateParams
|
|
30
|
-
def create(params)
|
|
31
|
-
parsed, options = Sentdm::BrandCreateParams.dump_request(params)
|
|
32
|
-
header_params = {idempotency_key: "idempotency-key"}
|
|
33
|
-
@client.request(
|
|
34
|
-
method: :post,
|
|
35
|
-
path: "v3/brands",
|
|
36
|
-
headers: parsed.slice(*header_params.keys).transform_keys(header_params),
|
|
37
|
-
body: parsed.except(*header_params.keys),
|
|
38
|
-
model: Sentdm::APIResponseBrandWithKYC,
|
|
39
|
-
options: options
|
|
40
|
-
)
|
|
41
|
-
end
|
|
42
|
-
|
|
43
|
-
# Some parameter documentations has been truncated, see
|
|
44
|
-
# {Sentdm::Models::BrandUpdateParams} for more details.
|
|
45
|
-
#
|
|
46
|
-
# Updates an existing brand and its associated information. Cannot update brands
|
|
47
|
-
# that have already been submitted to TCR or inherited brands.
|
|
48
|
-
#
|
|
49
|
-
# @overload update(brand_id, brand:, test_mode: nil, idempotency_key: nil, request_options: {})
|
|
50
|
-
#
|
|
51
|
-
# @param brand_id [String] Path param: Brand ID from route
|
|
52
|
-
#
|
|
53
|
-
# @param brand [Sentdm::Models::BrandData] Body param: Brand and KYC information
|
|
54
|
-
#
|
|
55
|
-
# @param test_mode [Boolean] Body param: Test mode flag - when true, the operation is simulated without side
|
|
56
|
-
#
|
|
57
|
-
# @param idempotency_key [String] Header param: Unique key to ensure idempotent request processing. Must be 1-255
|
|
58
|
-
#
|
|
59
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
60
|
-
#
|
|
61
|
-
# @return [Sentdm::Models::APIResponseBrandWithKYC]
|
|
62
|
-
#
|
|
63
|
-
# @see Sentdm::Models::BrandUpdateParams
|
|
64
|
-
def update(brand_id, params)
|
|
65
|
-
parsed, options = Sentdm::BrandUpdateParams.dump_request(params)
|
|
66
|
-
header_params = {idempotency_key: "idempotency-key"}
|
|
67
|
-
@client.request(
|
|
68
|
-
method: :put,
|
|
69
|
-
path: ["v3/brands/%1$s", brand_id],
|
|
70
|
-
headers: parsed.slice(*header_params.keys).transform_keys(header_params),
|
|
71
|
-
body: parsed.except(*header_params.keys),
|
|
72
|
-
model: Sentdm::APIResponseBrandWithKYC,
|
|
73
|
-
options: options
|
|
74
|
-
)
|
|
75
|
-
end
|
|
76
|
-
|
|
77
|
-
# Retrieves all brands for the authenticated customer with information in a
|
|
78
|
-
# flattened structure. Includes inherited brands if inheritTcrBrand=true.
|
|
79
|
-
#
|
|
80
|
-
# @overload list(request_options: {})
|
|
81
|
-
#
|
|
82
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
83
|
-
#
|
|
84
|
-
# @return [Sentdm::Models::BrandListResponse]
|
|
85
|
-
#
|
|
86
|
-
# @see Sentdm::Models::BrandListParams
|
|
87
|
-
def list(params = {})
|
|
88
|
-
@client.request(
|
|
89
|
-
method: :get,
|
|
90
|
-
path: "v3/brands",
|
|
91
|
-
model: Sentdm::Models::BrandListResponse,
|
|
92
|
-
options: params[:request_options]
|
|
93
|
-
)
|
|
94
|
-
end
|
|
95
|
-
|
|
96
|
-
# Delete a brand by ID. The brand must belong to the authenticated customer.
|
|
97
|
-
#
|
|
98
|
-
# @overload delete(brand_id, body:, request_options: {})
|
|
99
|
-
#
|
|
100
|
-
# @param brand_id [String] Brand ID from route parameter
|
|
101
|
-
#
|
|
102
|
-
# @param body [Sentdm::Models::BrandDeleteParams::Body] Request to delete a brand
|
|
103
|
-
#
|
|
104
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
105
|
-
#
|
|
106
|
-
# @return [nil]
|
|
107
|
-
#
|
|
108
|
-
# @see Sentdm::Models::BrandDeleteParams
|
|
109
|
-
def delete(brand_id, params)
|
|
110
|
-
parsed, options = Sentdm::BrandDeleteParams.dump_request(params)
|
|
111
|
-
@client.request(
|
|
112
|
-
method: :delete,
|
|
113
|
-
path: ["v3/brands/%1$s", brand_id],
|
|
114
|
-
headers: {"content-type" => "*/*"},
|
|
115
|
-
body: parsed[:body],
|
|
116
|
-
model: NilClass,
|
|
117
|
-
options: options
|
|
118
|
-
)
|
|
119
|
-
end
|
|
120
|
-
|
|
121
|
-
# @api private
|
|
122
|
-
#
|
|
123
|
-
# @param client [Sentdm::Client]
|
|
124
|
-
def initialize(client:)
|
|
125
|
-
@client = client
|
|
126
|
-
@campaigns = Sentdm::Resources::Brands::Campaigns.new(client: client)
|
|
127
|
-
end
|
|
128
|
-
end
|
|
129
|
-
end
|
|
130
|
-
end
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Resources
|
|
5
|
-
class Lookup
|
|
6
|
-
# Validates a phone number and retrieves formatting, country, and timezone
|
|
7
|
-
# information from the internal index. Provider-agnostic and works for all
|
|
8
|
-
# customers.
|
|
9
|
-
#
|
|
10
|
-
# @overload retrieve_phone_info(phone_number, request_options: {})
|
|
11
|
-
#
|
|
12
|
-
# @param phone_number [String]
|
|
13
|
-
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
14
|
-
#
|
|
15
|
-
# @return [Sentdm::Models::LookupRetrievePhoneInfoResponse]
|
|
16
|
-
#
|
|
17
|
-
# @see Sentdm::Models::LookupRetrievePhoneInfoParams
|
|
18
|
-
def retrieve_phone_info(phone_number, params = {})
|
|
19
|
-
@client.request(
|
|
20
|
-
method: :get,
|
|
21
|
-
path: ["v3/lookup/number/%1$s", phone_number],
|
|
22
|
-
model: Sentdm::Models::LookupRetrievePhoneInfoResponse,
|
|
23
|
-
options: params[:request_options]
|
|
24
|
-
)
|
|
25
|
-
end
|
|
26
|
-
|
|
27
|
-
# @api private
|
|
28
|
-
#
|
|
29
|
-
# @param client [Sentdm::Client]
|
|
30
|
-
def initialize(client:)
|
|
31
|
-
@client = client
|
|
32
|
-
end
|
|
33
|
-
end
|
|
34
|
-
end
|
|
35
|
-
end
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
# typed: strong
|
|
2
|
-
|
|
3
|
-
module Sentdm
|
|
4
|
-
module Models
|
|
5
|
-
class APIResponseContact < Sentdm::Internal::Type::BaseModel
|
|
6
|
-
OrHash =
|
|
7
|
-
T.type_alias do
|
|
8
|
-
T.any(Sentdm::APIResponseContact, Sentdm::Internal::AnyHash)
|
|
9
|
-
end
|
|
10
|
-
|
|
11
|
-
# The response data (null if error)
|
|
12
|
-
sig { returns(T.nilable(Sentdm::Contact)) }
|
|
13
|
-
attr_reader :data
|
|
14
|
-
|
|
15
|
-
sig { params(data: T.nilable(Sentdm::Contact::OrHash)).void }
|
|
16
|
-
attr_writer :data
|
|
17
|
-
|
|
18
|
-
# Error details (null if successful)
|
|
19
|
-
sig { returns(T.nilable(Sentdm::APIError)) }
|
|
20
|
-
attr_reader :error
|
|
21
|
-
|
|
22
|
-
sig { params(error: T.nilable(Sentdm::APIError::OrHash)).void }
|
|
23
|
-
attr_writer :error
|
|
24
|
-
|
|
25
|
-
# Metadata about the request and response
|
|
26
|
-
sig { returns(T.nilable(Sentdm::APIMeta)) }
|
|
27
|
-
attr_reader :meta
|
|
28
|
-
|
|
29
|
-
sig { params(meta: Sentdm::APIMeta::OrHash).void }
|
|
30
|
-
attr_writer :meta
|
|
31
|
-
|
|
32
|
-
# Indicates whether the request was successful
|
|
33
|
-
sig { returns(T.nilable(T::Boolean)) }
|
|
34
|
-
attr_reader :success
|
|
35
|
-
|
|
36
|
-
sig { params(success: T::Boolean).void }
|
|
37
|
-
attr_writer :success
|
|
38
|
-
|
|
39
|
-
# Standard API response envelope for all v3 endpoints
|
|
40
|
-
sig do
|
|
41
|
-
params(
|
|
42
|
-
data: T.nilable(Sentdm::Contact::OrHash),
|
|
43
|
-
error: T.nilable(Sentdm::APIError::OrHash),
|
|
44
|
-
meta: Sentdm::APIMeta::OrHash,
|
|
45
|
-
success: T::Boolean
|
|
46
|
-
).returns(T.attached_class)
|
|
47
|
-
end
|
|
48
|
-
def self.new(
|
|
49
|
-
# The response data (null if error)
|
|
50
|
-
data: nil,
|
|
51
|
-
# Error details (null if successful)
|
|
52
|
-
error: nil,
|
|
53
|
-
# Metadata about the request and response
|
|
54
|
-
meta: nil,
|
|
55
|
-
# Indicates whether the request was successful
|
|
56
|
-
success: nil
|
|
57
|
-
)
|
|
58
|
-
end
|
|
59
|
-
|
|
60
|
-
sig do
|
|
61
|
-
override.returns(
|
|
62
|
-
{
|
|
63
|
-
data: T.nilable(Sentdm::Contact),
|
|
64
|
-
error: T.nilable(Sentdm::APIError),
|
|
65
|
-
meta: Sentdm::APIMeta,
|
|
66
|
-
success: T::Boolean
|
|
67
|
-
}
|
|
68
|
-
)
|
|
69
|
-
end
|
|
70
|
-
def to_hash
|
|
71
|
-
end
|
|
72
|
-
end
|
|
73
|
-
end
|
|
74
|
-
end
|