telnyx 5.62.0 → 5.64.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.
Files changed (54) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +21 -0
  3. data/README.md +1 -1
  4. data/lib/telnyx/models/ai/conversation_add_message_params.rb +4 -4
  5. data/lib/telnyx/models/ai/inference_embedding_webhook_tool_params.rb +36 -1
  6. data/lib/telnyx/models/porting_orders/phone_number_block_list_params.rb +7 -7
  7. data/lib/telnyx/models/voice_clone_create_from_upload_params.rb +0 -2
  8. data/lib/telnyx/models/voice_clone_create_params.rb +0 -2
  9. data/lib/telnyx/models/voice_clone_data.rb +0 -2
  10. data/lib/telnyx/models/voice_clone_list_params.rb +0 -2
  11. data/lib/telnyx/models/voice_design_create_params.rb +0 -2
  12. data/lib/telnyx/models/voice_design_data.rb +0 -2
  13. data/lib/telnyx/models/voice_design_list_response.rb +0 -2
  14. data/lib/telnyx/models/voice_design_rename_response.rb +0 -2
  15. data/lib/telnyx/models/whatsapp/template_create_params.rb +78 -136
  16. data/lib/telnyx/models/whatsapp_message_template_update_params.rb +77 -135
  17. data/lib/telnyx/models/x402/credit_account_settle_params.rb +4 -4
  18. data/lib/telnyx/resources/whatsapp/templates.rb +1 -1
  19. data/lib/telnyx/resources/whatsapp_message_templates.rb +1 -1
  20. data/lib/telnyx/resources/x402/credit_account.rb +2 -2
  21. data/lib/telnyx/version.rb +1 -1
  22. data/rbi/telnyx/models/ai/conversation_add_message_params.rbi +5 -5
  23. data/rbi/telnyx/models/ai/inference_embedding_webhook_tool_params.rbi +71 -0
  24. data/rbi/telnyx/models/porting_orders/phone_number_block_list_params.rbi +18 -18
  25. data/rbi/telnyx/models/voice_clone_create_from_upload_params.rbi +0 -10
  26. data/rbi/telnyx/models/voice_clone_create_params.rbi +0 -7
  27. data/rbi/telnyx/models/voice_clone_data.rbi +0 -4
  28. data/rbi/telnyx/models/voice_clone_list_params.rbi +0 -10
  29. data/rbi/telnyx/models/voice_design_create_params.rbi +0 -10
  30. data/rbi/telnyx/models/voice_design_data.rbi +0 -4
  31. data/rbi/telnyx/models/voice_design_list_response.rbi +0 -10
  32. data/rbi/telnyx/models/voice_design_rename_response.rbi +0 -10
  33. data/rbi/telnyx/models/whatsapp/template_create_params.rbi +115 -294
  34. data/rbi/telnyx/models/whatsapp_message_template_update_params.rbi +120 -299
  35. data/rbi/telnyx/models/x402/credit_account_settle_params.rbi +6 -6
  36. data/rbi/telnyx/resources/whatsapp/templates.rbi +5 -5
  37. data/rbi/telnyx/resources/whatsapp_message_templates.rbi +5 -5
  38. data/rbi/telnyx/resources/x402/credit_account.rbi +2 -2
  39. data/sig/telnyx/models/ai/conversation_add_message_params.rbs +5 -5
  40. data/sig/telnyx/models/ai/inference_embedding_webhook_tool_params.rbs +21 -0
  41. data/sig/telnyx/models/porting_orders/phone_number_block_list_params.rbs +5 -5
  42. data/sig/telnyx/models/voice_clone_create_from_upload_params.rbs +1 -3
  43. data/sig/telnyx/models/voice_clone_create_params.rbs +1 -3
  44. data/sig/telnyx/models/voice_clone_data.rbs +1 -3
  45. data/sig/telnyx/models/voice_clone_list_params.rbs +1 -3
  46. data/sig/telnyx/models/voice_design_create_params.rbs +1 -3
  47. data/sig/telnyx/models/voice_design_data.rbs +1 -3
  48. data/sig/telnyx/models/voice_design_list_response.rbs +1 -3
  49. data/sig/telnyx/models/voice_design_rename_response.rbs +1 -3
  50. data/sig/telnyx/models/whatsapp/template_create_params.rbs +82 -136
  51. data/sig/telnyx/models/whatsapp_message_template_update_params.rbs +82 -136
  52. data/sig/telnyx/models/x402/credit_account_settle_params.rbs +5 -5
  53. data/sig/telnyx/resources/x402/credit_account.rbs +1 -1
  54. metadata +2 -2
@@ -19,7 +19,7 @@ module Telnyx
19
19
  # API. Templates with variables must include example values. Supports HEADER,
20
20
  # BODY, FOOTER, BUTTONS, CAROUSEL and any future Meta component types.
21
21
  #
22
- # @return [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent>]
22
+ # @return [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Body, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Footer, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Carousel>]
23
23
  required :components,
24
24
  -> { Telnyx::Internal::Type::ArrayOf[union: Telnyx::Whatsapp::TemplateCreateParams::Component] }
25
25
 
@@ -47,7 +47,7 @@ module Telnyx
47
47
  #
48
48
  # @param category [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Category] Template category: AUTHENTICATION, UTILITY, or MARKETING.
49
49
  #
50
- # @param components [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent>] Template components defining message structure. Passed through to Meta Graph API
50
+ # @param components [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Body, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Footer, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Carousel>] Template components defining message structure. Passed through to Meta Graph API
51
51
  #
52
52
  # @param language [String] Template language code (e.g. en_US, es, pt_BR).
53
53
  #
@@ -74,45 +74,43 @@ module Telnyx
74
74
  module Component
75
75
  extend Telnyx::Internal::Type::Union
76
76
 
77
+ discriminator :type
78
+
77
79
  # Optional header displayed at the top of the message.
78
- variant -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent }
80
+ variant :HEADER, -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Header }
79
81
 
80
82
  # The main text content of the message. Supports multiple variable parameters ({{1}}, {{2}}, etc.). Variables cannot be at the start or end. Maximum 1024 characters.
81
- variant -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent }
83
+ variant :BODY, -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Body }
82
84
 
83
85
  # Optional footer displayed at the bottom of the message. Does not support variables.
84
- variant -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent }
86
+ variant :FOOTER, -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Footer }
85
87
 
86
88
  # Optional interactive buttons. Maximum 3 buttons per template.
87
- variant -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent }
89
+ variant :BUTTONS, -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Buttons }
88
90
 
89
91
  # Carousel component for multi-card templates. Each card can contain its own header, body, and buttons.
90
- variant -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent }
92
+ variant :CAROUSEL, -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Carousel }
91
93
 
92
- class WhatsappTemplateHeaderComponent < Telnyx::Internal::Type::BaseModel
93
- # @!attribute format_
94
+ class Header < Telnyx::Internal::Type::BaseModel
95
+ # @!attribute file_format
94
96
  # Header format type: TEXT (supports one variable), IMAGE, VIDEO, DOCUMENT, or
95
97
  # LOCATION.
96
98
  #
97
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format]
98
- required :format_,
99
- enum: -> {
100
- Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format
101
- },
99
+ # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header::Format]
100
+ required :file_format,
101
+ enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Header::Format },
102
102
  api_name: :format
103
103
 
104
104
  # @!attribute type
105
105
  #
106
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type]
107
- required :type,
108
- enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type }
106
+ # @return [Symbol, :HEADER]
107
+ required :type, const: :HEADER
109
108
 
110
109
  # @!attribute example
111
110
  # Sample values for header variables.
112
111
  #
113
- # @return [Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Example, nil]
114
- optional :example,
115
- -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Example }
112
+ # @return [Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header::Example, nil]
113
+ optional :example, -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Header::Example }
116
114
 
117
115
  # @!attribute text
118
116
  # Header text. Required when format is TEXT. Supports one variable ({{1}}).
@@ -121,25 +119,25 @@ module Telnyx
121
119
  # @return [String, nil]
122
120
  optional :text, String
123
121
 
124
- # @!method initialize(format_:, type:, example: nil, text: nil)
122
+ # @!method initialize(file_format:, example: nil, text: nil, type: :HEADER)
125
123
  # Some parameter documentations has been truncated, see
126
- # {Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent}
127
- # for more details.
124
+ # {Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header} for more
125
+ # details.
128
126
  #
129
127
  # Optional header displayed at the top of the message.
130
128
  #
131
- # @param format_ [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Format] Header format type: TEXT (supports one variable), IMAGE, VIDEO, DOCUMENT, or LOC
132
- #
133
- # @param type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Type]
129
+ # @param file_format [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header::Format] Header format type: TEXT (supports one variable), IMAGE, VIDEO, DOCUMENT, or LOC
134
130
  #
135
- # @param example [Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent::Example] Sample values for header variables.
131
+ # @param example [Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header::Example] Sample values for header variables.
136
132
  #
137
133
  # @param text [String] Header text. Required when format is TEXT. Supports one variable ({{1}}). Variab
134
+ #
135
+ # @param type [Symbol, :HEADER]
138
136
 
139
137
  # Header format type: TEXT (supports one variable), IMAGE, VIDEO, DOCUMENT, or
140
138
  # LOCATION.
141
139
  #
142
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent#format_
140
+ # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header#file_format
143
141
  module Format
144
142
  extend Telnyx::Internal::Type::Enum
145
143
 
@@ -153,17 +151,7 @@ module Telnyx
153
151
  # @return [Array<Symbol>]
154
152
  end
155
153
 
156
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent#type
157
- module Type
158
- extend Telnyx::Internal::Type::Enum
159
-
160
- HEADER = :HEADER
161
-
162
- # @!method self.values
163
- # @return [Array<Symbol>]
164
- end
165
-
166
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent#example
154
+ # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header#example
167
155
  class Example < Telnyx::Internal::Type::BaseModel
168
156
  # @!attribute header_handle
169
157
  # Media handle for IMAGE, VIDEO, or DOCUMENT headers.
@@ -186,19 +174,17 @@ module Telnyx
186
174
  end
187
175
  end
188
176
 
189
- class WhatsappTemplateBodyComponent < Telnyx::Internal::Type::BaseModel
177
+ class Body < Telnyx::Internal::Type::BaseModel
190
178
  # @!attribute type
191
179
  #
192
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type]
193
- required :type,
194
- enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type }
180
+ # @return [Symbol, :BODY]
181
+ required :type, const: :BODY
195
182
 
196
183
  # @!attribute example
197
184
  # Sample values for body variables. Required when body text contains parameters.
198
185
  #
199
- # @return [Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Example, nil]
200
- optional :example,
201
- -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Example }
186
+ # @return [Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Body::Example, nil]
187
+ optional :example, -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Body::Example }
202
188
 
203
189
  # @!attribute text
204
190
  # Body text content. Use {{1}}, {{2}}, etc. for variable placeholders. Required
@@ -208,32 +194,22 @@ module Telnyx
208
194
  # @return [String, nil]
209
195
  optional :text, String
210
196
 
211
- # @!method initialize(type:, example: nil, text: nil)
197
+ # @!method initialize(example: nil, text: nil, type: :BODY)
212
198
  # Some parameter documentations has been truncated, see
213
- # {Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent}
214
- # for more details.
199
+ # {Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Body} for more
200
+ # details.
215
201
  #
216
202
  # The main text content of the message. Supports multiple variable parameters
217
203
  # ({{1}}, {{2}}, etc.). Variables cannot be at the start or end. Maximum 1024
218
204
  # characters.
219
205
  #
220
- # @param type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Type]
221
- #
222
- # @param example [Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent::Example] Sample values for body variables. Required when body text contains parameters.
206
+ # @param example [Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Body::Example] Sample values for body variables. Required when body text contains parameters.
223
207
  #
224
208
  # @param text [String] Body text content. Use {{1}}, {{2}}, etc. for variable placeholders. Required fo
209
+ #
210
+ # @param type [Symbol, :BODY]
225
211
 
226
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent#type
227
- module Type
228
- extend Telnyx::Internal::Type::Enum
229
-
230
- BODY = :BODY
231
-
232
- # @!method self.values
233
- # @return [Array<Symbol>]
234
- end
235
-
236
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent#example
212
+ # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Body#example
237
213
  class Example < Telnyx::Internal::Type::BaseModel
238
214
  # @!attribute body_text
239
215
  # Array containing one array of sample values, one per variable in order.
@@ -248,12 +224,11 @@ module Telnyx
248
224
  end
249
225
  end
250
226
 
251
- class WhatsappTemplateFooterComponent < Telnyx::Internal::Type::BaseModel
227
+ class Footer < Telnyx::Internal::Type::BaseModel
252
228
  # @!attribute type
253
229
  #
254
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type]
255
- required :type,
256
- enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type }
230
+ # @return [Symbol, :FOOTER]
231
+ required :type, const: :FOOTER
257
232
 
258
233
  # @!attribute code_expiration_minutes
259
234
  # OTP code expiration time in minutes. Used in AUTHENTICATION template footers
@@ -268,58 +243,46 @@ module Telnyx
268
243
  # @return [String, nil]
269
244
  optional :text, String
270
245
 
271
- # @!method initialize(type:, code_expiration_minutes: nil, text: nil)
246
+ # @!method initialize(code_expiration_minutes: nil, text: nil, type: :FOOTER)
272
247
  # Some parameter documentations has been truncated, see
273
- # {Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent}
274
- # for more details.
248
+ # {Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Footer} for more
249
+ # details.
275
250
  #
276
251
  # Optional footer displayed at the bottom of the message. Does not support
277
252
  # variables.
278
253
  #
279
- # @param type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent::Type]
280
- #
281
254
  # @param code_expiration_minutes [Integer] OTP code expiration time in minutes. Used in AUTHENTICATION template footers ins
282
255
  #
283
256
  # @param text [String] Footer text. Maximum 60 characters. For non-authentication templates.
284
-
285
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent#type
286
- module Type
287
- extend Telnyx::Internal::Type::Enum
288
-
289
- FOOTER = :FOOTER
290
-
291
- # @!method self.values
292
- # @return [Array<Symbol>]
293
- end
257
+ #
258
+ # @param type [Symbol, :FOOTER]
294
259
  end
295
260
 
296
- class WhatsappTemplateButtonsComponent < Telnyx::Internal::Type::BaseModel
261
+ class Buttons < Telnyx::Internal::Type::BaseModel
297
262
  # @!attribute buttons
298
263
  # Array of button objects. Meta supports various combinations of button types.
299
264
  #
300
- # @return [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button>]
265
+ # @return [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button>]
301
266
  required :buttons,
302
- -> { Telnyx::Internal::Type::ArrayOf[Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button] }
267
+ -> { Telnyx::Internal::Type::ArrayOf[Telnyx::Whatsapp::TemplateCreateParams::Component::Buttons::Button] }
303
268
 
304
269
  # @!attribute type
305
270
  #
306
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type]
307
- required :type,
308
- enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type }
271
+ # @return [Symbol, :BUTTONS]
272
+ required :type, const: :BUTTONS
309
273
 
310
- # @!method initialize(buttons:, type:)
274
+ # @!method initialize(buttons:, type: :BUTTONS)
311
275
  # Optional interactive buttons. Maximum 3 buttons per template.
312
276
  #
313
- # @param buttons [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button>] Array of button objects. Meta supports various combinations of button types.
277
+ # @param buttons [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button>] Array of button objects. Meta supports various combinations of button types.
314
278
  #
315
- # @param type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Type]
279
+ # @param type [Symbol, :BUTTONS]
316
280
 
317
281
  class Button < Telnyx::Internal::Type::BaseModel
318
282
  # @!attribute type
319
283
  #
320
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type]
321
- required :type,
322
- enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type }
284
+ # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button::Type]
285
+ required :type, enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Buttons::Button::Type }
323
286
 
324
287
  # @!attribute autofill_text
325
288
  # Custom autofill button text for ONE_TAP OTP buttons.
@@ -336,9 +299,9 @@ module Telnyx
336
299
  # @!attribute flow_action
337
300
  # Flow action type for FLOW-type buttons.
338
301
  #
339
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction, nil]
302
+ # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button::FlowAction, nil]
340
303
  optional :flow_action,
341
- enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction }
304
+ enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Buttons::Button::FlowAction }
342
305
 
343
306
  # @!attribute flow_id
344
307
  # Flow ID for FLOW-type buttons.
@@ -354,9 +317,9 @@ module Telnyx
354
317
 
355
318
  # @!attribute otp_type
356
319
  #
357
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType, nil]
320
+ # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button::OtpType, nil]
358
321
  optional :otp_type,
359
- enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType }
322
+ enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::Buttons::Button::OtpType }
360
323
 
361
324
  # @!attribute package_name
362
325
  # Android package name. Required for ONE_TAP OTP buttons.
@@ -397,22 +360,22 @@ module Telnyx
397
360
 
398
361
  # @!method initialize(type:, autofill_text: nil, example: nil, flow_action: nil, flow_id: nil, navigate_screen: nil, otp_type: nil, package_name: nil, phone_number: nil, signature_hash: nil, text: nil, url: nil, zero_tap_terms_accepted: nil)
399
362
  # Some parameter documentations has been truncated, see
400
- # {Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button}
401
- # for more details.
363
+ # {Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button} for
364
+ # more details.
402
365
  #
403
- # @param type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::Type]
366
+ # @param type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button::Type]
404
367
  #
405
368
  # @param autofill_text [String] Custom autofill button text for ONE_TAP OTP buttons.
406
369
  #
407
370
  # @param example [Array<String>] Sample values for URL variable.
408
371
  #
409
- # @param flow_action [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::FlowAction] Flow action type for FLOW-type buttons.
372
+ # @param flow_action [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button::FlowAction] Flow action type for FLOW-type buttons.
410
373
  #
411
374
  # @param flow_id [String] Flow ID for FLOW-type buttons.
412
375
  #
413
376
  # @param navigate_screen [String] Target screen name for FLOW buttons with navigate action.
414
377
  #
415
- # @param otp_type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button::OtpType]
378
+ # @param otp_type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button::OtpType]
416
379
  #
417
380
  # @param package_name [String] Android package name. Required for ONE_TAP OTP buttons.
418
381
  #
@@ -426,7 +389,7 @@ module Telnyx
426
389
  #
427
390
  # @param zero_tap_terms_accepted [Boolean] Whether zero-tap terms have been accepted.
428
391
 
429
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button#type
392
+ # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button#type
430
393
  module Type
431
394
  extend Telnyx::Internal::Type::Enum
432
395
 
@@ -443,7 +406,7 @@ module Telnyx
443
406
 
444
407
  # Flow action type for FLOW-type buttons.
445
408
  #
446
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button#flow_action
409
+ # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button#flow_action
447
410
  module FlowAction
448
411
  extend Telnyx::Internal::Type::Enum
449
412
 
@@ -454,7 +417,7 @@ module Telnyx
454
417
  # @return [Array<Symbol>]
455
418
  end
456
419
 
457
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent::Button#otp_type
420
+ # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons::Button#otp_type
458
421
  module OtpType
459
422
  extend Telnyx::Internal::Type::Enum
460
423
 
@@ -465,39 +428,28 @@ module Telnyx
465
428
  # @return [Array<Symbol>]
466
429
  end
467
430
  end
468
-
469
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent#type
470
- module Type
471
- extend Telnyx::Internal::Type::Enum
472
-
473
- BUTTONS = :BUTTONS
474
-
475
- # @!method self.values
476
- # @return [Array<Symbol>]
477
- end
478
431
  end
479
432
 
480
- class WhatsappTemplateCarouselComponent < Telnyx::Internal::Type::BaseModel
433
+ class Carousel < Telnyx::Internal::Type::BaseModel
481
434
  # @!attribute cards
482
435
  # Array of card objects, each with its own components.
483
436
  #
484
- # @return [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Card>]
437
+ # @return [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Carousel::Card>]
485
438
  required :cards,
486
- -> { Telnyx::Internal::Type::ArrayOf[Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Card] }
439
+ -> { Telnyx::Internal::Type::ArrayOf[Telnyx::Whatsapp::TemplateCreateParams::Component::Carousel::Card] }
487
440
 
488
441
  # @!attribute type
489
442
  #
490
- # @return [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type]
491
- required :type,
492
- enum: -> { Telnyx::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type }
443
+ # @return [Symbol, :CAROUSEL]
444
+ required :type, const: :CAROUSEL
493
445
 
494
- # @!method initialize(cards:, type:)
446
+ # @!method initialize(cards:, type: :CAROUSEL)
495
447
  # Carousel component for multi-card templates. Each card can contain its own
496
448
  # header, body, and buttons.
497
449
  #
498
- # @param cards [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Card>] Array of card objects, each with its own components.
450
+ # @param cards [Array<Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Carousel::Card>] Array of card objects, each with its own components.
499
451
  #
500
- # @param type [Symbol, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent::Type]
452
+ # @param type [Symbol, :CAROUSEL]
501
453
 
502
454
  class Card < Telnyx::Internal::Type::BaseModel
503
455
  # @!attribute components
@@ -509,20 +461,10 @@ module Telnyx
509
461
  # @!method initialize(components: nil)
510
462
  # @param components [Array<Hash{Symbol=>Object}>]
511
463
  end
512
-
513
- # @see Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent#type
514
- module Type
515
- extend Telnyx::Internal::Type::Enum
516
-
517
- CAROUSEL = :CAROUSEL
518
-
519
- # @!method self.values
520
- # @return [Array<Symbol>]
521
- end
522
464
  end
523
465
 
524
466
  # @!method self.variants
525
- # @return [Array(Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateHeaderComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateBodyComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateFooterComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateButtonsComponent, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::WhatsappTemplateCarouselComponent)]
467
+ # @return [Array(Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Header, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Body, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Footer, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Buttons, Telnyx::Models::Whatsapp::TemplateCreateParams::Component::Carousel)]
526
468
  end
527
469
  end
528
470
  end