telnyx 5.60.0 → 5.62.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 +37 -0
- data/README.md +1 -1
- data/lib/telnyx/client.rb +10 -5
- data/lib/telnyx/errors.rb +0 -10
- data/lib/telnyx/lib/webhook_verification.rb +172 -0
- data/lib/telnyx/models/ai/assistants/{tag_delete_params.rb → tag_add_params.rb} +2 -2
- data/lib/telnyx/models/ai/assistants/{tag_delete_response.rb → tag_add_response.rb} +2 -2
- data/lib/telnyx/models/ai/assistants/{tag_create_params.rb → tag_remove_params.rb} +2 -2
- data/lib/telnyx/models/ai/assistants/{tag_create_response.rb → tag_remove_response.rb} +2 -2
- data/lib/telnyx/models/call_cost_webhook_event.rb +242 -0
- data/lib/telnyx/models/calls/action_start_noise_suppression_params.rb +135 -8
- data/lib/telnyx/models/text_to_speech_generate_params.rb +3 -3
- data/lib/telnyx/models/unsafe_unwrap_webhook_event.rb +3 -1
- data/lib/telnyx/models/unwrap_webhook_event.rb +3 -1
- data/lib/telnyx/models/voice_clone_create_from_design_params.rb +27 -6
- data/lib/telnyx/models/voice_clone_create_from_upload_params.rb +23 -2
- data/lib/telnyx/models/voice_clone_create_params.rb +79 -0
- data/lib/telnyx/models/voice_clone_create_response.rb +19 -0
- data/lib/telnyx/models/voice_clone_data.rb +41 -1
- data/lib/telnyx/models/voice_clone_list_params.rb +22 -1
- data/lib/telnyx/models/voice_design_create_params.rb +24 -1
- data/lib/telnyx/models/voice_design_data.rb +45 -1
- data/lib/telnyx/models/voice_design_list_response.rb +32 -1
- data/lib/telnyx/models/{voice_design_update_params.rb → voice_design_rename_params.rb} +2 -2
- data/lib/telnyx/models/{voice_design_update_response.rb → voice_design_rename_response.rb} +42 -11
- data/lib/telnyx/models/whatsapp/business_accounts/{phone_number_create_verification_params.rb → phone_number_initialize_verification_params.rb} +5 -5
- data/lib/telnyx/models/whatsapp/template_create_params.rb +530 -0
- data/lib/telnyx/models/whatsapp/{message_template_create_response.rb → template_create_response.rb} +2 -2
- data/lib/telnyx/models/whatsapp/{message_template_list_params.rb → template_list_params.rb} +5 -5
- data/lib/telnyx/models/whatsapp_message_template_delete_params.rb +20 -0
- data/lib/telnyx/models/whatsapp_message_template_retrieve_params.rb +20 -0
- data/lib/telnyx/models/whatsapp_message_template_retrieve_response.rb +16 -0
- data/lib/telnyx/models/whatsapp_message_template_update_params.rb +504 -0
- data/lib/telnyx/models/whatsapp_message_template_update_response.rb +16 -0
- data/lib/telnyx/models/whatsapp_template_data.rb +10 -3
- data/lib/telnyx/models/x402/{credit_account_create_payment_quote_params.rb → credit_account_create_quote_params.rb} +2 -2
- data/lib/telnyx/models/x402/{credit_account_create_payment_quote_response.rb → credit_account_create_quote_response.rb} +31 -32
- data/lib/telnyx/models/x402/{credit_account_settle_payment_params.rb → credit_account_settle_params.rb} +3 -3
- data/lib/telnyx/models/x402/{credit_account_settle_payment_response.rb → credit_account_settle_response.rb} +14 -15
- data/lib/telnyx/models.rb +12 -4
- data/lib/telnyx/resources/ai/assistants/tags.rb +28 -28
- data/lib/telnyx/resources/calls/actions.rb +1 -1
- data/lib/telnyx/resources/voice_clones.rb +38 -31
- data/lib/telnyx/resources/voice_designs.rb +27 -25
- data/lib/telnyx/resources/webhooks.rb +10 -183
- data/lib/telnyx/resources/whatsapp/business_accounts/phone_numbers.rb +5 -5
- data/lib/telnyx/resources/whatsapp/phone_numbers/profile.rb +0 -4
- data/lib/telnyx/resources/whatsapp/templates.rb +91 -0
- data/lib/telnyx/resources/whatsapp.rb +3 -3
- data/lib/telnyx/resources/whatsapp_message_templates.rb +81 -0
- data/lib/telnyx/resources/x402/credit_account.rb +13 -13
- data/lib/telnyx/version.rb +1 -1
- data/lib/telnyx.rb +25 -24
- data/rbi/telnyx/client.rbi +8 -4
- data/rbi/telnyx/models/ai/assistants/{tag_create_params.rbi → tag_add_params.rbi} +2 -2
- data/rbi/telnyx/models/ai/assistants/{tag_delete_response.rbi → tag_add_response.rbi} +2 -2
- data/rbi/telnyx/models/ai/assistants/{tag_delete_params.rbi → tag_remove_params.rbi} +2 -2
- data/rbi/telnyx/models/ai/assistants/{tag_create_response.rbi → tag_remove_response.rbi} +2 -2
- data/rbi/telnyx/models/call_cost_webhook_event.rbi +485 -0
- data/rbi/telnyx/models/calls/action_start_noise_suppression_params.rbi +338 -12
- data/rbi/telnyx/models/text_to_speech_generate_params.rbi +2 -1
- data/rbi/telnyx/models/unsafe_unwrap_webhook_event.rbi +1 -0
- data/rbi/telnyx/models/unwrap_webhook_event.rbi +1 -0
- data/rbi/telnyx/models/voice_clone_create_from_design_params.rbi +51 -0
- data/rbi/telnyx/models/voice_clone_create_from_upload_params.rbi +67 -2
- data/rbi/telnyx/models/voice_clone_create_params.rbi +142 -0
- data/rbi/telnyx/models/voice_clone_create_response.rbi +36 -0
- data/rbi/telnyx/models/voice_clone_data.rbi +57 -0
- data/rbi/telnyx/models/voice_clone_list_params.rbi +62 -0
- data/rbi/telnyx/models/voice_design_create_params.rbi +60 -0
- data/rbi/telnyx/models/voice_design_data.rbi +59 -0
- data/rbi/telnyx/models/voice_design_list_response.rbi +73 -0
- data/rbi/telnyx/models/{voice_design_update_params.rbi → voice_design_rename_params.rbi} +2 -2
- data/rbi/telnyx/models/{voice_design_update_response.rbi → voice_design_rename_response.rbi} +90 -14
- data/rbi/telnyx/models/whatsapp/business_accounts/{phone_number_create_verification_params.rbi → phone_number_initialize_verification_params.rbi} +10 -10
- data/rbi/telnyx/models/whatsapp/template_create_params.rbi +1177 -0
- data/rbi/telnyx/models/whatsapp/{message_template_create_response.rbi → template_create_response.rbi} +2 -2
- data/rbi/telnyx/models/whatsapp/{message_template_list_params.rbi → template_list_params.rbi} +11 -11
- data/rbi/telnyx/models/whatsapp_message_template_delete_params.rbi +38 -0
- data/rbi/telnyx/models/whatsapp_message_template_retrieve_params.rbi +38 -0
- data/rbi/telnyx/models/whatsapp_message_template_retrieve_response.rbi +33 -0
- data/rbi/telnyx/models/whatsapp_message_template_update_params.rbi +1178 -0
- data/rbi/telnyx/models/whatsapp_message_template_update_response.rbi +33 -0
- data/rbi/telnyx/models/whatsapp_template_data.rbi +10 -2
- data/rbi/telnyx/models/x402/{credit_account_create_payment_quote_params.rbi → credit_account_create_quote_params.rbi} +2 -2
- data/rbi/telnyx/models/x402/{credit_account_create_payment_quote_response.rbi → credit_account_create_quote_response.rbi} +41 -42
- data/rbi/telnyx/models/x402/{credit_account_settle_payment_params.rbi → credit_account_settle_params.rbi} +2 -2
- data/rbi/telnyx/models/x402/{credit_account_settle_payment_response.rbi → credit_account_settle_response.rbi} +21 -26
- data/rbi/telnyx/models.rbi +29 -3
- data/rbi/telnyx/resources/ai/assistants/tags.rbi +13 -13
- data/rbi/telnyx/resources/calls/actions.rbi +4 -3
- data/rbi/telnyx/resources/voice_clones.rbi +36 -25
- data/rbi/telnyx/resources/voice_designs.rbi +21 -17
- data/rbi/telnyx/resources/webhooks.rbi +12 -2
- data/rbi/telnyx/resources/whatsapp/business_accounts/phone_numbers.rbi +2 -2
- data/rbi/telnyx/resources/whatsapp/phone_numbers/profile.rbi +0 -5
- data/rbi/telnyx/resources/whatsapp/templates.rbi +85 -0
- data/rbi/telnyx/resources/whatsapp.rbi +2 -2
- data/rbi/telnyx/resources/whatsapp_message_templates.rbi +67 -0
- data/rbi/telnyx/resources/x402/credit_account.rbi +4 -6
- data/sig/telnyx/client.rbs +4 -2
- data/sig/telnyx/models/ai/assistants/{tag_delete_params.rbs → tag_add_params.rbs} +2 -2
- data/sig/telnyx/models/ai/assistants/{tag_delete_response.rbs → tag_add_response.rbs} +2 -2
- data/sig/telnyx/models/ai/assistants/{tag_create_params.rbs → tag_remove_params.rbs} +2 -2
- data/sig/telnyx/models/ai/assistants/{tag_create_response.rbs → tag_remove_response.rbs} +2 -2
- data/sig/telnyx/models/call_cost_webhook_event.rbs +235 -0
- data/sig/telnyx/models/calls/action_start_noise_suppression_params.rbs +124 -4
- data/sig/telnyx/models/unsafe_unwrap_webhook_event.rbs +1 -0
- data/sig/telnyx/models/unwrap_webhook_event.rbs +1 -0
- data/sig/telnyx/models/voice_clone_create_from_design_params.rbs +23 -1
- data/sig/telnyx/models/voice_clone_create_from_upload_params.rbs +22 -0
- data/sig/telnyx/models/voice_clone_create_params.rbs +75 -0
- data/sig/telnyx/models/voice_clone_create_response.rbs +15 -0
- data/sig/telnyx/models/voice_clone_data.rbs +34 -0
- data/sig/telnyx/models/voice_clone_list_params.rbs +22 -0
- data/sig/telnyx/models/voice_design_create_params.rbs +22 -0
- data/sig/telnyx/models/voice_design_data.rbs +30 -0
- data/sig/telnyx/models/voice_design_list_response.rbs +25 -0
- data/sig/telnyx/models/{voice_design_update_params.rbs → voice_design_rename_params.rbs} +2 -2
- data/sig/telnyx/models/voice_design_rename_response.rbs +104 -0
- data/sig/telnyx/models/whatsapp/business_accounts/{phone_number_create_verification_params.rbs → phone_number_initialize_verification_params.rbs} +9 -9
- data/sig/telnyx/models/whatsapp/template_create_params.rbs +479 -0
- data/sig/telnyx/models/whatsapp/{message_template_update_response.rbs → template_create_response.rbs} +2 -3
- data/sig/telnyx/models/whatsapp/{message_template_list_params.rbs → template_list_params.rbs} +9 -9
- data/sig/telnyx/models/whatsapp_message_template_delete_params.rbs +20 -0
- data/sig/telnyx/models/whatsapp_message_template_retrieve_params.rbs +20 -0
- data/sig/telnyx/models/whatsapp_message_template_retrieve_response.rbs +16 -0
- data/sig/telnyx/models/whatsapp_message_template_update_params.rbs +473 -0
- data/sig/telnyx/models/whatsapp_message_template_update_response.rbs +16 -0
- data/sig/telnyx/models/x402/{credit_account_create_payment_quote_params.rbs → credit_account_create_quote_params.rbs} +2 -2
- data/sig/telnyx/models/x402/{credit_account_create_payment_quote_response.rbs → credit_account_create_quote_response.rbs} +46 -48
- data/sig/telnyx/models/x402/{credit_account_settle_payment_params.rbs → credit_account_settle_params.rbs} +2 -2
- data/sig/telnyx/models/x402/{credit_account_settle_payment_response.rbs → credit_account_settle_response.rbs} +22 -22
- data/sig/telnyx/models.rbs +12 -4
- data/sig/telnyx/resources/ai/assistants/tags.rbs +8 -8
- data/sig/telnyx/resources/voice_clones.rbs +11 -8
- data/sig/telnyx/resources/voice_designs.rbs +7 -6
- data/sig/telnyx/resources/webhooks.rbs +5 -1
- data/sig/telnyx/resources/whatsapp/business_accounts/phone_numbers.rbs +2 -2
- data/sig/telnyx/resources/whatsapp/phone_numbers/profile.rbs +0 -2
- data/sig/telnyx/resources/whatsapp/templates.rbs +28 -0
- data/sig/telnyx/resources/whatsapp.rbs +1 -1
- data/sig/telnyx/resources/whatsapp_message_templates.rbs +21 -0
- data/sig/telnyx/resources/x402/credit_account.rbs +4 -4
- metadata +75 -65
- data/lib/telnyx/models/whatsapp/message_template_create_params.rb +0 -58
- data/lib/telnyx/models/whatsapp/message_template_delete_params.rb +0 -22
- data/lib/telnyx/models/whatsapp/message_template_retrieve_params.rb +0 -22
- data/lib/telnyx/models/whatsapp/message_template_retrieve_response.rb +0 -18
- data/lib/telnyx/models/whatsapp/message_template_update_params.rb +0 -46
- data/lib/telnyx/models/whatsapp/message_template_update_response.rb +0 -18
- data/lib/telnyx/resources/whatsapp/message_templates.rb +0 -149
- data/lib/telnyx/resources/whatsapp/phone_numbers/profile/models.rb +0 -20
- data/rbi/telnyx/models/whatsapp/message_template_create_params.rbi +0 -115
- data/rbi/telnyx/models/whatsapp/message_template_delete_params.rbi +0 -40
- data/rbi/telnyx/models/whatsapp/message_template_retrieve_params.rbi +0 -40
- data/rbi/telnyx/models/whatsapp/message_template_retrieve_response.rbi +0 -35
- data/rbi/telnyx/models/whatsapp/message_template_update_params.rbi +0 -111
- data/rbi/telnyx/models/whatsapp/message_template_update_response.rbi +0 -35
- data/rbi/telnyx/resources/whatsapp/message_templates.rbi +0 -116
- data/rbi/telnyx/resources/whatsapp/phone_numbers/profile/models.rbi +0 -18
- data/sig/telnyx/models/voice_design_update_response.rbs +0 -79
- data/sig/telnyx/models/whatsapp/message_template_create_params.rbs +0 -60
- data/sig/telnyx/models/whatsapp/message_template_create_response.rbs +0 -20
- data/sig/telnyx/models/whatsapp/message_template_delete_params.rbs +0 -22
- data/sig/telnyx/models/whatsapp/message_template_retrieve_params.rbs +0 -22
- data/sig/telnyx/models/whatsapp/message_template_retrieve_response.rbs +0 -20
- data/sig/telnyx/models/whatsapp/message_template_update_params.rbs +0 -58
- data/sig/telnyx/resources/whatsapp/message_templates.rbs +0 -42
- data/sig/telnyx/resources/whatsapp/phone_numbers/profile/models.rbs +0 -13
|
@@ -0,0 +1,1177 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Telnyx
|
|
4
|
+
module Models
|
|
5
|
+
module Whatsapp
|
|
6
|
+
class TemplateCreateParams < Telnyx::Internal::Type::BaseModel
|
|
7
|
+
extend Telnyx::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Telnyx::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
OrHash =
|
|
11
|
+
T.type_alias do
|
|
12
|
+
T.any(
|
|
13
|
+
Telnyx::Whatsapp::TemplateCreateParams,
|
|
14
|
+
Telnyx::Internal::AnyHash
|
|
15
|
+
)
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
# Template category: AUTHENTICATION, UTILITY, or MARKETING.
|
|
19
|
+
sig do
|
|
20
|
+
returns(Telnyx::Whatsapp::TemplateCreateParams::Category::OrSymbol)
|
|
21
|
+
end
|
|
22
|
+
attr_accessor :category
|
|
23
|
+
|
|
24
|
+
# Template components defining message structure. Passed through to Meta Graph
|
|
25
|
+
# API. Templates with variables must include example values. Supports HEADER,
|
|
26
|
+
# BODY, FOOTER, BUTTONS, CAROUSEL and any future Meta component types.
|
|
27
|
+
sig do
|
|
28
|
+
returns(
|
|
29
|
+
T::Array[
|
|
30
|
+
T.any(
|
|
31
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent,
|
|
32
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent,
|
|
33
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent,
|
|
34
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent,
|
|
35
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent
|
|
36
|
+
)
|
|
37
|
+
]
|
|
38
|
+
)
|
|
39
|
+
end
|
|
40
|
+
attr_accessor :components
|
|
41
|
+
|
|
42
|
+
# Template language code (e.g. en_US, es, pt_BR).
|
|
43
|
+
sig { returns(String) }
|
|
44
|
+
attr_accessor :language
|
|
45
|
+
|
|
46
|
+
# Template name. Lowercase letters, numbers, and underscores only.
|
|
47
|
+
sig { returns(String) }
|
|
48
|
+
attr_accessor :name
|
|
49
|
+
|
|
50
|
+
# The WhatsApp Business Account ID.
|
|
51
|
+
sig { returns(String) }
|
|
52
|
+
attr_accessor :waba_id
|
|
53
|
+
|
|
54
|
+
sig do
|
|
55
|
+
params(
|
|
56
|
+
category:
|
|
57
|
+
Telnyx::Whatsapp::TemplateCreateParams::Category::OrSymbol,
|
|
58
|
+
components:
|
|
59
|
+
T::Array[
|
|
60
|
+
T.any(
|
|
61
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::OrHash,
|
|
62
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::OrHash,
|
|
63
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::OrHash,
|
|
64
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::OrHash,
|
|
65
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::OrHash
|
|
66
|
+
)
|
|
67
|
+
],
|
|
68
|
+
language: String,
|
|
69
|
+
name: String,
|
|
70
|
+
waba_id: String,
|
|
71
|
+
request_options: Telnyx::RequestOptions::OrHash
|
|
72
|
+
).returns(T.attached_class)
|
|
73
|
+
end
|
|
74
|
+
def self.new(
|
|
75
|
+
# Template category: AUTHENTICATION, UTILITY, or MARKETING.
|
|
76
|
+
category:,
|
|
77
|
+
# Template components defining message structure. Passed through to Meta Graph
|
|
78
|
+
# API. Templates with variables must include example values. Supports HEADER,
|
|
79
|
+
# BODY, FOOTER, BUTTONS, CAROUSEL and any future Meta component types.
|
|
80
|
+
components:,
|
|
81
|
+
# Template language code (e.g. en_US, es, pt_BR).
|
|
82
|
+
language:,
|
|
83
|
+
# Template name. Lowercase letters, numbers, and underscores only.
|
|
84
|
+
name:,
|
|
85
|
+
# The WhatsApp Business Account ID.
|
|
86
|
+
waba_id:,
|
|
87
|
+
request_options: {}
|
|
88
|
+
)
|
|
89
|
+
end
|
|
90
|
+
|
|
91
|
+
sig do
|
|
92
|
+
override.returns(
|
|
93
|
+
{
|
|
94
|
+
category:
|
|
95
|
+
Telnyx::Whatsapp::TemplateCreateParams::Category::OrSymbol,
|
|
96
|
+
components:
|
|
97
|
+
T::Array[
|
|
98
|
+
T.any(
|
|
99
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent,
|
|
100
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent,
|
|
101
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent,
|
|
102
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent,
|
|
103
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent
|
|
104
|
+
)
|
|
105
|
+
],
|
|
106
|
+
language: String,
|
|
107
|
+
name: String,
|
|
108
|
+
waba_id: String,
|
|
109
|
+
request_options: Telnyx::RequestOptions
|
|
110
|
+
}
|
|
111
|
+
)
|
|
112
|
+
end
|
|
113
|
+
def to_hash
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
# Template category: AUTHENTICATION, UTILITY, or MARKETING.
|
|
117
|
+
module Category
|
|
118
|
+
extend Telnyx::Internal::Type::Enum
|
|
119
|
+
|
|
120
|
+
TaggedSymbol =
|
|
121
|
+
T.type_alias do
|
|
122
|
+
T.all(Symbol, Telnyx::Whatsapp::TemplateCreateParams::Category)
|
|
123
|
+
end
|
|
124
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
125
|
+
|
|
126
|
+
MARKETING =
|
|
127
|
+
T.let(
|
|
128
|
+
:MARKETING,
|
|
129
|
+
Telnyx::Whatsapp::TemplateCreateParams::Category::TaggedSymbol
|
|
130
|
+
)
|
|
131
|
+
UTILITY =
|
|
132
|
+
T.let(
|
|
133
|
+
:UTILITY,
|
|
134
|
+
Telnyx::Whatsapp::TemplateCreateParams::Category::TaggedSymbol
|
|
135
|
+
)
|
|
136
|
+
AUTHENTICATION =
|
|
137
|
+
T.let(
|
|
138
|
+
:AUTHENTICATION,
|
|
139
|
+
Telnyx::Whatsapp::TemplateCreateParams::Category::TaggedSymbol
|
|
140
|
+
)
|
|
141
|
+
|
|
142
|
+
sig do
|
|
143
|
+
override.returns(
|
|
144
|
+
T::Array[
|
|
145
|
+
Telnyx::Whatsapp::TemplateCreateParams::Category::TaggedSymbol
|
|
146
|
+
]
|
|
147
|
+
)
|
|
148
|
+
end
|
|
149
|
+
def self.values
|
|
150
|
+
end
|
|
151
|
+
end
|
|
152
|
+
|
|
153
|
+
# A template component. Additional Meta component types not listed here are also
|
|
154
|
+
# accepted.
|
|
155
|
+
module Component
|
|
156
|
+
extend Telnyx::Internal::Type::Union
|
|
157
|
+
|
|
158
|
+
Variants =
|
|
159
|
+
T.type_alias do
|
|
160
|
+
T.any(
|
|
161
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent,
|
|
162
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent,
|
|
163
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent,
|
|
164
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent,
|
|
165
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent
|
|
166
|
+
)
|
|
167
|
+
end
|
|
168
|
+
|
|
169
|
+
class WhatsappTemplateHeaderComponent < Telnyx::Internal::Type::BaseModel
|
|
170
|
+
OrHash =
|
|
171
|
+
T.type_alias do
|
|
172
|
+
T.any(
|
|
173
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent,
|
|
174
|
+
Telnyx::Internal::AnyHash
|
|
175
|
+
)
|
|
176
|
+
end
|
|
177
|
+
|
|
178
|
+
# Header format type: TEXT (supports one variable), IMAGE, VIDEO, DOCUMENT, or
|
|
179
|
+
# LOCATION.
|
|
180
|
+
sig do
|
|
181
|
+
returns(
|
|
182
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::OrSymbol
|
|
183
|
+
)
|
|
184
|
+
end
|
|
185
|
+
attr_accessor :format_
|
|
186
|
+
|
|
187
|
+
sig do
|
|
188
|
+
returns(
|
|
189
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type::OrSymbol
|
|
190
|
+
)
|
|
191
|
+
end
|
|
192
|
+
attr_accessor :type
|
|
193
|
+
|
|
194
|
+
# Sample values for header variables.
|
|
195
|
+
sig do
|
|
196
|
+
returns(
|
|
197
|
+
T.nilable(
|
|
198
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Example
|
|
199
|
+
)
|
|
200
|
+
)
|
|
201
|
+
end
|
|
202
|
+
attr_reader :example
|
|
203
|
+
|
|
204
|
+
sig do
|
|
205
|
+
params(
|
|
206
|
+
example:
|
|
207
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Example::OrHash
|
|
208
|
+
).void
|
|
209
|
+
end
|
|
210
|
+
attr_writer :example
|
|
211
|
+
|
|
212
|
+
# Header text. Required when format is TEXT. Supports one variable ({{1}}).
|
|
213
|
+
# Variables cannot be at the start or end.
|
|
214
|
+
sig { returns(T.nilable(String)) }
|
|
215
|
+
attr_reader :text
|
|
216
|
+
|
|
217
|
+
sig { params(text: String).void }
|
|
218
|
+
attr_writer :text
|
|
219
|
+
|
|
220
|
+
# Optional header displayed at the top of the message.
|
|
221
|
+
sig do
|
|
222
|
+
params(
|
|
223
|
+
format_:
|
|
224
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::OrSymbol,
|
|
225
|
+
type:
|
|
226
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type::OrSymbol,
|
|
227
|
+
example:
|
|
228
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Example::OrHash,
|
|
229
|
+
text: String
|
|
230
|
+
).returns(T.attached_class)
|
|
231
|
+
end
|
|
232
|
+
def self.new(
|
|
233
|
+
# Header format type: TEXT (supports one variable), IMAGE, VIDEO, DOCUMENT, or
|
|
234
|
+
# LOCATION.
|
|
235
|
+
format_:,
|
|
236
|
+
type:,
|
|
237
|
+
# Sample values for header variables.
|
|
238
|
+
example: nil,
|
|
239
|
+
# Header text. Required when format is TEXT. Supports one variable ({{1}}).
|
|
240
|
+
# Variables cannot be at the start or end.
|
|
241
|
+
text: nil
|
|
242
|
+
)
|
|
243
|
+
end
|
|
244
|
+
|
|
245
|
+
sig do
|
|
246
|
+
override.returns(
|
|
247
|
+
{
|
|
248
|
+
format_:
|
|
249
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::OrSymbol,
|
|
250
|
+
type:
|
|
251
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type::OrSymbol,
|
|
252
|
+
example:
|
|
253
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Example,
|
|
254
|
+
text: String
|
|
255
|
+
}
|
|
256
|
+
)
|
|
257
|
+
end
|
|
258
|
+
def to_hash
|
|
259
|
+
end
|
|
260
|
+
|
|
261
|
+
# Header format type: TEXT (supports one variable), IMAGE, VIDEO, DOCUMENT, or
|
|
262
|
+
# LOCATION.
|
|
263
|
+
module Format
|
|
264
|
+
extend Telnyx::Internal::Type::Enum
|
|
265
|
+
|
|
266
|
+
TaggedSymbol =
|
|
267
|
+
T.type_alias do
|
|
268
|
+
T.all(
|
|
269
|
+
Symbol,
|
|
270
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format
|
|
271
|
+
)
|
|
272
|
+
end
|
|
273
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
274
|
+
|
|
275
|
+
TEXT =
|
|
276
|
+
T.let(
|
|
277
|
+
:TEXT,
|
|
278
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::TaggedSymbol
|
|
279
|
+
)
|
|
280
|
+
IMAGE =
|
|
281
|
+
T.let(
|
|
282
|
+
:IMAGE,
|
|
283
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::TaggedSymbol
|
|
284
|
+
)
|
|
285
|
+
VIDEO =
|
|
286
|
+
T.let(
|
|
287
|
+
:VIDEO,
|
|
288
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::TaggedSymbol
|
|
289
|
+
)
|
|
290
|
+
DOCUMENT =
|
|
291
|
+
T.let(
|
|
292
|
+
:DOCUMENT,
|
|
293
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::TaggedSymbol
|
|
294
|
+
)
|
|
295
|
+
LOCATION =
|
|
296
|
+
T.let(
|
|
297
|
+
:LOCATION,
|
|
298
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::TaggedSymbol
|
|
299
|
+
)
|
|
300
|
+
|
|
301
|
+
sig do
|
|
302
|
+
override.returns(
|
|
303
|
+
T::Array[
|
|
304
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format::TaggedSymbol
|
|
305
|
+
]
|
|
306
|
+
)
|
|
307
|
+
end
|
|
308
|
+
def self.values
|
|
309
|
+
end
|
|
310
|
+
end
|
|
311
|
+
|
|
312
|
+
module Type
|
|
313
|
+
extend Telnyx::Internal::Type::Enum
|
|
314
|
+
|
|
315
|
+
TaggedSymbol =
|
|
316
|
+
T.type_alias do
|
|
317
|
+
T.all(
|
|
318
|
+
Symbol,
|
|
319
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type
|
|
320
|
+
)
|
|
321
|
+
end
|
|
322
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
323
|
+
|
|
324
|
+
HEADER =
|
|
325
|
+
T.let(
|
|
326
|
+
:HEADER,
|
|
327
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type::TaggedSymbol
|
|
328
|
+
)
|
|
329
|
+
|
|
330
|
+
sig do
|
|
331
|
+
override.returns(
|
|
332
|
+
T::Array[
|
|
333
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type::TaggedSymbol
|
|
334
|
+
]
|
|
335
|
+
)
|
|
336
|
+
end
|
|
337
|
+
def self.values
|
|
338
|
+
end
|
|
339
|
+
end
|
|
340
|
+
|
|
341
|
+
class Example < Telnyx::Internal::Type::BaseModel
|
|
342
|
+
OrHash =
|
|
343
|
+
T.type_alias do
|
|
344
|
+
T.any(
|
|
345
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Example,
|
|
346
|
+
Telnyx::Internal::AnyHash
|
|
347
|
+
)
|
|
348
|
+
end
|
|
349
|
+
|
|
350
|
+
# Media handle for IMAGE, VIDEO, or DOCUMENT headers.
|
|
351
|
+
sig { returns(T.nilable(T::Array[String])) }
|
|
352
|
+
attr_reader :header_handle
|
|
353
|
+
|
|
354
|
+
sig { params(header_handle: T::Array[String]).void }
|
|
355
|
+
attr_writer :header_handle
|
|
356
|
+
|
|
357
|
+
# Sample values for text header variables.
|
|
358
|
+
sig { returns(T.nilable(T::Array[String])) }
|
|
359
|
+
attr_reader :header_text
|
|
360
|
+
|
|
361
|
+
sig { params(header_text: T::Array[String]).void }
|
|
362
|
+
attr_writer :header_text
|
|
363
|
+
|
|
364
|
+
# Sample values for header variables.
|
|
365
|
+
sig do
|
|
366
|
+
params(
|
|
367
|
+
header_handle: T::Array[String],
|
|
368
|
+
header_text: T::Array[String]
|
|
369
|
+
).returns(T.attached_class)
|
|
370
|
+
end
|
|
371
|
+
def self.new(
|
|
372
|
+
# Media handle for IMAGE, VIDEO, or DOCUMENT headers.
|
|
373
|
+
header_handle: nil,
|
|
374
|
+
# Sample values for text header variables.
|
|
375
|
+
header_text: nil
|
|
376
|
+
)
|
|
377
|
+
end
|
|
378
|
+
|
|
379
|
+
sig do
|
|
380
|
+
override.returns(
|
|
381
|
+
{
|
|
382
|
+
header_handle: T::Array[String],
|
|
383
|
+
header_text: T::Array[String]
|
|
384
|
+
}
|
|
385
|
+
)
|
|
386
|
+
end
|
|
387
|
+
def to_hash
|
|
388
|
+
end
|
|
389
|
+
end
|
|
390
|
+
end
|
|
391
|
+
|
|
392
|
+
class WhatsappTemplateBodyComponent < Telnyx::Internal::Type::BaseModel
|
|
393
|
+
OrHash =
|
|
394
|
+
T.type_alias do
|
|
395
|
+
T.any(
|
|
396
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent,
|
|
397
|
+
Telnyx::Internal::AnyHash
|
|
398
|
+
)
|
|
399
|
+
end
|
|
400
|
+
|
|
401
|
+
sig do
|
|
402
|
+
returns(
|
|
403
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type::OrSymbol
|
|
404
|
+
)
|
|
405
|
+
end
|
|
406
|
+
attr_accessor :type
|
|
407
|
+
|
|
408
|
+
# Sample values for body variables. Required when body text contains parameters.
|
|
409
|
+
sig do
|
|
410
|
+
returns(
|
|
411
|
+
T.nilable(
|
|
412
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Example
|
|
413
|
+
)
|
|
414
|
+
)
|
|
415
|
+
end
|
|
416
|
+
attr_reader :example
|
|
417
|
+
|
|
418
|
+
sig do
|
|
419
|
+
params(
|
|
420
|
+
example:
|
|
421
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Example::OrHash
|
|
422
|
+
).void
|
|
423
|
+
end
|
|
424
|
+
attr_writer :example
|
|
425
|
+
|
|
426
|
+
# Body text content. Use {{1}}, {{2}}, etc. for variable placeholders. Required
|
|
427
|
+
# for MARKETING and UTILITY templates. Optional for AUTHENTICATION templates where
|
|
428
|
+
# Meta provides the built-in OTP body.
|
|
429
|
+
sig { returns(T.nilable(String)) }
|
|
430
|
+
attr_reader :text
|
|
431
|
+
|
|
432
|
+
sig { params(text: String).void }
|
|
433
|
+
attr_writer :text
|
|
434
|
+
|
|
435
|
+
# The main text content of the message. Supports multiple variable parameters
|
|
436
|
+
# ({{1}}, {{2}}, etc.). Variables cannot be at the start or end. Maximum 1024
|
|
437
|
+
# characters.
|
|
438
|
+
sig do
|
|
439
|
+
params(
|
|
440
|
+
type:
|
|
441
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type::OrSymbol,
|
|
442
|
+
example:
|
|
443
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Example::OrHash,
|
|
444
|
+
text: String
|
|
445
|
+
).returns(T.attached_class)
|
|
446
|
+
end
|
|
447
|
+
def self.new(
|
|
448
|
+
type:,
|
|
449
|
+
# Sample values for body variables. Required when body text contains parameters.
|
|
450
|
+
example: nil,
|
|
451
|
+
# Body text content. Use {{1}}, {{2}}, etc. for variable placeholders. Required
|
|
452
|
+
# for MARKETING and UTILITY templates. Optional for AUTHENTICATION templates where
|
|
453
|
+
# Meta provides the built-in OTP body.
|
|
454
|
+
text: nil
|
|
455
|
+
)
|
|
456
|
+
end
|
|
457
|
+
|
|
458
|
+
sig do
|
|
459
|
+
override.returns(
|
|
460
|
+
{
|
|
461
|
+
type:
|
|
462
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type::OrSymbol,
|
|
463
|
+
example:
|
|
464
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Example,
|
|
465
|
+
text: String
|
|
466
|
+
}
|
|
467
|
+
)
|
|
468
|
+
end
|
|
469
|
+
def to_hash
|
|
470
|
+
end
|
|
471
|
+
|
|
472
|
+
module Type
|
|
473
|
+
extend Telnyx::Internal::Type::Enum
|
|
474
|
+
|
|
475
|
+
TaggedSymbol =
|
|
476
|
+
T.type_alias do
|
|
477
|
+
T.all(
|
|
478
|
+
Symbol,
|
|
479
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type
|
|
480
|
+
)
|
|
481
|
+
end
|
|
482
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
483
|
+
|
|
484
|
+
BODY =
|
|
485
|
+
T.let(
|
|
486
|
+
:BODY,
|
|
487
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type::TaggedSymbol
|
|
488
|
+
)
|
|
489
|
+
|
|
490
|
+
sig do
|
|
491
|
+
override.returns(
|
|
492
|
+
T::Array[
|
|
493
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type::TaggedSymbol
|
|
494
|
+
]
|
|
495
|
+
)
|
|
496
|
+
end
|
|
497
|
+
def self.values
|
|
498
|
+
end
|
|
499
|
+
end
|
|
500
|
+
|
|
501
|
+
class Example < Telnyx::Internal::Type::BaseModel
|
|
502
|
+
OrHash =
|
|
503
|
+
T.type_alias do
|
|
504
|
+
T.any(
|
|
505
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Example,
|
|
506
|
+
Telnyx::Internal::AnyHash
|
|
507
|
+
)
|
|
508
|
+
end
|
|
509
|
+
|
|
510
|
+
# Array containing one array of sample values, one per variable in order.
|
|
511
|
+
sig { returns(T.nilable(T::Array[T::Array[String]])) }
|
|
512
|
+
attr_reader :body_text
|
|
513
|
+
|
|
514
|
+
sig { params(body_text: T::Array[T::Array[String]]).void }
|
|
515
|
+
attr_writer :body_text
|
|
516
|
+
|
|
517
|
+
# Sample values for body variables. Required when body text contains parameters.
|
|
518
|
+
sig do
|
|
519
|
+
params(body_text: T::Array[T::Array[String]]).returns(
|
|
520
|
+
T.attached_class
|
|
521
|
+
)
|
|
522
|
+
end
|
|
523
|
+
def self.new(
|
|
524
|
+
# Array containing one array of sample values, one per variable in order.
|
|
525
|
+
body_text: nil
|
|
526
|
+
)
|
|
527
|
+
end
|
|
528
|
+
|
|
529
|
+
sig do
|
|
530
|
+
override.returns({ body_text: T::Array[T::Array[String]] })
|
|
531
|
+
end
|
|
532
|
+
def to_hash
|
|
533
|
+
end
|
|
534
|
+
end
|
|
535
|
+
end
|
|
536
|
+
|
|
537
|
+
class WhatsappTemplateFooterComponent < Telnyx::Internal::Type::BaseModel
|
|
538
|
+
OrHash =
|
|
539
|
+
T.type_alias do
|
|
540
|
+
T.any(
|
|
541
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent,
|
|
542
|
+
Telnyx::Internal::AnyHash
|
|
543
|
+
)
|
|
544
|
+
end
|
|
545
|
+
|
|
546
|
+
sig do
|
|
547
|
+
returns(
|
|
548
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type::OrSymbol
|
|
549
|
+
)
|
|
550
|
+
end
|
|
551
|
+
attr_accessor :type
|
|
552
|
+
|
|
553
|
+
# OTP code expiration time in minutes. Used in AUTHENTICATION template footers
|
|
554
|
+
# instead of free-form text.
|
|
555
|
+
sig { returns(T.nilable(Integer)) }
|
|
556
|
+
attr_reader :code_expiration_minutes
|
|
557
|
+
|
|
558
|
+
sig { params(code_expiration_minutes: Integer).void }
|
|
559
|
+
attr_writer :code_expiration_minutes
|
|
560
|
+
|
|
561
|
+
# Footer text. Maximum 60 characters. For non-authentication templates.
|
|
562
|
+
sig { returns(T.nilable(String)) }
|
|
563
|
+
attr_reader :text
|
|
564
|
+
|
|
565
|
+
sig { params(text: String).void }
|
|
566
|
+
attr_writer :text
|
|
567
|
+
|
|
568
|
+
# Optional footer displayed at the bottom of the message. Does not support
|
|
569
|
+
# variables.
|
|
570
|
+
sig do
|
|
571
|
+
params(
|
|
572
|
+
type:
|
|
573
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type::OrSymbol,
|
|
574
|
+
code_expiration_minutes: Integer,
|
|
575
|
+
text: String
|
|
576
|
+
).returns(T.attached_class)
|
|
577
|
+
end
|
|
578
|
+
def self.new(
|
|
579
|
+
type:,
|
|
580
|
+
# OTP code expiration time in minutes. Used in AUTHENTICATION template footers
|
|
581
|
+
# instead of free-form text.
|
|
582
|
+
code_expiration_minutes: nil,
|
|
583
|
+
# Footer text. Maximum 60 characters. For non-authentication templates.
|
|
584
|
+
text: nil
|
|
585
|
+
)
|
|
586
|
+
end
|
|
587
|
+
|
|
588
|
+
sig do
|
|
589
|
+
override.returns(
|
|
590
|
+
{
|
|
591
|
+
type:
|
|
592
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type::OrSymbol,
|
|
593
|
+
code_expiration_minutes: Integer,
|
|
594
|
+
text: String
|
|
595
|
+
}
|
|
596
|
+
)
|
|
597
|
+
end
|
|
598
|
+
def to_hash
|
|
599
|
+
end
|
|
600
|
+
|
|
601
|
+
module Type
|
|
602
|
+
extend Telnyx::Internal::Type::Enum
|
|
603
|
+
|
|
604
|
+
TaggedSymbol =
|
|
605
|
+
T.type_alias do
|
|
606
|
+
T.all(
|
|
607
|
+
Symbol,
|
|
608
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type
|
|
609
|
+
)
|
|
610
|
+
end
|
|
611
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
612
|
+
|
|
613
|
+
FOOTER =
|
|
614
|
+
T.let(
|
|
615
|
+
:FOOTER,
|
|
616
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type::TaggedSymbol
|
|
617
|
+
)
|
|
618
|
+
|
|
619
|
+
sig do
|
|
620
|
+
override.returns(
|
|
621
|
+
T::Array[
|
|
622
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type::TaggedSymbol
|
|
623
|
+
]
|
|
624
|
+
)
|
|
625
|
+
end
|
|
626
|
+
def self.values
|
|
627
|
+
end
|
|
628
|
+
end
|
|
629
|
+
end
|
|
630
|
+
|
|
631
|
+
class WhatsappTemplateButtonsComponent < Telnyx::Internal::Type::BaseModel
|
|
632
|
+
OrHash =
|
|
633
|
+
T.type_alias do
|
|
634
|
+
T.any(
|
|
635
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent,
|
|
636
|
+
Telnyx::Internal::AnyHash
|
|
637
|
+
)
|
|
638
|
+
end
|
|
639
|
+
|
|
640
|
+
# Array of button objects. Meta supports various combinations of button types.
|
|
641
|
+
sig do
|
|
642
|
+
returns(
|
|
643
|
+
T::Array[
|
|
644
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button
|
|
645
|
+
]
|
|
646
|
+
)
|
|
647
|
+
end
|
|
648
|
+
attr_accessor :buttons
|
|
649
|
+
|
|
650
|
+
sig do
|
|
651
|
+
returns(
|
|
652
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type::OrSymbol
|
|
653
|
+
)
|
|
654
|
+
end
|
|
655
|
+
attr_accessor :type
|
|
656
|
+
|
|
657
|
+
# Optional interactive buttons. Maximum 3 buttons per template.
|
|
658
|
+
sig do
|
|
659
|
+
params(
|
|
660
|
+
buttons:
|
|
661
|
+
T::Array[
|
|
662
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OrHash
|
|
663
|
+
],
|
|
664
|
+
type:
|
|
665
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type::OrSymbol
|
|
666
|
+
).returns(T.attached_class)
|
|
667
|
+
end
|
|
668
|
+
def self.new(
|
|
669
|
+
# Array of button objects. Meta supports various combinations of button types.
|
|
670
|
+
buttons:,
|
|
671
|
+
type:
|
|
672
|
+
)
|
|
673
|
+
end
|
|
674
|
+
|
|
675
|
+
sig do
|
|
676
|
+
override.returns(
|
|
677
|
+
{
|
|
678
|
+
buttons:
|
|
679
|
+
T::Array[
|
|
680
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button
|
|
681
|
+
],
|
|
682
|
+
type:
|
|
683
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type::OrSymbol
|
|
684
|
+
}
|
|
685
|
+
)
|
|
686
|
+
end
|
|
687
|
+
def to_hash
|
|
688
|
+
end
|
|
689
|
+
|
|
690
|
+
class Button < Telnyx::Internal::Type::BaseModel
|
|
691
|
+
OrHash =
|
|
692
|
+
T.type_alias do
|
|
693
|
+
T.any(
|
|
694
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button,
|
|
695
|
+
Telnyx::Internal::AnyHash
|
|
696
|
+
)
|
|
697
|
+
end
|
|
698
|
+
|
|
699
|
+
sig do
|
|
700
|
+
returns(
|
|
701
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::OrSymbol
|
|
702
|
+
)
|
|
703
|
+
end
|
|
704
|
+
attr_accessor :type
|
|
705
|
+
|
|
706
|
+
# Custom autofill button text for ONE_TAP OTP buttons.
|
|
707
|
+
sig { returns(T.nilable(String)) }
|
|
708
|
+
attr_reader :autofill_text
|
|
709
|
+
|
|
710
|
+
sig { params(autofill_text: String).void }
|
|
711
|
+
attr_writer :autofill_text
|
|
712
|
+
|
|
713
|
+
# Sample values for URL variable.
|
|
714
|
+
sig { returns(T.nilable(T::Array[String])) }
|
|
715
|
+
attr_reader :example
|
|
716
|
+
|
|
717
|
+
sig { params(example: T::Array[String]).void }
|
|
718
|
+
attr_writer :example
|
|
719
|
+
|
|
720
|
+
# Flow action type for FLOW-type buttons.
|
|
721
|
+
sig do
|
|
722
|
+
returns(
|
|
723
|
+
T.nilable(
|
|
724
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction::OrSymbol
|
|
725
|
+
)
|
|
726
|
+
)
|
|
727
|
+
end
|
|
728
|
+
attr_reader :flow_action
|
|
729
|
+
|
|
730
|
+
sig do
|
|
731
|
+
params(
|
|
732
|
+
flow_action:
|
|
733
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction::OrSymbol
|
|
734
|
+
).void
|
|
735
|
+
end
|
|
736
|
+
attr_writer :flow_action
|
|
737
|
+
|
|
738
|
+
# Flow ID for FLOW-type buttons.
|
|
739
|
+
sig { returns(T.nilable(String)) }
|
|
740
|
+
attr_reader :flow_id
|
|
741
|
+
|
|
742
|
+
sig { params(flow_id: String).void }
|
|
743
|
+
attr_writer :flow_id
|
|
744
|
+
|
|
745
|
+
# Target screen name for FLOW buttons with navigate action.
|
|
746
|
+
sig { returns(T.nilable(String)) }
|
|
747
|
+
attr_reader :navigate_screen
|
|
748
|
+
|
|
749
|
+
sig { params(navigate_screen: String).void }
|
|
750
|
+
attr_writer :navigate_screen
|
|
751
|
+
|
|
752
|
+
sig do
|
|
753
|
+
returns(
|
|
754
|
+
T.nilable(
|
|
755
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType::OrSymbol
|
|
756
|
+
)
|
|
757
|
+
)
|
|
758
|
+
end
|
|
759
|
+
attr_reader :otp_type
|
|
760
|
+
|
|
761
|
+
sig do
|
|
762
|
+
params(
|
|
763
|
+
otp_type:
|
|
764
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType::OrSymbol
|
|
765
|
+
).void
|
|
766
|
+
end
|
|
767
|
+
attr_writer :otp_type
|
|
768
|
+
|
|
769
|
+
# Android package name. Required for ONE_TAP OTP buttons.
|
|
770
|
+
sig { returns(T.nilable(String)) }
|
|
771
|
+
attr_reader :package_name
|
|
772
|
+
|
|
773
|
+
sig { params(package_name: String).void }
|
|
774
|
+
attr_writer :package_name
|
|
775
|
+
|
|
776
|
+
# Phone number in E.164 format.
|
|
777
|
+
sig { returns(T.nilable(String)) }
|
|
778
|
+
attr_reader :phone_number
|
|
779
|
+
|
|
780
|
+
sig { params(phone_number: String).void }
|
|
781
|
+
attr_writer :phone_number
|
|
782
|
+
|
|
783
|
+
# Android app signing key hash. Required for ONE_TAP OTP buttons.
|
|
784
|
+
sig { returns(T.nilable(String)) }
|
|
785
|
+
attr_reader :signature_hash
|
|
786
|
+
|
|
787
|
+
sig { params(signature_hash: String).void }
|
|
788
|
+
attr_writer :signature_hash
|
|
789
|
+
|
|
790
|
+
# Button label text. Maximum 25 characters. Required for URL, PHONE_NUMBER, and
|
|
791
|
+
# QUICK_REPLY buttons. Not required for OTP buttons (Meta supplies the label).
|
|
792
|
+
sig { returns(T.nilable(String)) }
|
|
793
|
+
attr_reader :text
|
|
794
|
+
|
|
795
|
+
sig { params(text: String).void }
|
|
796
|
+
attr_writer :text
|
|
797
|
+
|
|
798
|
+
# URL for URL-type buttons. Supports one variable ({{1}}).
|
|
799
|
+
sig { returns(T.nilable(String)) }
|
|
800
|
+
attr_reader :url
|
|
801
|
+
|
|
802
|
+
sig { params(url: String).void }
|
|
803
|
+
attr_writer :url
|
|
804
|
+
|
|
805
|
+
# Whether zero-tap terms have been accepted.
|
|
806
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
807
|
+
attr_reader :zero_tap_terms_accepted
|
|
808
|
+
|
|
809
|
+
sig { params(zero_tap_terms_accepted: T::Boolean).void }
|
|
810
|
+
attr_writer :zero_tap_terms_accepted
|
|
811
|
+
|
|
812
|
+
sig do
|
|
813
|
+
params(
|
|
814
|
+
type:
|
|
815
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::OrSymbol,
|
|
816
|
+
autofill_text: String,
|
|
817
|
+
example: T::Array[String],
|
|
818
|
+
flow_action:
|
|
819
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction::OrSymbol,
|
|
820
|
+
flow_id: String,
|
|
821
|
+
navigate_screen: String,
|
|
822
|
+
otp_type:
|
|
823
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType::OrSymbol,
|
|
824
|
+
package_name: String,
|
|
825
|
+
phone_number: String,
|
|
826
|
+
signature_hash: String,
|
|
827
|
+
text: String,
|
|
828
|
+
url: String,
|
|
829
|
+
zero_tap_terms_accepted: T::Boolean
|
|
830
|
+
).returns(T.attached_class)
|
|
831
|
+
end
|
|
832
|
+
def self.new(
|
|
833
|
+
type:,
|
|
834
|
+
# Custom autofill button text for ONE_TAP OTP buttons.
|
|
835
|
+
autofill_text: nil,
|
|
836
|
+
# Sample values for URL variable.
|
|
837
|
+
example: nil,
|
|
838
|
+
# Flow action type for FLOW-type buttons.
|
|
839
|
+
flow_action: nil,
|
|
840
|
+
# Flow ID for FLOW-type buttons.
|
|
841
|
+
flow_id: nil,
|
|
842
|
+
# Target screen name for FLOW buttons with navigate action.
|
|
843
|
+
navigate_screen: nil,
|
|
844
|
+
otp_type: nil,
|
|
845
|
+
# Android package name. Required for ONE_TAP OTP buttons.
|
|
846
|
+
package_name: nil,
|
|
847
|
+
# Phone number in E.164 format.
|
|
848
|
+
phone_number: nil,
|
|
849
|
+
# Android app signing key hash. Required for ONE_TAP OTP buttons.
|
|
850
|
+
signature_hash: nil,
|
|
851
|
+
# Button label text. Maximum 25 characters. Required for URL, PHONE_NUMBER, and
|
|
852
|
+
# QUICK_REPLY buttons. Not required for OTP buttons (Meta supplies the label).
|
|
853
|
+
text: nil,
|
|
854
|
+
# URL for URL-type buttons. Supports one variable ({{1}}).
|
|
855
|
+
url: nil,
|
|
856
|
+
# Whether zero-tap terms have been accepted.
|
|
857
|
+
zero_tap_terms_accepted: nil
|
|
858
|
+
)
|
|
859
|
+
end
|
|
860
|
+
|
|
861
|
+
sig do
|
|
862
|
+
override.returns(
|
|
863
|
+
{
|
|
864
|
+
type:
|
|
865
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::OrSymbol,
|
|
866
|
+
autofill_text: String,
|
|
867
|
+
example: T::Array[String],
|
|
868
|
+
flow_action:
|
|
869
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction::OrSymbol,
|
|
870
|
+
flow_id: String,
|
|
871
|
+
navigate_screen: String,
|
|
872
|
+
otp_type:
|
|
873
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType::OrSymbol,
|
|
874
|
+
package_name: String,
|
|
875
|
+
phone_number: String,
|
|
876
|
+
signature_hash: String,
|
|
877
|
+
text: String,
|
|
878
|
+
url: String,
|
|
879
|
+
zero_tap_terms_accepted: T::Boolean
|
|
880
|
+
}
|
|
881
|
+
)
|
|
882
|
+
end
|
|
883
|
+
def to_hash
|
|
884
|
+
end
|
|
885
|
+
|
|
886
|
+
module Type
|
|
887
|
+
extend Telnyx::Internal::Type::Enum
|
|
888
|
+
|
|
889
|
+
TaggedSymbol =
|
|
890
|
+
T.type_alias do
|
|
891
|
+
T.all(
|
|
892
|
+
Symbol,
|
|
893
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type
|
|
894
|
+
)
|
|
895
|
+
end
|
|
896
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
897
|
+
|
|
898
|
+
URL =
|
|
899
|
+
T.let(
|
|
900
|
+
:URL,
|
|
901
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::TaggedSymbol
|
|
902
|
+
)
|
|
903
|
+
PHONE_NUMBER =
|
|
904
|
+
T.let(
|
|
905
|
+
:PHONE_NUMBER,
|
|
906
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::TaggedSymbol
|
|
907
|
+
)
|
|
908
|
+
QUICK_REPLY =
|
|
909
|
+
T.let(
|
|
910
|
+
:QUICK_REPLY,
|
|
911
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::TaggedSymbol
|
|
912
|
+
)
|
|
913
|
+
OTP =
|
|
914
|
+
T.let(
|
|
915
|
+
:OTP,
|
|
916
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::TaggedSymbol
|
|
917
|
+
)
|
|
918
|
+
COPY_CODE =
|
|
919
|
+
T.let(
|
|
920
|
+
:COPY_CODE,
|
|
921
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::TaggedSymbol
|
|
922
|
+
)
|
|
923
|
+
FLOW =
|
|
924
|
+
T.let(
|
|
925
|
+
:FLOW,
|
|
926
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::TaggedSymbol
|
|
927
|
+
)
|
|
928
|
+
|
|
929
|
+
sig do
|
|
930
|
+
override.returns(
|
|
931
|
+
T::Array[
|
|
932
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type::TaggedSymbol
|
|
933
|
+
]
|
|
934
|
+
)
|
|
935
|
+
end
|
|
936
|
+
def self.values
|
|
937
|
+
end
|
|
938
|
+
end
|
|
939
|
+
|
|
940
|
+
# Flow action type for FLOW-type buttons.
|
|
941
|
+
module FlowAction
|
|
942
|
+
extend Telnyx::Internal::Type::Enum
|
|
943
|
+
|
|
944
|
+
TaggedSymbol =
|
|
945
|
+
T.type_alias do
|
|
946
|
+
T.all(
|
|
947
|
+
Symbol,
|
|
948
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction
|
|
949
|
+
)
|
|
950
|
+
end
|
|
951
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
952
|
+
|
|
953
|
+
NAVIGATE =
|
|
954
|
+
T.let(
|
|
955
|
+
:navigate,
|
|
956
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction::TaggedSymbol
|
|
957
|
+
)
|
|
958
|
+
DATA_EXCHANGE =
|
|
959
|
+
T.let(
|
|
960
|
+
:data_exchange,
|
|
961
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction::TaggedSymbol
|
|
962
|
+
)
|
|
963
|
+
|
|
964
|
+
sig do
|
|
965
|
+
override.returns(
|
|
966
|
+
T::Array[
|
|
967
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction::TaggedSymbol
|
|
968
|
+
]
|
|
969
|
+
)
|
|
970
|
+
end
|
|
971
|
+
def self.values
|
|
972
|
+
end
|
|
973
|
+
end
|
|
974
|
+
|
|
975
|
+
module OtpType
|
|
976
|
+
extend Telnyx::Internal::Type::Enum
|
|
977
|
+
|
|
978
|
+
TaggedSymbol =
|
|
979
|
+
T.type_alias do
|
|
980
|
+
T.all(
|
|
981
|
+
Symbol,
|
|
982
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType
|
|
983
|
+
)
|
|
984
|
+
end
|
|
985
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
986
|
+
|
|
987
|
+
COPY_CODE =
|
|
988
|
+
T.let(
|
|
989
|
+
:COPY_CODE,
|
|
990
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType::TaggedSymbol
|
|
991
|
+
)
|
|
992
|
+
ONE_TAP =
|
|
993
|
+
T.let(
|
|
994
|
+
:ONE_TAP,
|
|
995
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType::TaggedSymbol
|
|
996
|
+
)
|
|
997
|
+
|
|
998
|
+
sig do
|
|
999
|
+
override.returns(
|
|
1000
|
+
T::Array[
|
|
1001
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType::TaggedSymbol
|
|
1002
|
+
]
|
|
1003
|
+
)
|
|
1004
|
+
end
|
|
1005
|
+
def self.values
|
|
1006
|
+
end
|
|
1007
|
+
end
|
|
1008
|
+
end
|
|
1009
|
+
|
|
1010
|
+
module Type
|
|
1011
|
+
extend Telnyx::Internal::Type::Enum
|
|
1012
|
+
|
|
1013
|
+
TaggedSymbol =
|
|
1014
|
+
T.type_alias do
|
|
1015
|
+
T.all(
|
|
1016
|
+
Symbol,
|
|
1017
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type
|
|
1018
|
+
)
|
|
1019
|
+
end
|
|
1020
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1021
|
+
|
|
1022
|
+
BUTTONS =
|
|
1023
|
+
T.let(
|
|
1024
|
+
:BUTTONS,
|
|
1025
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type::TaggedSymbol
|
|
1026
|
+
)
|
|
1027
|
+
|
|
1028
|
+
sig do
|
|
1029
|
+
override.returns(
|
|
1030
|
+
T::Array[
|
|
1031
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type::TaggedSymbol
|
|
1032
|
+
]
|
|
1033
|
+
)
|
|
1034
|
+
end
|
|
1035
|
+
def self.values
|
|
1036
|
+
end
|
|
1037
|
+
end
|
|
1038
|
+
end
|
|
1039
|
+
|
|
1040
|
+
class WhatsappTemplateCarouselComponent < Telnyx::Internal::Type::BaseModel
|
|
1041
|
+
OrHash =
|
|
1042
|
+
T.type_alias do
|
|
1043
|
+
T.any(
|
|
1044
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent,
|
|
1045
|
+
Telnyx::Internal::AnyHash
|
|
1046
|
+
)
|
|
1047
|
+
end
|
|
1048
|
+
|
|
1049
|
+
# Array of card objects, each with its own components.
|
|
1050
|
+
sig do
|
|
1051
|
+
returns(
|
|
1052
|
+
T::Array[
|
|
1053
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Card
|
|
1054
|
+
]
|
|
1055
|
+
)
|
|
1056
|
+
end
|
|
1057
|
+
attr_accessor :cards
|
|
1058
|
+
|
|
1059
|
+
sig do
|
|
1060
|
+
returns(
|
|
1061
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type::OrSymbol
|
|
1062
|
+
)
|
|
1063
|
+
end
|
|
1064
|
+
attr_accessor :type
|
|
1065
|
+
|
|
1066
|
+
# Carousel component for multi-card templates. Each card can contain its own
|
|
1067
|
+
# header, body, and buttons.
|
|
1068
|
+
sig do
|
|
1069
|
+
params(
|
|
1070
|
+
cards:
|
|
1071
|
+
T::Array[
|
|
1072
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Card::OrHash
|
|
1073
|
+
],
|
|
1074
|
+
type:
|
|
1075
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type::OrSymbol
|
|
1076
|
+
).returns(T.attached_class)
|
|
1077
|
+
end
|
|
1078
|
+
def self.new(
|
|
1079
|
+
# Array of card objects, each with its own components.
|
|
1080
|
+
cards:,
|
|
1081
|
+
type:
|
|
1082
|
+
)
|
|
1083
|
+
end
|
|
1084
|
+
|
|
1085
|
+
sig do
|
|
1086
|
+
override.returns(
|
|
1087
|
+
{
|
|
1088
|
+
cards:
|
|
1089
|
+
T::Array[
|
|
1090
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Card
|
|
1091
|
+
],
|
|
1092
|
+
type:
|
|
1093
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type::OrSymbol
|
|
1094
|
+
}
|
|
1095
|
+
)
|
|
1096
|
+
end
|
|
1097
|
+
def to_hash
|
|
1098
|
+
end
|
|
1099
|
+
|
|
1100
|
+
class Card < Telnyx::Internal::Type::BaseModel
|
|
1101
|
+
OrHash =
|
|
1102
|
+
T.type_alias do
|
|
1103
|
+
T.any(
|
|
1104
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Card,
|
|
1105
|
+
Telnyx::Internal::AnyHash
|
|
1106
|
+
)
|
|
1107
|
+
end
|
|
1108
|
+
|
|
1109
|
+
sig { returns(T.nilable(T::Array[T::Hash[Symbol, T.anything]])) }
|
|
1110
|
+
attr_reader :components
|
|
1111
|
+
|
|
1112
|
+
sig do
|
|
1113
|
+
params(components: T::Array[T::Hash[Symbol, T.anything]]).void
|
|
1114
|
+
end
|
|
1115
|
+
attr_writer :components
|
|
1116
|
+
|
|
1117
|
+
sig do
|
|
1118
|
+
params(
|
|
1119
|
+
components: T::Array[T::Hash[Symbol, T.anything]]
|
|
1120
|
+
).returns(T.attached_class)
|
|
1121
|
+
end
|
|
1122
|
+
def self.new(components: nil)
|
|
1123
|
+
end
|
|
1124
|
+
|
|
1125
|
+
sig do
|
|
1126
|
+
override.returns(
|
|
1127
|
+
{ components: T::Array[T::Hash[Symbol, T.anything]] }
|
|
1128
|
+
)
|
|
1129
|
+
end
|
|
1130
|
+
def to_hash
|
|
1131
|
+
end
|
|
1132
|
+
end
|
|
1133
|
+
|
|
1134
|
+
module Type
|
|
1135
|
+
extend Telnyx::Internal::Type::Enum
|
|
1136
|
+
|
|
1137
|
+
TaggedSymbol =
|
|
1138
|
+
T.type_alias do
|
|
1139
|
+
T.all(
|
|
1140
|
+
Symbol,
|
|
1141
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type
|
|
1142
|
+
)
|
|
1143
|
+
end
|
|
1144
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1145
|
+
|
|
1146
|
+
CAROUSEL =
|
|
1147
|
+
T.let(
|
|
1148
|
+
:CAROUSEL,
|
|
1149
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type::TaggedSymbol
|
|
1150
|
+
)
|
|
1151
|
+
|
|
1152
|
+
sig do
|
|
1153
|
+
override.returns(
|
|
1154
|
+
T::Array[
|
|
1155
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type::TaggedSymbol
|
|
1156
|
+
]
|
|
1157
|
+
)
|
|
1158
|
+
end
|
|
1159
|
+
def self.values
|
|
1160
|
+
end
|
|
1161
|
+
end
|
|
1162
|
+
end
|
|
1163
|
+
|
|
1164
|
+
sig do
|
|
1165
|
+
override.returns(
|
|
1166
|
+
T::Array[
|
|
1167
|
+
Telnyx::Whatsapp::TemplateCreateParams::Component::Variants
|
|
1168
|
+
]
|
|
1169
|
+
)
|
|
1170
|
+
end
|
|
1171
|
+
def self.variants
|
|
1172
|
+
end
|
|
1173
|
+
end
|
|
1174
|
+
end
|
|
1175
|
+
end
|
|
1176
|
+
end
|
|
1177
|
+
end
|