telnyx 5.123.0 → 5.124.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 (122) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +19 -0
  3. data/README.md +1 -1
  4. data/lib/telnyx/client.rb +5 -0
  5. data/lib/telnyx/models/ai/assistant_create_params.rb +780 -1
  6. data/lib/telnyx/models/ai/assistant_update_params.rb +780 -1
  7. data/lib/telnyx/models/ai/assistants/update_assistant.rb +785 -1
  8. data/lib/telnyx/models/ai/inference_embedding.rb +767 -1
  9. data/lib/telnyx/models/{ai_create_response_params.rb → ai_create_response_deprecated_params.rb} +2 -2
  10. data/lib/telnyx/models/{ai_create_response_response.rb → ai_create_response_deprecated_response.rb} +1 -1
  11. data/lib/telnyx/models/call_dial_params.rb +276 -10
  12. data/lib/telnyx/models/calls/action_answer_params.rb +278 -10
  13. data/lib/telnyx/models/calls/action_gather_using_speak_params.rb +15 -4
  14. data/lib/telnyx/models/calls/action_speak_params.rb +15 -4
  15. data/lib/telnyx/models/calls/action_start_conversation_relay_params.rb +431 -13
  16. data/lib/telnyx/models/calls/transcription_start_request.rb +173 -5
  17. data/lib/telnyx/models/conferences/action_speak_params.rb +15 -4
  18. data/lib/telnyx/models/messaging_profile_update_params.rb +9 -1
  19. data/lib/telnyx/models/sip_registration_status_retrieve_params.rb +45 -0
  20. data/lib/telnyx/models/sip_registration_status_retrieve_response.rb +160 -0
  21. data/lib/telnyx/models/speech_to_text_list_providers_params.rb +16 -5
  22. data/lib/telnyx/models/speech_to_text_list_providers_response.rb +55 -23
  23. data/lib/telnyx/models/voice_sdk_call_report_list_response.rb +114 -9
  24. data/lib/telnyx/models/voice_sdk_call_report_retrieve_response.rb +116 -9
  25. data/lib/telnyx/models/whatsapp/user_data_retrieve_response.rb +44 -3
  26. data/lib/telnyx/models/whatsapp/user_data_update_response.rb +44 -3
  27. data/lib/telnyx/models.rb +3 -9
  28. data/lib/telnyx/resources/ai/assistants/versions.rb +3 -1
  29. data/lib/telnyx/resources/ai/assistants.rb +6 -2
  30. data/lib/telnyx/resources/ai.rb +4 -4
  31. data/lib/telnyx/resources/calls/actions.rb +6 -6
  32. data/lib/telnyx/resources/conferences/actions.rb +1 -1
  33. data/lib/telnyx/resources/messaging_profiles.rb +3 -1
  34. data/lib/telnyx/resources/sip_registration_status.rb +45 -0
  35. data/lib/telnyx/resources/speech_to_text.rb +6 -5
  36. data/lib/telnyx/version.rb +1 -1
  37. data/lib/telnyx.rb +5 -9
  38. data/rbi/telnyx/client.rbi +4 -0
  39. data/rbi/telnyx/models/ai/assistant_create_params.rbi +1411 -0
  40. data/rbi/telnyx/models/ai/assistant_update_params.rbi +1411 -0
  41. data/rbi/telnyx/models/ai/assistants/update_assistant.rbi +1417 -0
  42. data/rbi/telnyx/models/ai/inference_embedding.rbi +1454 -0
  43. data/rbi/telnyx/models/{ai_create_response_params.rbi → ai_create_response_deprecated_params.rbi} +5 -2
  44. data/rbi/telnyx/models/{ai_create_response_response.rbi → ai_create_response_deprecated_response.rbi} +1 -1
  45. data/rbi/telnyx/models/call_dial_params.rbi +661 -13
  46. data/rbi/telnyx/models/calls/action_answer_params.rbi +659 -13
  47. data/rbi/telnyx/models/calls/action_gather_using_speak_params.rbi +30 -5
  48. data/rbi/telnyx/models/calls/action_speak_params.rbi +30 -5
  49. data/rbi/telnyx/models/calls/action_start_conversation_relay_params.rbi +1016 -17
  50. data/rbi/telnyx/models/calls/transcription_start_request.rbi +433 -10
  51. data/rbi/telnyx/models/conferences/action_speak_params.rbi +30 -5
  52. data/rbi/telnyx/models/messaging_profile_update_params.rbi +8 -0
  53. data/rbi/telnyx/models/sip_registration_status_retrieve_params.rbi +93 -0
  54. data/rbi/telnyx/models/sip_registration_status_retrieve_response.rbi +343 -0
  55. data/rbi/telnyx/models/speech_to_text_list_providers_params.rbi +27 -7
  56. data/rbi/telnyx/models/speech_to_text_list_providers_response.rbi +107 -43
  57. data/rbi/telnyx/models/voice_sdk_call_report_list_response.rbi +294 -9
  58. data/rbi/telnyx/models/voice_sdk_call_report_retrieve_response.rbi +294 -9
  59. data/rbi/telnyx/models/whatsapp/user_data_retrieve_response.rbi +96 -6
  60. data/rbi/telnyx/models/whatsapp/user_data_update_response.rbi +94 -6
  61. data/rbi/telnyx/models.rbi +5 -10
  62. data/rbi/telnyx/resources/ai/assistants/versions.rbi +8 -0
  63. data/rbi/telnyx/resources/ai/assistants.rbi +16 -0
  64. data/rbi/telnyx/resources/ai.rbi +1 -1
  65. data/rbi/telnyx/resources/calls/actions.rbi +10 -7
  66. data/rbi/telnyx/resources/conferences/actions.rbi +1 -1
  67. data/rbi/telnyx/resources/messaging_profiles.rbi +3 -0
  68. data/rbi/telnyx/resources/sip_registration_status.rbi +34 -0
  69. data/rbi/telnyx/resources/speech_to_text.rbi +11 -5
  70. data/sig/telnyx/client.rbs +2 -0
  71. data/sig/telnyx/models/ai/assistant_create_params.rbs +508 -0
  72. data/sig/telnyx/models/ai/assistant_update_params.rbs +508 -0
  73. data/sig/telnyx/models/ai/assistants/update_assistant.rbs +511 -0
  74. data/sig/telnyx/models/ai/inference_embedding.rbs +526 -0
  75. data/sig/telnyx/models/{ai_create_response_params.rbs → ai_create_response_deprecated_params.rbs} +2 -2
  76. data/sig/telnyx/models/ai_create_response_deprecated_response.rbs +7 -0
  77. data/sig/telnyx/models/call_dial_params.rbs +236 -13
  78. data/sig/telnyx/models/calls/action_answer_params.rbs +236 -13
  79. data/sig/telnyx/models/calls/action_gather_using_speak_params.rbs +11 -1
  80. data/sig/telnyx/models/calls/action_speak_params.rbs +11 -1
  81. data/sig/telnyx/models/calls/action_start_conversation_relay_params.rbs +370 -19
  82. data/sig/telnyx/models/calls/transcription_start_request.rbs +175 -2
  83. data/sig/telnyx/models/conferences/action_speak_params.rbs +11 -1
  84. data/sig/telnyx/models/messaging_profile_update_params.rbs +5 -0
  85. data/sig/telnyx/models/sip_registration_status_retrieve_params.rbs +41 -0
  86. data/sig/telnyx/models/sip_registration_status_retrieve_response.rbs +164 -0
  87. data/sig/telnyx/models/speech_to_text_list_providers_params.rbs +4 -4
  88. data/sig/telnyx/models/speech_to_text_list_providers_response.rbs +33 -16
  89. data/sig/telnyx/models/voice_sdk_call_report_list_response.rbs +121 -8
  90. data/sig/telnyx/models/voice_sdk_call_report_retrieve_response.rbs +121 -8
  91. data/sig/telnyx/models/whatsapp/user_data_retrieve_response.rbs +57 -6
  92. data/sig/telnyx/models/whatsapp/user_data_update_response.rbs +57 -6
  93. data/sig/telnyx/models.rbs +3 -9
  94. data/sig/telnyx/resources/ai/assistants/versions.rbs +1 -0
  95. data/sig/telnyx/resources/ai/assistants.rbs +2 -0
  96. data/sig/telnyx/resources/ai.rbs +2 -2
  97. data/sig/telnyx/resources/calls/actions.rbs +2 -2
  98. data/sig/telnyx/resources/messaging_profiles.rbs +1 -0
  99. data/sig/telnyx/resources/sip_registration_status.rbs +13 -0
  100. metadata +17 -29
  101. data/lib/telnyx/models/calls/transcription_engine_soniox_config.rb +0 -91
  102. data/lib/telnyx/models/calls/transcription_engine_speechmatics_config.rb +0 -100
  103. data/lib/telnyx/models/conversation_relay_interruption_settings.rb +0 -105
  104. data/lib/telnyx/models/conversation_relay_language.rb +0 -141
  105. data/lib/telnyx/models/inworld_voice_settings.rb +0 -28
  106. data/lib/telnyx/models/voice_sdk_call_report_log_entry.rb +0 -57
  107. data/lib/telnyx/models/whatsapp/whatsapp_user_data.rb +0 -49
  108. data/rbi/telnyx/models/calls/transcription_engine_soniox_config.rbi +0 -184
  109. data/rbi/telnyx/models/calls/transcription_engine_speechmatics_config.rbi +0 -289
  110. data/rbi/telnyx/models/conversation_relay_interruption_settings.rbi +0 -271
  111. data/rbi/telnyx/models/conversation_relay_language.rbi +0 -309
  112. data/rbi/telnyx/models/inworld_voice_settings.rbi +0 -53
  113. data/rbi/telnyx/models/voice_sdk_call_report_log_entry.rbi +0 -108
  114. data/rbi/telnyx/models/whatsapp/whatsapp_user_data.rbi +0 -82
  115. data/sig/telnyx/models/ai_create_response_response.rbs +0 -7
  116. data/sig/telnyx/models/calls/transcription_engine_soniox_config.rbs +0 -79
  117. data/sig/telnyx/models/calls/transcription_engine_speechmatics_config.rbs +0 -114
  118. data/sig/telnyx/models/conversation_relay_interruption_settings.rbs +0 -88
  119. data/sig/telnyx/models/conversation_relay_language.rbs +0 -121
  120. data/sig/telnyx/models/inworld_voice_settings.rbs +0 -26
  121. data/sig/telnyx/models/voice_sdk_call_report_log_entry.rbs +0 -58
  122. data/sig/telnyx/models/whatsapp/whatsapp_user_data.rbs +0 -54
@@ -8,6 +8,7 @@ module Telnyx
8
8
  instructions: String,
9
9
  model: String,
10
10
  name: String,
11
+ conversation_flow: Telnyx::AI::InferenceEmbedding::ConversationFlow,
11
12
  description: String,
12
13
  dynamic_variables: ::Hash[Symbol, top],
13
14
  dynamic_variables_webhook_timeout_ms: Integer,
@@ -49,6 +50,12 @@ module Telnyx
49
50
 
50
51
  attr_accessor name: String
51
52
 
53
+ attr_reader conversation_flow: Telnyx::AI::InferenceEmbedding::ConversationFlow?
54
+
55
+ def conversation_flow=: (
56
+ Telnyx::AI::InferenceEmbedding::ConversationFlow
57
+ ) -> Telnyx::AI::InferenceEmbedding::ConversationFlow
58
+
52
59
  attr_reader description: String?
53
60
 
54
61
  def description=: (String) -> String
@@ -199,6 +206,7 @@ module Telnyx
199
206
  instructions: String,
200
207
  model: String,
201
208
  name: String,
209
+ ?conversation_flow: Telnyx::AI::InferenceEmbedding::ConversationFlow,
202
210
  ?description: String,
203
211
  ?dynamic_variables: ::Hash[Symbol, top],
204
212
  ?dynamic_variables_webhook_timeout_ms: Integer,
@@ -235,6 +243,7 @@ module Telnyx
235
243
  instructions: String,
236
244
  model: String,
237
245
  name: String,
246
+ conversation_flow: Telnyx::AI::InferenceEmbedding::ConversationFlow,
238
247
  description: String,
239
248
  dynamic_variables: ::Hash[Symbol, top],
240
249
  dynamic_variables_webhook_timeout_ms: Integer,
@@ -264,6 +273,523 @@ module Telnyx
264
273
  voice_settings: Telnyx::AI::VoiceSettings,
265
274
  widget_settings: Telnyx::AI::WidgetSettings
266
275
  }
276
+
277
+ type conversation_flow =
278
+ {
279
+ nodes: ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::node],
280
+ start_node_id: String,
281
+ edges: ::Array[Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge]
282
+ }
283
+
284
+ class ConversationFlow < Telnyx::Internal::Type::BaseModel
285
+ attr_accessor nodes: ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::node]
286
+
287
+ attr_accessor start_node_id: String
288
+
289
+ attr_reader edges: ::Array[Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge]?
290
+
291
+ def edges=: (
292
+ ::Array[Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge]
293
+ ) -> ::Array[Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge]
294
+
295
+ def initialize: (
296
+ nodes: ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::node],
297
+ start_node_id: String,
298
+ ?edges: ::Array[Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge]
299
+ ) -> void
300
+
301
+ def to_hash: -> {
302
+ nodes: ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::node],
303
+ start_node_id: String,
304
+ edges: ::Array[Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge]
305
+ }
306
+
307
+ type node =
308
+ Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Prompt
309
+ | Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Tool
310
+
311
+ module Node
312
+ extend Telnyx::Internal::Type::Union
313
+
314
+ type prompt =
315
+ {
316
+ id: String,
317
+ instructions: String,
318
+ external_llm: Telnyx::AI::ExternalLlm,
319
+ instructions_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::instructions_mode,
320
+ llm_api_key_ref: String,
321
+ model: String,
322
+ name: String,
323
+ position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::Position,
324
+ shared_tool_ids: ::Array[String],
325
+ tools: ::Array[::Array[Telnyx::Models::AI::assistant_tool]],
326
+ tools_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::tools_mode,
327
+ transcription: Telnyx::AI::TranscriptionSettings,
328
+ type: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::type_,
329
+ voice_settings: Telnyx::AI::VoiceSettings
330
+ }
331
+
332
+ class Prompt < Telnyx::Internal::Type::BaseModel
333
+ attr_accessor id: String
334
+
335
+ attr_accessor instructions: String
336
+
337
+ attr_reader external_llm: Telnyx::AI::ExternalLlm?
338
+
339
+ def external_llm=: (
340
+ Telnyx::AI::ExternalLlm
341
+ ) -> Telnyx::AI::ExternalLlm
342
+
343
+ attr_reader instructions_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::instructions_mode?
344
+
345
+ def instructions_mode=: (
346
+ Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::instructions_mode
347
+ ) -> Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::instructions_mode
348
+
349
+ attr_reader llm_api_key_ref: String?
350
+
351
+ def llm_api_key_ref=: (String) -> String
352
+
353
+ attr_reader model: String?
354
+
355
+ def model=: (String) -> String
356
+
357
+ attr_reader name: String?
358
+
359
+ def name=: (String) -> String
360
+
361
+ attr_reader position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::Position?
362
+
363
+ def position=: (
364
+ Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::Position
365
+ ) -> Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::Position
366
+
367
+ attr_reader shared_tool_ids: ::Array[String]?
368
+
369
+ def shared_tool_ids=: (::Array[String]) -> ::Array[String]
370
+
371
+ attr_reader tools: ::Array[::Array[Telnyx::Models::AI::assistant_tool]]?
372
+
373
+ def tools=: (
374
+ ::Array[::Array[Telnyx::Models::AI::assistant_tool]]
375
+ ) -> ::Array[::Array[Telnyx::Models::AI::assistant_tool]]
376
+
377
+ attr_reader tools_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::tools_mode?
378
+
379
+ def tools_mode=: (
380
+ Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::tools_mode
381
+ ) -> Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::tools_mode
382
+
383
+ attr_reader transcription: Telnyx::AI::TranscriptionSettings?
384
+
385
+ def transcription=: (
386
+ Telnyx::AI::TranscriptionSettings
387
+ ) -> Telnyx::AI::TranscriptionSettings
388
+
389
+ attr_reader type: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::type_?
390
+
391
+ def type=: (
392
+ Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::type_
393
+ ) -> Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::type_
394
+
395
+ attr_reader voice_settings: Telnyx::AI::VoiceSettings?
396
+
397
+ def voice_settings=: (
398
+ Telnyx::AI::VoiceSettings
399
+ ) -> Telnyx::AI::VoiceSettings
400
+
401
+ def initialize: (
402
+ id: String,
403
+ instructions: String,
404
+ ?external_llm: Telnyx::AI::ExternalLlm,
405
+ ?instructions_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::instructions_mode,
406
+ ?llm_api_key_ref: String,
407
+ ?model: String,
408
+ ?name: String,
409
+ ?position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::Position,
410
+ ?shared_tool_ids: ::Array[String],
411
+ ?tools: ::Array[::Array[Telnyx::Models::AI::assistant_tool]],
412
+ ?tools_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::tools_mode,
413
+ ?transcription: Telnyx::AI::TranscriptionSettings,
414
+ ?type: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::type_,
415
+ ?voice_settings: Telnyx::AI::VoiceSettings
416
+ ) -> void
417
+
418
+ def to_hash: -> {
419
+ id: String,
420
+ instructions: String,
421
+ external_llm: Telnyx::AI::ExternalLlm,
422
+ instructions_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::instructions_mode,
423
+ llm_api_key_ref: String,
424
+ model: String,
425
+ name: String,
426
+ position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::Position,
427
+ shared_tool_ids: ::Array[String],
428
+ tools: ::Array[::Array[Telnyx::Models::AI::assistant_tool]],
429
+ tools_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::tools_mode,
430
+ transcription: Telnyx::AI::TranscriptionSettings,
431
+ type: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::type_,
432
+ voice_settings: Telnyx::AI::VoiceSettings
433
+ }
434
+
435
+ type instructions_mode = :replace | :append
436
+
437
+ module InstructionsMode
438
+ extend Telnyx::Internal::Type::Enum
439
+
440
+ REPLACE: :replace
441
+ APPEND: :append
442
+
443
+ def self?.values: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::instructions_mode]
444
+ end
445
+
446
+ type position = { x: Float, y_: Float }
447
+
448
+ class Position < Telnyx::Internal::Type::BaseModel
449
+ attr_accessor x: Float
450
+
451
+ attr_accessor y_: Float
452
+
453
+ def initialize: (x: Float, y_: Float) -> void
454
+
455
+ def to_hash: -> { x: Float, y_: Float }
456
+ end
457
+
458
+ type tools_mode = :replace | :append
459
+
460
+ module ToolsMode
461
+ extend Telnyx::Internal::Type::Enum
462
+
463
+ REPLACE: :replace
464
+ APPEND: :append
465
+
466
+ def self?.values: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::tools_mode]
467
+ end
468
+
469
+ type type_ = :prompt
470
+
471
+ module Type
472
+ extend Telnyx::Internal::Type::Enum
473
+
474
+ PROMPT: :prompt
475
+
476
+ def self?.values: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Prompt::type_]
477
+ end
478
+ end
479
+
480
+ type tool =
481
+ {
482
+ id: String,
483
+ shared_tool_id: String,
484
+ name: String,
485
+ position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Tool::Position,
486
+ tool: ::Array[Telnyx::Models::AI::assistant_tool],
487
+ type: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Tool::type_
488
+ }
489
+
490
+ class Tool < Telnyx::Internal::Type::BaseModel
491
+ attr_accessor id: String
492
+
493
+ attr_accessor shared_tool_id: String
494
+
495
+ attr_reader name: String?
496
+
497
+ def name=: (String) -> String
498
+
499
+ attr_reader position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Tool::Position?
500
+
501
+ def position=: (
502
+ Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Tool::Position
503
+ ) -> Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Tool::Position
504
+
505
+ attr_reader tool: ::Array[Telnyx::Models::AI::assistant_tool]?
506
+
507
+ def tool=: (
508
+ ::Array[Telnyx::Models::AI::assistant_tool]
509
+ ) -> ::Array[Telnyx::Models::AI::assistant_tool]
510
+
511
+ attr_reader type: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Tool::type_?
512
+
513
+ def type=: (
514
+ Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Tool::type_
515
+ ) -> Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Tool::type_
516
+
517
+ def initialize: (
518
+ id: String,
519
+ shared_tool_id: String,
520
+ ?name: String,
521
+ ?position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Tool::Position,
522
+ ?tool: ::Array[Telnyx::Models::AI::assistant_tool],
523
+ ?type: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Tool::type_
524
+ ) -> void
525
+
526
+ def to_hash: -> {
527
+ id: String,
528
+ shared_tool_id: String,
529
+ name: String,
530
+ position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Node::Tool::Position,
531
+ tool: ::Array[Telnyx::Models::AI::assistant_tool],
532
+ type: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Tool::type_
533
+ }
534
+
535
+ type position = { x: Float, y_: Float }
536
+
537
+ class Position < Telnyx::Internal::Type::BaseModel
538
+ attr_accessor x: Float
539
+
540
+ attr_accessor y_: Float
541
+
542
+ def initialize: (x: Float, y_: Float) -> void
543
+
544
+ def to_hash: -> { x: Float, y_: Float }
545
+ end
546
+
547
+ type type_ = :tool
548
+
549
+ module Type
550
+ extend Telnyx::Internal::Type::Enum
551
+
552
+ TOOL: :tool
553
+
554
+ def self?.values: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Node::Tool::type_]
555
+ end
556
+ end
557
+
558
+ def self?.variants: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::node]
559
+ end
560
+
561
+ type edge =
562
+ {
563
+ id: String,
564
+ condition: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::condition,
565
+ start_node_id: String,
566
+ target: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::target
567
+ }
568
+
569
+ class Edge < Telnyx::Internal::Type::BaseModel
570
+ attr_accessor id: String
571
+
572
+ attr_accessor condition: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::condition
573
+
574
+ attr_accessor start_node_id: String
575
+
576
+ attr_accessor target: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::target
577
+
578
+ def initialize: (
579
+ id: String,
580
+ condition: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::condition,
581
+ start_node_id: String,
582
+ target: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::target
583
+ ) -> void
584
+
585
+ def to_hash: -> {
586
+ id: String,
587
+ condition: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::condition,
588
+ start_node_id: String,
589
+ target: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::target
590
+ }
591
+
592
+ type condition =
593
+ Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Llm
594
+ | Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression
595
+
596
+ module Condition
597
+ extend Telnyx::Internal::Type::Union
598
+
599
+ type llm = { prompt: String, type: :llm }
600
+
601
+ class Llm < Telnyx::Internal::Type::BaseModel
602
+ attr_accessor prompt: String
603
+
604
+ attr_accessor type: :llm
605
+
606
+ def initialize: (prompt: String, ?type: :llm) -> void
607
+
608
+ def to_hash: -> { prompt: String, type: :llm }
609
+ end
610
+
611
+ type expression =
612
+ {
613
+ expression: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::expression,
614
+ type: :expression
615
+ }
616
+
617
+ class Expression < Telnyx::Internal::Type::BaseModel
618
+ attr_accessor expression: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::expression
619
+
620
+ attr_accessor type: :expression
621
+
622
+ def initialize: (
623
+ expression: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::expression,
624
+ ?type: :expression
625
+ ) -> void
626
+
627
+ def to_hash: -> {
628
+ expression: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::expression,
629
+ type: :expression
630
+ }
631
+
632
+ type expression =
633
+ top
634
+ | Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::Expression::DynamicVariableExpression
635
+ | Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::Expression::StringLiteralExpression
636
+ | Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::Expression::NumberLiteralExpression
637
+ | Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::Expression::BooleanLiteralExpression
638
+
639
+ module Expression
640
+ extend Telnyx::Internal::Type::Union
641
+
642
+ type dynamic_variable_expression =
643
+ { name: String, type: :variable }
644
+
645
+ class DynamicVariableExpression < Telnyx::Internal::Type::BaseModel
646
+ attr_accessor name: String
647
+
648
+ attr_accessor type: :variable
649
+
650
+ def initialize: (name: String, ?type: :variable) -> void
651
+
652
+ def to_hash: -> { name: String, type: :variable }
653
+ end
654
+
655
+ type string_literal_expression =
656
+ { type: :string_literal, value: String }
657
+
658
+ class StringLiteralExpression < Telnyx::Internal::Type::BaseModel
659
+ attr_accessor type: :string_literal
660
+
661
+ attr_accessor value: String
662
+
663
+ def initialize: (
664
+ value: String,
665
+ ?type: :string_literal
666
+ ) -> void
667
+
668
+ def to_hash: -> { type: :string_literal, value: String }
669
+ end
670
+
671
+ type number_literal_expression =
672
+ { type: :number_literal, value: Float }
673
+
674
+ class NumberLiteralExpression < Telnyx::Internal::Type::BaseModel
675
+ attr_accessor type: :number_literal
676
+
677
+ attr_accessor value: Float
678
+
679
+ def initialize: (
680
+ value: Float,
681
+ ?type: :number_literal
682
+ ) -> void
683
+
684
+ def to_hash: -> { type: :number_literal, value: Float }
685
+ end
686
+
687
+ type boolean_literal_expression =
688
+ { type: :bool_literal, value: bool }
689
+
690
+ class BooleanLiteralExpression < Telnyx::Internal::Type::BaseModel
691
+ attr_accessor type: :bool_literal
692
+
693
+ attr_accessor value: bool
694
+
695
+ def initialize: (value: bool, ?type: :bool_literal) -> void
696
+
697
+ def to_hash: -> { type: :bool_literal, value: bool }
698
+ end
699
+
700
+ def self?.variants: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Condition::Expression::expression]
701
+ end
702
+ end
703
+
704
+ def self?.variants: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::condition]
705
+ end
706
+
707
+ type target =
708
+ Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Node
709
+ | Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant
710
+
711
+ module Target
712
+ extend Telnyx::Internal::Type::Union
713
+
714
+ type node = { node_id: String, type: :node }
715
+
716
+ class Node < Telnyx::Internal::Type::BaseModel
717
+ attr_accessor node_id: String
718
+
719
+ attr_accessor type: :node
720
+
721
+ def initialize: (node_id: String, ?type: :node) -> void
722
+
723
+ def to_hash: -> { node_id: String, type: :node }
724
+ end
725
+
726
+ type assistant =
727
+ {
728
+ assistant_id: String,
729
+ type: :assistant,
730
+ position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::Position,
731
+ voice_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::voice_mode
732
+ }
733
+
734
+ class Assistant < Telnyx::Internal::Type::BaseModel
735
+ attr_accessor assistant_id: String
736
+
737
+ attr_accessor type: :assistant
738
+
739
+ attr_reader position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::Position?
740
+
741
+ def position=: (
742
+ Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::Position
743
+ ) -> Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::Position
744
+
745
+ attr_reader voice_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::voice_mode?
746
+
747
+ def voice_mode=: (
748
+ Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::voice_mode
749
+ ) -> Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::voice_mode
750
+
751
+ def initialize: (
752
+ assistant_id: String,
753
+ ?position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::Position,
754
+ ?voice_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::voice_mode,
755
+ ?type: :assistant
756
+ ) -> void
757
+
758
+ def to_hash: -> {
759
+ assistant_id: String,
760
+ type: :assistant,
761
+ position: Telnyx::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::Position,
762
+ voice_mode: Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::voice_mode
763
+ }
764
+
765
+ type position = { x: Float, y_: Float }
766
+
767
+ class Position < Telnyx::Internal::Type::BaseModel
768
+ attr_accessor x: Float
769
+
770
+ attr_accessor y_: Float
771
+
772
+ def initialize: (x: Float, y_: Float) -> void
773
+
774
+ def to_hash: -> { x: Float, y_: Float }
775
+ end
776
+
777
+ type voice_mode = :unified | :distinct
778
+
779
+ module VoiceMode
780
+ extend Telnyx::Internal::Type::Enum
781
+
782
+ UNIFIED: :unified
783
+ DISTINCT: :distinct
784
+
785
+ def self?.values: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::Target::Assistant::voice_mode]
786
+ end
787
+ end
788
+
789
+ def self?.variants: -> ::Array[Telnyx::Models::AI::InferenceEmbedding::ConversationFlow::Edge::target]
790
+ end
791
+ end
792
+ end
267
793
  end
268
794
  end
269
795
  end
@@ -1,9 +1,9 @@
1
1
  module Telnyx
2
2
  module Models
3
- type ai_create_response_params =
3
+ type ai_create_response_deprecated_params =
4
4
  { body: ::Hash[Symbol, top] } & Telnyx::Internal::Type::request_parameters
5
5
 
6
- class AICreateResponseParams < Telnyx::Internal::Type::BaseModel
6
+ class AICreateResponseDeprecatedParams < Telnyx::Internal::Type::BaseModel
7
7
  extend Telnyx::Internal::Type::RequestParameters::Converter
8
8
  include Telnyx::Internal::Type::RequestParameters
9
9
 
@@ -0,0 +1,7 @@
1
+ module Telnyx
2
+ module Models
3
+ type ai_create_response_deprecated_response = ::Hash[Symbol, top]
4
+
5
+ AICreateResponseDeprecatedResponse: Telnyx::Internal::Type::Converter
6
+ end
7
+ end