telnyx 3.1.0a0__py3-none-any.whl → 3.2.0__py3-none-any.whl

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.

Potentially problematic release.


This version of telnyx might be problematic. Click here for more details.

Files changed (564) hide show
  1. telnyx/__init__.py +3 -1
  2. telnyx/_base_client.py +12 -12
  3. telnyx/_client.py +68 -762
  4. telnyx/_compat.py +48 -48
  5. telnyx/_models.py +50 -44
  6. telnyx/_qs.py +7 -7
  7. telnyx/_types.py +53 -12
  8. telnyx/_utils/__init__.py +9 -2
  9. telnyx/_utils/_compat.py +45 -0
  10. telnyx/_utils/_datetime_parse.py +136 -0
  11. telnyx/_utils/_transform.py +13 -3
  12. telnyx/_utils/_typing.py +6 -1
  13. telnyx/_utils/_utils.py +4 -5
  14. telnyx/_version.py +1 -1
  15. telnyx/resources/__init__.py +73 -0
  16. telnyx/resources/access_ip_address.py +15 -15
  17. telnyx/resources/access_ip_ranges.py +13 -13
  18. telnyx/resources/actions/purchase.py +13 -14
  19. telnyx/resources/actions/register.py +11 -12
  20. telnyx/resources/addresses/actions.py +13 -13
  21. telnyx/resources/addresses/addresses.py +33 -35
  22. telnyx/resources/advanced_orders.py +102 -106
  23. telnyx/resources/ai/ai.py +7 -7
  24. telnyx/resources/ai/assistants/assistants.py +89 -89
  25. telnyx/resources/ai/assistants/canary_deploys.py +9 -9
  26. telnyx/resources/ai/assistants/scheduled_events.py +21 -21
  27. telnyx/resources/ai/assistants/tests/runs.py +13 -13
  28. telnyx/resources/ai/assistants/tests/test_suites/runs.py +13 -13
  29. telnyx/resources/ai/assistants/tests/test_suites/test_suites.py +3 -3
  30. telnyx/resources/ai/assistants/tests/tests.py +43 -43
  31. telnyx/resources/ai/assistants/tools.py +7 -7
  32. telnyx/resources/ai/assistants/versions.py +45 -45
  33. telnyx/resources/ai/audio.py +11 -11
  34. telnyx/resources/ai/chat.py +48 -48
  35. telnyx/resources/ai/clusters.py +27 -29
  36. telnyx/resources/ai/conversations/conversations.py +179 -45
  37. telnyx/resources/ai/conversations/insight_groups/insight_groups.py +23 -23
  38. telnyx/resources/ai/conversations/insight_groups/insights.py +5 -5
  39. telnyx/resources/ai/conversations/insights.py +25 -25
  40. telnyx/resources/ai/conversations/messages.py +3 -136
  41. telnyx/resources/ai/embeddings/buckets.py +7 -7
  42. telnyx/resources/ai/embeddings/embeddings.py +23 -24
  43. telnyx/resources/ai/fine_tuning/jobs.py +13 -13
  44. telnyx/resources/audit_events.py +9 -9
  45. telnyx/resources/authentication_providers.py +29 -29
  46. telnyx/resources/available_phone_number_blocks.py +5 -5
  47. telnyx/resources/available_phone_numbers.py +5 -5
  48. telnyx/resources/balance.py +3 -3
  49. telnyx/resources/billing_groups.py +17 -17
  50. telnyx/resources/brand/brand.py +121 -117
  51. telnyx/resources/brand/external_vetting.py +9 -9
  52. telnyx/resources/bulk_sim_card_actions.py +11 -11
  53. telnyx/resources/bundle_pricing/billing_bundles.py +13 -13
  54. telnyx/resources/bundle_pricing/user_bundles.py +35 -35
  55. telnyx/resources/call_control_applications.py +64 -68
  56. telnyx/resources/call_events.py +7 -7
  57. telnyx/resources/calls/actions.py +695 -697
  58. telnyx/resources/calls/calls.py +116 -110
  59. telnyx/resources/campaign/campaign.py +47 -47
  60. telnyx/resources/campaign/osr.py +3 -3
  61. telnyx/resources/campaign/usecase.py +3 -3
  62. telnyx/resources/campaign_builder/brand.py +3 -3
  63. telnyx/resources/campaign_builder/campaign_builder.py +68 -68
  64. telnyx/resources/channel_zones.py +7 -7
  65. telnyx/resources/charges_breakdown.py +7 -7
  66. telnyx/resources/charges_summary.py +3 -3
  67. telnyx/resources/comments.py +17 -17
  68. telnyx/resources/conferences/actions.py +123 -140
  69. telnyx/resources/conferences/conferences.py +37 -41
  70. telnyx/resources/connections.py +15 -15
  71. telnyx/resources/country_coverage.py +5 -5
  72. telnyx/resources/credential_connections/actions.py +3 -3
  73. telnyx/resources/credential_connections/credential_connections.py +96 -96
  74. telnyx/resources/custom_storage_credentials.py +9 -9
  75. telnyx/resources/customer_service_records.py +21 -23
  76. telnyx/resources/detail_records.py +9 -11
  77. telnyx/resources/dialogflow_connections.py +25 -25
  78. telnyx/resources/document_links.py +7 -7
  79. telnyx/resources/documents.py +124 -43
  80. telnyx/resources/dynamic_emergency_addresses.py +23 -23
  81. telnyx/resources/dynamic_emergency_endpoints.py +13 -13
  82. telnyx/resources/enum.py +3 -3
  83. telnyx/resources/external_connections/civic_addresses.py +7 -7
  84. telnyx/resources/external_connections/external_connections.py +42 -42
  85. telnyx/resources/external_connections/log_messages.py +11 -11
  86. telnyx/resources/external_connections/phone_numbers.py +13 -13
  87. telnyx/resources/external_connections/releases.py +9 -9
  88. telnyx/resources/external_connections/uploads.py +27 -29
  89. telnyx/resources/fax_applications.py +48 -48
  90. telnyx/resources/faxes/actions.py +5 -5
  91. telnyx/resources/faxes/faxes.py +35 -35
  92. telnyx/resources/fqdn_connections.py +94 -94
  93. telnyx/resources/fqdns.py +25 -25
  94. telnyx/resources/global_ip_allowed_ports.py +3 -3
  95. telnyx/resources/global_ip_assignment_health.py +5 -5
  96. telnyx/resources/global_ip_assignments.py +19 -19
  97. telnyx/resources/global_ip_assignments_usage.py +5 -5
  98. telnyx/resources/global_ip_health_check_types.py +3 -3
  99. telnyx/resources/global_ip_health_checks.py +17 -17
  100. telnyx/resources/global_ip_latency.py +5 -5
  101. telnyx/resources/global_ip_protocols.py +3 -3
  102. telnyx/resources/global_ip_usage.py +5 -5
  103. telnyx/resources/global_ips.py +17 -17
  104. telnyx/resources/inbound_channels.py +5 -5
  105. telnyx/resources/integration_secrets.py +17 -17
  106. telnyx/resources/inventory_coverage.py +5 -5
  107. telnyx/resources/invoices.py +11 -11
  108. telnyx/resources/ip_connections.py +94 -94
  109. telnyx/resources/ips.py +23 -23
  110. telnyx/resources/ledger_billing_group_reports.py +9 -9
  111. telnyx/resources/legacy/__init__.py +33 -0
  112. telnyx/resources/legacy/legacy.py +102 -0
  113. telnyx/resources/legacy/reporting/__init__.py +47 -0
  114. telnyx/resources/legacy/reporting/batch_detail_records/__init__.py +61 -0
  115. telnyx/resources/legacy/reporting/batch_detail_records/batch_detail_records.py +166 -0
  116. telnyx/resources/legacy/reporting/batch_detail_records/messaging.py +482 -0
  117. telnyx/resources/legacy/reporting/batch_detail_records/speech_to_text.py +399 -0
  118. telnyx/resources/legacy/reporting/batch_detail_records/voice.py +539 -0
  119. telnyx/resources/legacy/reporting/reporting.py +134 -0
  120. telnyx/resources/legacy/reporting/usage_reports/__init__.py +61 -0
  121. telnyx/resources/legacy/reporting/usage_reports/messaging.py +471 -0
  122. telnyx/resources/legacy/reporting/usage_reports/number_lookup.py +464 -0
  123. telnyx/resources/legacy/reporting/usage_reports/usage_reports.py +288 -0
  124. telnyx/resources/legacy/reporting/usage_reports/voice.py +493 -0
  125. telnyx/resources/list.py +5 -5
  126. telnyx/resources/managed_accounts/actions.py +7 -7
  127. telnyx/resources/managed_accounts/managed_accounts.py +33 -33
  128. telnyx/resources/media.py +23 -23
  129. telnyx/resources/messages/messages.py +124 -124
  130. telnyx/resources/messages/rcs.py +7 -7
  131. telnyx/resources/messaging/rcs/agents.py +15 -15
  132. telnyx/resources/messaging/rcs/rcs.py +9 -11
  133. telnyx/resources/messaging_hosted_number_orders/actions.py +7 -7
  134. telnyx/resources/messaging_hosted_number_orders/messaging_hosted_number_orders.py +26 -26
  135. telnyx/resources/messaging_hosted_numbers.py +3 -3
  136. telnyx/resources/messaging_numbers_bulk_updates.py +7 -9
  137. telnyx/resources/messaging_optouts.py +11 -11
  138. telnyx/resources/messaging_profiles/autoresp_configs.py +25 -26
  139. telnyx/resources/messaging_profiles/messaging_profiles.py +76 -76
  140. telnyx/resources/messaging_tollfree/verification/requests.py +27 -27
  141. telnyx/resources/messaging_url_domains.py +5 -5
  142. telnyx/resources/messsages.py +11 -11
  143. telnyx/resources/mobile_network_operators.py +7 -7
  144. telnyx/resources/mobile_push_credentials.py +23 -23
  145. telnyx/resources/network_coverage.py +9 -9
  146. telnyx/resources/networks/default_gateway.py +9 -9
  147. telnyx/resources/networks/networks.py +21 -21
  148. telnyx/resources/notification_channels.py +27 -27
  149. telnyx/resources/notification_event_conditions.py +7 -7
  150. telnyx/resources/notification_events.py +5 -5
  151. telnyx/resources/notification_profiles.py +17 -17
  152. telnyx/resources/notification_settings.py +21 -21
  153. telnyx/resources/number_block_orders.py +17 -17
  154. telnyx/resources/number_lookup.py +5 -5
  155. telnyx/resources/number_order_phone_numbers.py +13 -13
  156. telnyx/resources/number_orders.py +27 -27
  157. telnyx/resources/number_reservations/actions.py +3 -3
  158. telnyx/resources/number_reservations/number_reservations.py +15 -15
  159. telnyx/resources/numbers_features.py +5 -7
  160. telnyx/resources/oauth.py +855 -0
  161. telnyx/resources/oauth_clients.py +711 -0
  162. telnyx/resources/oauth_grants.py +349 -0
  163. telnyx/resources/operator_connect/actions.py +3 -3
  164. telnyx/resources/ota_updates.py +9 -9
  165. telnyx/resources/outbound_voice_profiles.py +66 -66
  166. telnyx/resources/partner_campaigns.py +25 -25
  167. telnyx/resources/payment/auto_recharge_prefs.py +15 -15
  168. telnyx/resources/phone_number_assignment_by_profile.py +15 -15
  169. telnyx/resources/phone_number_blocks/jobs.py +13 -13
  170. telnyx/resources/phone_number_campaigns.py +19 -19
  171. telnyx/resources/phone_numbers/actions.py +9 -11
  172. telnyx/resources/phone_numbers/csv_downloads.py +13 -13
  173. telnyx/resources/phone_numbers/jobs.py +54 -42
  174. telnyx/resources/phone_numbers/messaging.py +13 -13
  175. telnyx/resources/phone_numbers/phone_numbers.py +39 -40
  176. telnyx/resources/phone_numbers/voice.py +31 -31
  177. telnyx/resources/phone_numbers/voicemail.py +15 -15
  178. telnyx/resources/phone_numbers_regulatory_requirements.py +5 -5
  179. telnyx/resources/portability_checks.py +5 -7
  180. telnyx/resources/porting/events.py +11 -11
  181. telnyx/resources/porting/loa_configurations.py +17 -17
  182. telnyx/resources/porting/porting.py +3 -3
  183. telnyx/resources/porting/reports.py +11 -11
  184. telnyx/resources/porting_orders/action_requirements.py +11 -11
  185. telnyx/resources/porting_orders/actions.py +13 -13
  186. telnyx/resources/porting_orders/activation_jobs.py +11 -11
  187. telnyx/resources/porting_orders/additional_documents.py +15 -15
  188. telnyx/resources/porting_orders/associated_phone_numbers.py +13 -13
  189. telnyx/resources/porting_orders/comments.py +9 -9
  190. telnyx/resources/porting_orders/phone_number_blocks.py +13 -13
  191. telnyx/resources/porting_orders/phone_number_configurations.py +13 -13
  192. telnyx/resources/porting_orders/phone_number_extensions.py +13 -13
  193. telnyx/resources/porting_orders/porting_orders.py +82 -70
  194. telnyx/resources/porting_orders/verification_codes.py +20 -20
  195. telnyx/resources/porting_phone_numbers.py +7 -7
  196. telnyx/resources/portouts/comments.py +7 -7
  197. telnyx/resources/portouts/events.py +11 -11
  198. telnyx/resources/portouts/portouts.py +17 -17
  199. telnyx/resources/portouts/reports.py +11 -11
  200. telnyx/resources/portouts/supporting_documents.py +7 -7
  201. telnyx/resources/private_wireless_gateways.py +25 -25
  202. telnyx/resources/public_internet_gateways.py +19 -19
  203. telnyx/resources/queues/calls.py +7 -7
  204. telnyx/resources/queues/queues.py +3 -3
  205. telnyx/resources/recording_transcriptions.py +7 -7
  206. telnyx/resources/recordings/actions.py +5 -7
  207. telnyx/resources/recordings/recordings.py +11 -11
  208. telnyx/resources/regions.py +3 -3
  209. telnyx/resources/regulatory_requirements.py +5 -5
  210. telnyx/resources/reports/cdr_usage_reports.py +9 -9
  211. telnyx/resources/reports/mdr_usage_reports.py +22 -22
  212. telnyx/resources/reports/reports.py +47 -48
  213. telnyx/resources/requirement_groups.py +23 -23
  214. telnyx/resources/requirement_types.py +9 -11
  215. telnyx/resources/requirements.py +11 -11
  216. telnyx/resources/room_compositions.py +27 -27
  217. telnyx/resources/room_participants.py +9 -9
  218. telnyx/resources/room_recordings.py +17 -17
  219. telnyx/resources/rooms/actions.py +11 -11
  220. telnyx/resources/rooms/rooms.py +43 -43
  221. telnyx/resources/rooms/sessions/actions.py +22 -22
  222. telnyx/resources/rooms/sessions/sessions.py +27 -27
  223. telnyx/resources/seti.py +5 -5
  224. telnyx/resources/short_codes.py +11 -11
  225. telnyx/resources/sim_card_data_usage_notifications.py +21 -21
  226. telnyx/resources/sim_card_groups/actions.py +23 -23
  227. telnyx/resources/sim_card_groups/sim_card_groups.py +29 -29
  228. telnyx/resources/sim_card_order_preview.py +3 -3
  229. telnyx/resources/sim_card_orders.py +11 -11
  230. telnyx/resources/sim_cards/actions.py +29 -31
  231. telnyx/resources/sim_cards/sim_cards.py +48 -48
  232. telnyx/resources/siprec_connectors.py +13 -13
  233. telnyx/resources/storage/buckets/buckets.py +5 -5
  234. telnyx/resources/storage/buckets/ssl_certificate.py +11 -11
  235. telnyx/resources/storage/buckets/usage.py +5 -5
  236. telnyx/resources/storage/migration_sources.py +11 -11
  237. telnyx/resources/storage/migrations/actions.py +3 -3
  238. telnyx/resources/storage/migrations/migrations.py +9 -9
  239. telnyx/resources/storage/storage.py +3 -3
  240. telnyx/resources/sub_number_orders.py +17 -17
  241. telnyx/resources/sub_number_orders_report.py +19 -19
  242. telnyx/resources/telephony_credentials.py +31 -31
  243. telnyx/resources/texml/accounts/accounts.py +15 -15
  244. telnyx/resources/texml/accounts/calls/calls.py +145 -145
  245. telnyx/resources/texml/accounts/calls/recordings.py +5 -5
  246. telnyx/resources/texml/accounts/calls/recordings_json.py +19 -19
  247. telnyx/resources/texml/accounts/calls/siprec.py +5 -5
  248. telnyx/resources/texml/accounts/calls/streams.py +5 -5
  249. telnyx/resources/texml/accounts/conferences/conferences.py +31 -31
  250. telnyx/resources/texml/accounts/conferences/participants.py +123 -123
  251. telnyx/resources/texml/accounts/recordings/json.py +5 -5
  252. telnyx/resources/texml/accounts/transcriptions/json.py +5 -5
  253. telnyx/resources/texml/calls.py +79 -79
  254. telnyx/resources/texml/texml.py +3 -3
  255. telnyx/resources/texml_applications.py +65 -66
  256. telnyx/resources/text_to_speech.py +9 -9
  257. telnyx/resources/usage_reports.py +31 -32
  258. telnyx/resources/user_addresses.py +29 -31
  259. telnyx/resources/user_tags.py +5 -5
  260. telnyx/resources/verifications/actions.py +7 -7
  261. telnyx/resources/verifications/by_phone_number/actions.py +3 -3
  262. telnyx/resources/verifications/by_phone_number/by_phone_number.py +3 -3
  263. telnyx/resources/verifications/verifications.py +29 -19
  264. telnyx/resources/verified_numbers/actions.py +3 -3
  265. telnyx/resources/verified_numbers/verified_numbers.py +36 -15
  266. telnyx/resources/verify_profiles.py +226 -44
  267. telnyx/resources/virtual_cross_connects.py +45 -45
  268. telnyx/resources/virtual_cross_connects_coverage.py +9 -9
  269. telnyx/resources/webhook_deliveries.py +9 -9
  270. telnyx/resources/webhooks.py +34 -0
  271. telnyx/resources/well_known.py +198 -0
  272. telnyx/resources/wireguard_interfaces.py +17 -17
  273. telnyx/resources/wireguard_peers.py +21 -21
  274. telnyx/resources/wireless/detail_records_reports.py +17 -17
  275. telnyx/resources/wireless/wireless.py +3 -3
  276. telnyx/resources/wireless_blocklist_values.py +3 -3
  277. telnyx/resources/wireless_blocklists.py +29 -30
  278. telnyx/types/__init__.py +167 -13
  279. telnyx/types/actions/purchase_create_params.py +3 -2
  280. telnyx/types/actions/register_create_params.py +4 -3
  281. telnyx/types/addresses/action_validate_response.py +8 -3
  282. telnyx/types/{advanced_order_update_params.py → advanced_order_update_requirement_group_params.py} +2 -2
  283. telnyx/types/ai/__init__.py +1 -0
  284. telnyx/types/ai/chat_create_completion_params.py +3 -2
  285. telnyx/types/ai/cluster_compute_params.py +3 -2
  286. telnyx/types/ai/{conversations/message_create_params.py → conversation_add_message_params.py} +6 -5
  287. telnyx/types/ai/conversations/__init__.py +0 -1
  288. telnyx/types/ai/embedding_list_params.py +3 -2
  289. telnyx/types/ai/inference_embedding_bucket_ids_param.py +3 -2
  290. telnyx/types/ai/inference_embedding_transfer_tool_params.py +6 -0
  291. telnyx/types/ai/inference_embedding_transfer_tool_params_param.py +6 -0
  292. telnyx/types/ai/inference_embedding_webhook_tool_params.py +2 -0
  293. telnyx/types/ai/inference_embedding_webhook_tool_params_param.py +8 -4
  294. telnyx/types/ai/voice_settings.py +49 -2
  295. telnyx/types/ai/voice_settings_param.py +49 -2
  296. telnyx/types/brand_create_params.py +2 -1
  297. telnyx/types/brand_update_params.py +2 -1
  298. telnyx/types/bundle_pricing/billing_bundle_list_params.py +4 -3
  299. telnyx/types/bundle_pricing/user_bundle_list_params.py +4 -3
  300. telnyx/types/bundle_pricing/user_bundle_list_unused_params.py +4 -3
  301. telnyx/types/call_ai_gather_ended_webhook_event.py +78 -0
  302. telnyx/types/call_ai_gather_message_history_updated_webhook_event.py +69 -0
  303. telnyx/types/call_ai_gather_partial_results_webhook_event.py +75 -0
  304. telnyx/types/call_answered_webhook_event.py +75 -0
  305. telnyx/types/call_bridged_webhook_event.py +58 -0
  306. telnyx/types/call_control_application_update_params.py +3 -2
  307. telnyx/types/call_conversation_ended_webhook_event.py +84 -0
  308. telnyx/types/call_conversation_insights_generated_webhook_event.py +67 -0
  309. telnyx/types/call_dial_params.py +14 -6
  310. telnyx/types/call_dtmf_received_webhook_event.py +61 -0
  311. telnyx/types/call_enqueued_webhook_event.py +59 -0
  312. telnyx/types/call_fork_started_webhook_event.py +53 -0
  313. telnyx/types/call_fork_stopped_webhook_event.py +53 -0
  314. telnyx/types/call_gather_ended_webhook_event.py +64 -0
  315. telnyx/types/call_hangup_webhook_event.py +150 -0
  316. telnyx/types/call_initiated_webhook_event.py +96 -0
  317. telnyx/types/call_left_queue_webhook_event.py +62 -0
  318. telnyx/types/call_machine_detection_ended_webhook_event.py +61 -0
  319. telnyx/types/call_machine_greeting_ended_webhook_event.py +61 -0
  320. telnyx/types/call_machine_premium_detection_ended_webhook_event.py +63 -0
  321. telnyx/types/call_machine_premium_greeting_ended_webhook_event.py +61 -0
  322. telnyx/types/call_playback_ended_webhook_event.py +70 -0
  323. telnyx/types/call_playback_started_webhook_event.py +62 -0
  324. telnyx/types/call_recording_error_webhook_event.py +60 -0
  325. telnyx/types/call_recording_saved_webhook_event.py +94 -0
  326. telnyx/types/call_recording_transcription_saved_webhook_event.py +71 -0
  327. telnyx/types/call_refer_completed_webhook_event.py +61 -0
  328. telnyx/types/call_refer_failed_webhook_event.py +61 -0
  329. telnyx/types/call_refer_started_webhook_event.py +61 -0
  330. telnyx/types/call_siprec_failed_webhook_event.py +53 -0
  331. telnyx/types/call_siprec_started_webhook_event.py +50 -0
  332. telnyx/types/call_siprec_stopped_webhook_event.py +53 -0
  333. telnyx/types/call_speak_ended_webhook_event.py +53 -0
  334. telnyx/types/call_speak_started_webhook_event.py +50 -0
  335. telnyx/types/call_streaming_failed_webhook_event.py +70 -0
  336. telnyx/types/call_streaming_started_webhook_event.py +53 -0
  337. telnyx/types/call_streaming_stopped_webhook_event.py +53 -0
  338. telnyx/types/calls/action_answer_params.py +1 -2
  339. telnyx/types/calls/action_gather_using_ai_params.py +5 -8
  340. telnyx/types/calls/action_start_streaming_params.py +4 -2
  341. telnyx/types/calls/action_transfer_params.py +50 -0
  342. telnyx/types/calls/transcription_engine_a_config_param.py +4 -3
  343. telnyx/types/campaign_builder_create_params.py +4 -3
  344. telnyx/types/campaign_status_update_webhook_event.py +26 -0
  345. telnyx/types/campaign_submit_appeal_response.py +0 -3
  346. telnyx/types/conference_created_webhook_event.py +53 -0
  347. telnyx/types/conference_ended_webhook_event.py +56 -0
  348. telnyx/types/conference_floor_changed_webhook_event.py +45 -0
  349. telnyx/types/conference_participant_joined_webhook_event.py +53 -0
  350. telnyx/types/conference_participant_left_webhook_event.py +53 -0
  351. telnyx/types/conference_participant_playback_ended_webhook_event.py +65 -0
  352. telnyx/types/conference_participant_playback_started_webhook_event.py +65 -0
  353. telnyx/types/conference_participant_speak_ended_webhook_event.py +56 -0
  354. telnyx/types/conference_participant_speak_started_webhook_event.py +56 -0
  355. telnyx/types/conference_playback_ended_webhook_event.py +49 -0
  356. telnyx/types/conference_playback_started_webhook_event.py +49 -0
  357. telnyx/types/conference_recording_saved_webhook_event.py +103 -0
  358. telnyx/types/conference_speak_ended_webhook_event.py +40 -0
  359. telnyx/types/conference_speak_started_webhook_event.py +40 -0
  360. telnyx/types/conferences/action_hold_params.py +3 -2
  361. telnyx/types/conferences/action_join_params.py +3 -2
  362. telnyx/types/conferences/action_mute_params.py +3 -2
  363. telnyx/types/conferences/action_play_params.py +2 -2
  364. telnyx/types/conferences/action_speak_params.py +3 -2
  365. telnyx/types/conferences/action_stop_params.py +3 -2
  366. telnyx/types/conferences/action_unhold_params.py +3 -2
  367. telnyx/types/conferences/action_unmute_params.py +3 -2
  368. telnyx/types/conferences/action_update_params.py +3 -2
  369. telnyx/types/country_coverage_retrieve_country_response.py +7 -0
  370. telnyx/types/country_coverage_retrieve_response.py +7 -0
  371. telnyx/types/credential_connection_create_params.py +3 -2
  372. telnyx/types/credential_connection_update_params.py +3 -2
  373. telnyx/types/credential_inbound_param.py +3 -2
  374. telnyx/types/custom_sip_header.py +13 -0
  375. telnyx/types/customer_service_record_list_params.py +2 -1
  376. telnyx/types/customer_service_record_status_changed_webhook_event.py +55 -0
  377. telnyx/types/customer_service_record_verify_phone_number_coverage_params.py +3 -2
  378. telnyx/types/delivery_update_webhook_event.py +40 -0
  379. telnyx/types/detail_record_list_params.py +4 -2
  380. telnyx/types/document_generate_download_link_response.py +14 -0
  381. telnyx/types/document_list_params.py +2 -1
  382. telnyx/types/external_connection_create_params.py +4 -2
  383. telnyx/types/external_connection_update_params.py +4 -2
  384. telnyx/types/external_connections/civic_address_list_params.py +3 -2
  385. telnyx/types/external_connections/upload_create_params.py +3 -1
  386. telnyx/types/fax_application_create_params.py +3 -2
  387. telnyx/types/fax_application_update_params.py +3 -2
  388. telnyx/types/fax_delivered_webhook_event.py +69 -0
  389. telnyx/types/fax_failed_webhook_event.py +66 -0
  390. telnyx/types/fax_media_processed_webhook_event.py +63 -0
  391. telnyx/types/fax_queued_webhook_event.py +63 -0
  392. telnyx/types/fax_sending_started_webhook_event.py +63 -0
  393. telnyx/types/fqdn_connection_create_params.py +3 -2
  394. telnyx/types/fqdn_connection_update_params.py +3 -2
  395. telnyx/types/global_ip_latency_retrieve_response.py +7 -7
  396. telnyx/types/inbound_fqdn_param.py +4 -2
  397. telnyx/types/inbound_ip_param.py +3 -2
  398. telnyx/types/inbound_message_webhook_event.py +227 -0
  399. telnyx/types/ip_connection_create_params.py +4 -3
  400. telnyx/types/ip_connection_update_params.py +3 -2
  401. telnyx/types/legacy/__init__.py +3 -0
  402. telnyx/types/legacy/reporting/__init__.py +12 -0
  403. telnyx/types/legacy/reporting/batch_detail_records/__init__.py +23 -0
  404. telnyx/types/legacy/reporting/batch_detail_records/cdr_detailed_req_response.py +63 -0
  405. telnyx/types/legacy/reporting/batch_detail_records/mdr_detail_report_response.py +42 -0
  406. telnyx/types/legacy/reporting/batch_detail_records/messaging_create_params.py +55 -0
  407. telnyx/types/legacy/reporting/batch_detail_records/messaging_create_response.py +12 -0
  408. telnyx/types/legacy/reporting/batch_detail_records/messaging_delete_response.py +12 -0
  409. telnyx/types/legacy/reporting/batch_detail_records/messaging_list_response.py +24 -0
  410. telnyx/types/legacy/reporting/batch_detail_records/messaging_retrieve_response.py +12 -0
  411. telnyx/types/legacy/reporting/batch_detail_records/speech_to_text_create_params.py +19 -0
  412. telnyx/types/legacy/reporting/batch_detail_records/speech_to_text_create_response.py +12 -0
  413. telnyx/types/legacy/reporting/batch_detail_records/speech_to_text_delete_response.py +12 -0
  414. telnyx/types/legacy/reporting/batch_detail_records/speech_to_text_list_response.py +12 -0
  415. telnyx/types/legacy/reporting/batch_detail_records/speech_to_text_retrieve_response.py +12 -0
  416. telnyx/types/legacy/reporting/batch_detail_records/stt_detail_report_response.py +27 -0
  417. telnyx/types/legacy/reporting/batch_detail_records/voice_create_params.py +57 -0
  418. telnyx/types/legacy/reporting/batch_detail_records/voice_create_response.py +13 -0
  419. telnyx/types/legacy/reporting/batch_detail_records/voice_delete_response.py +13 -0
  420. telnyx/types/legacy/reporting/batch_detail_records/voice_list_response.py +24 -0
  421. telnyx/types/legacy/reporting/batch_detail_records/voice_retrieve_fields_response.py +23 -0
  422. telnyx/types/legacy/reporting/batch_detail_records/voice_retrieve_response.py +13 -0
  423. telnyx/types/legacy/reporting/filter.py +31 -0
  424. telnyx/types/legacy/reporting/filter_param.py +30 -0
  425. telnyx/types/legacy/reporting/usage_report_retrieve_speech_to_text_params.py +17 -0
  426. telnyx/types/legacy/reporting/usage_report_retrieve_speech_to_text_response.py +11 -0
  427. telnyx/types/legacy/reporting/usage_reports/__init__.py +20 -0
  428. telnyx/types/legacy/reporting/usage_reports/cdr_usage_report_response_legacy.py +43 -0
  429. telnyx/types/legacy/reporting/usage_reports/mdr_usage_report_response_legacy.py +38 -0
  430. telnyx/types/legacy/reporting/usage_reports/messaging_create_params.py +29 -0
  431. telnyx/types/legacy/reporting/usage_reports/messaging_create_response.py +13 -0
  432. telnyx/types/legacy/reporting/usage_reports/messaging_delete_response.py +13 -0
  433. telnyx/types/legacy/reporting/usage_reports/messaging_list_params.py +15 -0
  434. telnyx/types/legacy/reporting/usage_reports/messaging_list_response.py +24 -0
  435. telnyx/types/legacy/reporting/usage_reports/messaging_retrieve_response.py +13 -0
  436. telnyx/types/legacy/reporting/usage_reports/number_lookup_create_params.py +26 -0
  437. telnyx/types/legacy/reporting/usage_reports/number_lookup_list_params.py +13 -0
  438. telnyx/types/legacy/reporting/usage_reports/voice_create_params.py +40 -0
  439. telnyx/types/legacy/reporting/usage_reports/voice_create_response.py +13 -0
  440. telnyx/types/legacy/reporting/usage_reports/voice_delete_response.py +13 -0
  441. telnyx/types/legacy/reporting/usage_reports/voice_list_params.py +15 -0
  442. telnyx/types/legacy/reporting/usage_reports/voice_list_response.py +24 -0
  443. telnyx/types/legacy/reporting/usage_reports/voice_retrieve_response.py +13 -0
  444. telnyx/types/media_list_params.py +3 -2
  445. telnyx/types/message_schedule_params.py +3 -2
  446. telnyx/types/message_send_group_mms_params.py +3 -3
  447. telnyx/types/message_send_long_code_params.py +2 -2
  448. telnyx/types/message_send_number_pool_params.py +3 -2
  449. telnyx/types/message_send_params.py +3 -2
  450. telnyx/types/message_send_short_code_params.py +2 -2
  451. telnyx/types/messaging/rc_list_bulk_capabilities_params.py +3 -2
  452. telnyx/types/messaging_hosted_number_order_check_eligibility_params.py +3 -2
  453. telnyx/types/messaging_hosted_number_order_create_params.py +3 -2
  454. telnyx/types/messaging_hosted_number_order_create_verification_codes_params.py +3 -2
  455. telnyx/types/messaging_numbers_bulk_update_create_params.py +3 -2
  456. telnyx/types/messaging_profile_create_params.py +3 -2
  457. telnyx/types/messaging_profile_update_params.py +3 -2
  458. telnyx/types/messaging_profiles/autoresp_config_create_params.py +3 -2
  459. telnyx/types/messaging_profiles/autoresp_config_update_params.py +3 -2
  460. telnyx/types/messsage_rcs_params.py +2 -2
  461. telnyx/types/number_order_status_update_webhook_event.py +38 -0
  462. telnyx/types/numbers_feature_create_params.py +3 -2
  463. telnyx/types/oauth_client.py +59 -0
  464. telnyx/types/oauth_client_create_params.py +39 -0
  465. telnyx/types/oauth_client_create_response.py +12 -0
  466. telnyx/types/oauth_client_list_params.py +38 -0
  467. telnyx/types/oauth_client_list_response.py +28 -0
  468. telnyx/types/oauth_client_retrieve_response.py +12 -0
  469. telnyx/types/oauth_client_update_params.py +36 -0
  470. telnyx/types/oauth_client_update_response.py +12 -0
  471. telnyx/types/oauth_grant.py +29 -0
  472. telnyx/types/oauth_grant_delete_response.py +12 -0
  473. telnyx/types/oauth_grant_list_params.py +17 -0
  474. telnyx/types/oauth_grant_list_response.py +28 -0
  475. telnyx/types/oauth_grant_retrieve_response.py +12 -0
  476. telnyx/types/oauth_grants_params.py +15 -0
  477. telnyx/types/oauth_grants_response.py +10 -0
  478. telnyx/types/oauth_introspect_params.py +12 -0
  479. telnyx/types/oauth_introspect_response.py +30 -0
  480. telnyx/types/oauth_register_params.py +39 -0
  481. telnyx/types/oauth_register_response.py +45 -0
  482. telnyx/types/oauth_retrieve_authorize_params.py +30 -0
  483. telnyx/types/oauth_retrieve_jwks_response.py +25 -0
  484. telnyx/types/oauth_retrieve_response.py +47 -0
  485. telnyx/types/oauth_token_params.py +33 -0
  486. telnyx/types/oauth_token_response.py +25 -0
  487. telnyx/types/outbound_call_recording_param.py +3 -2
  488. telnyx/types/outbound_voice_profile_create_params.py +4 -3
  489. telnyx/types/outbound_voice_profile_update_params.py +4 -3
  490. telnyx/types/phone_number_delete_response.py +7 -0
  491. telnyx/types/phone_number_detailed.py +7 -0
  492. telnyx/types/phone_number_list_params.py +9 -2
  493. telnyx/types/phone_number_slim_list_params.py +3 -2
  494. telnyx/types/phone_number_update_params.py +3 -2
  495. telnyx/types/phone_numbers/action_verify_ownership_params.py +3 -2
  496. telnyx/types/phone_numbers/job_delete_batch_params.py +3 -2
  497. telnyx/types/phone_numbers/job_update_batch_params.py +10 -3
  498. telnyx/types/phone_numbers/job_update_emergency_settings_batch_params.py +4 -2
  499. telnyx/types/portability_check_run_params.py +3 -2
  500. telnyx/types/porting/export_porting_orders_csv_report_param.py +2 -1
  501. telnyx/types/porting_order.py +3 -0
  502. telnyx/types/porting_order_create_params.py +6 -2
  503. telnyx/types/porting_order_list_params.py +52 -31
  504. telnyx/types/porting_order_phone_number_configuration_param.py +3 -2
  505. telnyx/types/porting_order_update_params.py +2 -0
  506. telnyx/types/porting_orders/action_requirement_list_params.py +3 -2
  507. telnyx/types/porting_orders/phone_number_block_list_params.py +5 -3
  508. telnyx/types/porting_orders/phone_number_configuration_list_params.py +22 -21
  509. telnyx/types/porting_orders/verification_code_send_params.py +3 -2
  510. telnyx/types/portout_list_params.py +2 -1
  511. telnyx/types/portouts/export_portouts_csv_report_param.py +3 -2
  512. telnyx/types/recordings/action_delete_params.py +3 -2
  513. telnyx/types/replaced_link_click_webhook_event.py +32 -0
  514. telnyx/types/report_list_wdrs_params.py +3 -2
  515. telnyx/types/reports/mdr_usage_report_fetch_sync_params.py +3 -2
  516. telnyx/types/rooms/sessions/action_kick_params.py +5 -3
  517. telnyx/types/rooms/sessions/action_mute_params.py +5 -3
  518. telnyx/types/rooms/sessions/action_unmute_params.py +5 -3
  519. telnyx/types/shared/__init__.py +1 -0
  520. telnyx/types/{error.py → shared/api_error.py} +3 -3
  521. telnyx/types/shared/simple_sim_card.py +15 -0
  522. telnyx/types/sim_card.py +12 -0
  523. telnyx/types/sim_card_list_params.py +2 -1
  524. telnyx/types/sim_card_update_params.py +4 -3
  525. telnyx/types/sim_cards/action_bulk_set_public_ips_params.py +3 -2
  526. telnyx/types/sim_cards/action_validate_registration_codes_params.py +3 -2
  527. telnyx/types/sip_header.py +15 -0
  528. telnyx/types/stream_bidirectional_codec.py +1 -1
  529. telnyx/types/stream_codec.py +1 -1
  530. telnyx/types/streaming_failed_webhook_event.py +70 -0
  531. telnyx/types/streaming_started_webhook_event.py +53 -0
  532. telnyx/types/streaming_stopped_webhook_event.py +53 -0
  533. telnyx/types/texml_application_create_params.py +2 -2
  534. telnyx/types/texml_application_update_params.py +2 -2
  535. telnyx/types/transcription_webhook_event.py +72 -0
  536. telnyx/types/unwrap_webhook_event.py +138 -0
  537. telnyx/types/usage_report_list_params.py +5 -4
  538. telnyx/types/verification_trigger_call_params.py +7 -0
  539. telnyx/types/verified_number_create_params.py +10 -0
  540. telnyx/types/verify_profile.py +18 -3
  541. telnyx/types/verify_profile_create_params.py +6 -4
  542. telnyx/types/verify_profile_create_template_params.py +12 -0
  543. telnyx/types/verify_profile_create_template_response.py +12 -0
  544. telnyx/types/verify_profile_message_template_response.py +13 -0
  545. telnyx/types/verify_profile_retrieve_templates_response.py +4 -9
  546. telnyx/types/verify_profile_update_params.py +6 -4
  547. telnyx/types/verify_profile_update_template_params.py +12 -0
  548. telnyx/types/verify_profile_update_template_response.py +12 -0
  549. telnyx/types/video_region_param.py +4 -2
  550. telnyx/types/well_known_retrieve_authorization_server_metadata_response.py +42 -0
  551. telnyx/types/well_known_retrieve_protected_resource_metadata_response.py +15 -0
  552. telnyx/types/wireless_blocklist_create_params.py +3 -2
  553. telnyx/types/wireless_blocklist_update_params.py +3 -2
  554. {telnyx-3.1.0a0.dist-info → telnyx-3.2.0.dist-info}/METADATA +60 -19
  555. {telnyx-3.1.0a0.dist-info → telnyx-3.2.0.dist-info}/RECORD +557 -401
  556. telnyx/types/client_create_bucket_params.py +0 -13
  557. telnyx/types/client_delete_objects_params.py +0 -20
  558. telnyx/types/client_get_object_params.py +0 -15
  559. telnyx/types/client_list_objects_params.py +0 -13
  560. telnyx/types/client_put_object_params.py +0 -20
  561. telnyx/types/list_buckets_response.py +0 -20
  562. telnyx/types/list_objects_response.py +0 -24
  563. {telnyx-3.1.0a0.dist-info → telnyx-3.2.0.dist-info}/WHEEL +0 -0
  564. {telnyx-3.1.0a0.dist-info → telnyx-3.2.0.dist-info}/licenses/LICENSE +0 -0
@@ -13,7 +13,7 @@ from ...types import (
13
13
  StreamBidirectionalCodec,
14
14
  StreamBidirectionalTargetLegs,
15
15
  )
16
- from ..._types import NOT_GIVEN, Body, Query, Headers, NotGiven
16
+ from ..._types import Body, Omit, Query, Headers, NotGiven, omit, not_given
17
17
  from ..._utils import maybe_transform, async_maybe_transform
18
18
  from ..._compat import cached_property
19
19
  from ..._resource import SyncAPIResource, AsyncAPIResource
@@ -141,47 +141,45 @@ class ActionsResource(SyncAPIResource):
141
141
  self,
142
142
  call_control_id: str,
143
143
  *,
144
- billing_group_id: str | NotGiven = NOT_GIVEN,
145
- client_state: str | NotGiven = NOT_GIVEN,
146
- command_id: str | NotGiven = NOT_GIVEN,
147
- custom_headers: Iterable[CustomSipHeaderParam] | NotGiven = NOT_GIVEN,
148
- preferred_codecs: Literal["G722,PCMU,PCMA,G729,OPUS,VP8,H264"] | NotGiven = NOT_GIVEN,
149
- record: Literal["record-from-answer"] | NotGiven = NOT_GIVEN,
150
- record_channels: Literal["single", "dual"] | NotGiven = NOT_GIVEN,
151
- record_custom_file_name: str | NotGiven = NOT_GIVEN,
152
- record_format: Literal["wav", "mp3"] | NotGiven = NOT_GIVEN,
153
- record_max_length: int | NotGiven = NOT_GIVEN,
154
- record_timeout_secs: int | NotGiven = NOT_GIVEN,
155
- record_track: Literal["both", "inbound", "outbound"] | NotGiven = NOT_GIVEN,
156
- record_trim: Literal["trim-silence"] | NotGiven = NOT_GIVEN,
157
- send_silence_when_idle: bool | NotGiven = NOT_GIVEN,
158
- sip_headers: Iterable[SipHeaderParam] | NotGiven = NOT_GIVEN,
159
- sound_modifications: SoundModificationsParam | NotGiven = NOT_GIVEN,
160
- stream_bidirectional_codec: StreamBidirectionalCodec | NotGiven = NOT_GIVEN,
161
- stream_bidirectional_mode: StreamBidirectionalMode | NotGiven = NOT_GIVEN,
162
- stream_bidirectional_target_legs: StreamBidirectionalTargetLegs | NotGiven = NOT_GIVEN,
163
- stream_codec: StreamCodec | NotGiven = NOT_GIVEN,
164
- stream_track: Literal["inbound_track", "outbound_track", "both_tracks"] | NotGiven = NOT_GIVEN,
165
- stream_url: str | NotGiven = NOT_GIVEN,
166
- transcription: bool | NotGiven = NOT_GIVEN,
167
- transcription_config: TranscriptionStartRequestParam | NotGiven = NOT_GIVEN,
168
- webhook_url: str | NotGiven = NOT_GIVEN,
169
- webhook_url_method: Literal["POST", "GET"] | NotGiven = NOT_GIVEN,
144
+ billing_group_id: str | Omit = omit,
145
+ client_state: str | Omit = omit,
146
+ command_id: str | Omit = omit,
147
+ custom_headers: Iterable[CustomSipHeaderParam] | Omit = omit,
148
+ preferred_codecs: Literal["G722,PCMU,PCMA,G729,OPUS,VP8,H264"] | Omit = omit,
149
+ record: Literal["record-from-answer"] | Omit = omit,
150
+ record_channels: Literal["single", "dual"] | Omit = omit,
151
+ record_custom_file_name: str | Omit = omit,
152
+ record_format: Literal["wav", "mp3"] | Omit = omit,
153
+ record_max_length: int | Omit = omit,
154
+ record_timeout_secs: int | Omit = omit,
155
+ record_track: Literal["both", "inbound", "outbound"] | Omit = omit,
156
+ record_trim: Literal["trim-silence"] | Omit = omit,
157
+ send_silence_when_idle: bool | Omit = omit,
158
+ sip_headers: Iterable[SipHeaderParam] | Omit = omit,
159
+ sound_modifications: SoundModificationsParam | Omit = omit,
160
+ stream_bidirectional_codec: StreamBidirectionalCodec | Omit = omit,
161
+ stream_bidirectional_mode: StreamBidirectionalMode | Omit = omit,
162
+ stream_bidirectional_target_legs: StreamBidirectionalTargetLegs | Omit = omit,
163
+ stream_codec: StreamCodec | Omit = omit,
164
+ stream_track: Literal["inbound_track", "outbound_track", "both_tracks"] | Omit = omit,
165
+ stream_url: str | Omit = omit,
166
+ transcription: bool | Omit = omit,
167
+ transcription_config: TranscriptionStartRequestParam | Omit = omit,
168
+ webhook_url: str | Omit = omit,
169
+ webhook_url_method: Literal["POST", "GET"] | Omit = omit,
170
170
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
171
171
  # The extra values given here take precedence over values defined on the client or passed to this method.
172
172
  extra_headers: Headers | None = None,
173
173
  extra_query: Query | None = None,
174
174
  extra_body: Body | None = None,
175
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
175
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
176
176
  ) -> ActionAnswerResponse:
177
177
  """Answer an incoming call.
178
178
 
179
179
  You must issue this command before executing subsequent
180
180
  commands on an incoming call.
181
181
 
182
- **Expected Webhooks (see
183
- [callback schema](https://developers.telnyx.com/api/call-control/answer-call#callbacks)
184
- below):**
182
+ **Expected Webhooks:**
185
183
 
186
184
  - `call.answered`
187
185
  - `streaming.started`, `streaming.stopped` or `streaming.failed` if `stream_url`
@@ -248,7 +246,6 @@ class ActionsResource(SyncAPIResource):
248
246
 
249
247
  stream_codec: Specifies the codec to be used for the streamed audio. When set to 'default' or
250
248
  when transcoding is not possible, the codec from the call will be used.
251
- Currently, transcoding is only supported between PCMU and PCMA codecs.
252
249
 
253
250
  stream_track: Specifies which track should be streamed.
254
251
 
@@ -315,20 +312,20 @@ class ActionsResource(SyncAPIResource):
315
312
  path_call_control_id: str,
316
313
  *,
317
314
  body_call_control_id: str,
318
- client_state: str | NotGiven = NOT_GIVEN,
319
- command_id: str | NotGiven = NOT_GIVEN,
320
- mute_dtmf: Literal["none", "both", "self", "opposite"] | NotGiven = NOT_GIVEN,
321
- park_after_unbridge: str | NotGiven = NOT_GIVEN,
322
- play_ringtone: bool | NotGiven = NOT_GIVEN,
323
- queue: str | NotGiven = NOT_GIVEN,
324
- record: Literal["record-from-answer"] | NotGiven = NOT_GIVEN,
325
- record_channels: Literal["single", "dual"] | NotGiven = NOT_GIVEN,
326
- record_custom_file_name: str | NotGiven = NOT_GIVEN,
327
- record_format: Literal["wav", "mp3"] | NotGiven = NOT_GIVEN,
328
- record_max_length: int | NotGiven = NOT_GIVEN,
329
- record_timeout_secs: int | NotGiven = NOT_GIVEN,
330
- record_track: Literal["both", "inbound", "outbound"] | NotGiven = NOT_GIVEN,
331
- record_trim: Literal["trim-silence"] | NotGiven = NOT_GIVEN,
315
+ client_state: str | Omit = omit,
316
+ command_id: str | Omit = omit,
317
+ mute_dtmf: Literal["none", "both", "self", "opposite"] | Omit = omit,
318
+ park_after_unbridge: str | Omit = omit,
319
+ play_ringtone: bool | Omit = omit,
320
+ queue: str | Omit = omit,
321
+ record: Literal["record-from-answer"] | Omit = omit,
322
+ record_channels: Literal["single", "dual"] | Omit = omit,
323
+ record_custom_file_name: str | Omit = omit,
324
+ record_format: Literal["wav", "mp3"] | Omit = omit,
325
+ record_max_length: int | Omit = omit,
326
+ record_timeout_secs: int | Omit = omit,
327
+ record_track: Literal["both", "inbound", "outbound"] | Omit = omit,
328
+ record_trim: Literal["trim-silence"] | Omit = omit,
332
329
  ringtone: Literal[
333
330
  "at",
334
331
  "au",
@@ -371,22 +368,20 @@ class ActionsResource(SyncAPIResource):
371
368
  "ve",
372
369
  "za",
373
370
  ]
374
- | NotGiven = NOT_GIVEN,
375
- video_room_context: str | NotGiven = NOT_GIVEN,
376
- video_room_id: str | NotGiven = NOT_GIVEN,
371
+ | Omit = omit,
372
+ video_room_context: str | Omit = omit,
373
+ video_room_id: str | Omit = omit,
377
374
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
378
375
  # The extra values given here take precedence over values defined on the client or passed to this method.
379
376
  extra_headers: Headers | None = None,
380
377
  extra_query: Query | None = None,
381
378
  extra_body: Body | None = None,
382
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
379
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
383
380
  ) -> ActionBridgeResponse:
384
381
  """
385
382
  Bridge two call control calls.
386
383
 
387
- **Expected Webhooks (see
388
- [callback schema](https://developers.telnyx.com/api/call-control/bridge-call#callbacks)
389
- below):**
384
+ **Expected Webhooks:**
390
385
 
391
386
  - `call.bridged` for Leg A
392
387
  - `call.bridged` for Leg B
@@ -503,16 +498,16 @@ class ActionsResource(SyncAPIResource):
503
498
  call_control_id: str,
504
499
  *,
505
500
  queue_name: str,
506
- client_state: str | NotGiven = NOT_GIVEN,
507
- command_id: str | NotGiven = NOT_GIVEN,
508
- max_size: int | NotGiven = NOT_GIVEN,
509
- max_wait_time_secs: int | NotGiven = NOT_GIVEN,
501
+ client_state: str | Omit = omit,
502
+ command_id: str | Omit = omit,
503
+ max_size: int | Omit = omit,
504
+ max_wait_time_secs: int | Omit = omit,
510
505
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
511
506
  # The extra values given here take precedence over values defined on the client or passed to this method.
512
507
  extra_headers: Headers | None = None,
513
508
  extra_query: Query | None = None,
514
509
  extra_body: Body | None = None,
515
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
510
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
516
511
  ) -> ActionEnqueueResponse:
517
512
  """
518
513
  Put the call in a queue.
@@ -564,22 +559,22 @@ class ActionsResource(SyncAPIResource):
564
559
  self,
565
560
  call_control_id: str,
566
561
  *,
567
- client_state: str | NotGiven = NOT_GIVEN,
568
- command_id: str | NotGiven = NOT_GIVEN,
569
- gather_id: str | NotGiven = NOT_GIVEN,
570
- initial_timeout_millis: int | NotGiven = NOT_GIVEN,
571
- inter_digit_timeout_millis: int | NotGiven = NOT_GIVEN,
572
- maximum_digits: int | NotGiven = NOT_GIVEN,
573
- minimum_digits: int | NotGiven = NOT_GIVEN,
574
- terminating_digit: str | NotGiven = NOT_GIVEN,
575
- timeout_millis: int | NotGiven = NOT_GIVEN,
576
- valid_digits: str | NotGiven = NOT_GIVEN,
562
+ client_state: str | Omit = omit,
563
+ command_id: str | Omit = omit,
564
+ gather_id: str | Omit = omit,
565
+ initial_timeout_millis: int | Omit = omit,
566
+ inter_digit_timeout_millis: int | Omit = omit,
567
+ maximum_digits: int | Omit = omit,
568
+ minimum_digits: int | Omit = omit,
569
+ terminating_digit: str | Omit = omit,
570
+ timeout_millis: int | Omit = omit,
571
+ valid_digits: str | Omit = omit,
577
572
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
578
573
  # The extra values given here take precedence over values defined on the client or passed to this method.
579
574
  extra_headers: Headers | None = None,
580
575
  extra_query: Query | None = None,
581
576
  extra_body: Body | None = None,
582
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
577
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
583
578
  ) -> ActionGatherResponse:
584
579
  """
585
580
  Gather DTMF signals to build interactive menus.
@@ -587,9 +582,7 @@ class ActionsResource(SyncAPIResource):
587
582
  You can pass a list of valid digits. The `Answer` command must be issued before
588
583
  the `gather` command.
589
584
 
590
- **Expected Webhooks (see
591
- [callback schema](https://developers.telnyx.com/api/call-control/gather-call#callbacks)
592
- below):**
585
+ **Expected Webhooks:**
593
586
 
594
587
  - `call.dtmf.received` (you may receive many of these webhooks)
595
588
  - `call.gather.ended`
@@ -658,25 +651,25 @@ class ActionsResource(SyncAPIResource):
658
651
  call_control_id: str,
659
652
  *,
660
653
  parameters: object,
661
- assistant: AssistantParam | NotGiven = NOT_GIVEN,
662
- client_state: str | NotGiven = NOT_GIVEN,
663
- command_id: str | NotGiven = NOT_GIVEN,
664
- greeting: str | NotGiven = NOT_GIVEN,
665
- interruption_settings: InterruptionSettingsParam | NotGiven = NOT_GIVEN,
666
- language: GoogleTranscriptionLanguage | NotGiven = NOT_GIVEN,
667
- message_history: Iterable[action_gather_using_ai_params.MessageHistory] | NotGiven = NOT_GIVEN,
668
- send_message_history_updates: bool | NotGiven = NOT_GIVEN,
669
- send_partial_results: bool | NotGiven = NOT_GIVEN,
670
- transcription: TranscriptionConfigParam | NotGiven = NOT_GIVEN,
671
- user_response_timeout_ms: int | NotGiven = NOT_GIVEN,
672
- voice: str | NotGiven = NOT_GIVEN,
673
- voice_settings: action_gather_using_ai_params.VoiceSettings | NotGiven = NOT_GIVEN,
654
+ assistant: AssistantParam | Omit = omit,
655
+ client_state: str | Omit = omit,
656
+ command_id: str | Omit = omit,
657
+ greeting: str | Omit = omit,
658
+ interruption_settings: InterruptionSettingsParam | Omit = omit,
659
+ language: GoogleTranscriptionLanguage | Omit = omit,
660
+ message_history: Iterable[action_gather_using_ai_params.MessageHistory] | Omit = omit,
661
+ send_message_history_updates: bool | Omit = omit,
662
+ send_partial_results: bool | Omit = omit,
663
+ transcription: TranscriptionConfigParam | Omit = omit,
664
+ user_response_timeout_ms: int | Omit = omit,
665
+ voice: str | Omit = omit,
666
+ voice_settings: action_gather_using_ai_params.VoiceSettings | Omit = omit,
674
667
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
675
668
  # The extra values given here take precedence over values defined on the client or passed to this method.
676
669
  extra_headers: Headers | None = None,
677
670
  extra_query: Query | None = None,
678
671
  extra_body: Body | None = None,
679
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
672
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
680
673
  ) -> ActionGatherUsingAIResponse:
681
674
  """
682
675
  Gather parameters defined in the request payload using a voice assistant.
@@ -684,9 +677,7 @@ class ActionsResource(SyncAPIResource):
684
677
  You can pass parameters described as a JSON Schema object and the voice
685
678
  assistant will attempt to gather these informations.
686
679
 
687
- **Expected Webhooks (see
688
- [callback schema](https://developers.telnyx.com/api/call-control/call-gather-using-ai#callbacks)
689
- below):**
680
+ **Expected Webhooks:**
690
681
 
691
682
  - `call.ai_gather.ended`
692
683
  - `call.conversation.ended`
@@ -721,16 +712,13 @@ class ActionsResource(SyncAPIResource):
721
712
  information to the voice assistant.
722
713
 
723
714
  send_message_history_updates: Default is `false`. If set to `true`, the voice assistant will send updates to
724
- the message history via the `call.ai_gather.message_history_updated`
725
- [callback](https://developers.telnyx.com/api/call-control/call-gather-using-ai#callbacks)
726
- in real time as the message history is updated.
715
+ the message history via the `call.ai_gather.message_history_updated` callback in
716
+ real time as the message history is updated.
727
717
 
728
718
  send_partial_results: Default is `false`. If set to `true`, the voice assistant will send partial
729
- results via the `call.ai_gather.partial_results`
730
- [callback](https://developers.telnyx.com/api/call-control/call-gather-using-ai#callbacks)
731
- in real time as individual fields are gathered. If set to `false`, the voice
732
- assistant will only send the final result via the `call.ai_gather.ended`
733
- callback.
719
+ results via the `call.ai_gather.partial_results` callback in real time as
720
+ individual fields are gathered. If set to `false`, the voice assistant will only
721
+ send the final result via the `call.ai_gather.ended` callback.
734
722
 
735
723
  transcription: The settings associated with speech to text for the voice assistant. This is
736
724
  only relevant if the assistant uses a text-to-text language model. Any assistant
@@ -806,25 +794,25 @@ class ActionsResource(SyncAPIResource):
806
794
  self,
807
795
  call_control_id: str,
808
796
  *,
809
- audio_url: str | NotGiven = NOT_GIVEN,
810
- client_state: str | NotGiven = NOT_GIVEN,
811
- command_id: str | NotGiven = NOT_GIVEN,
812
- inter_digit_timeout_millis: int | NotGiven = NOT_GIVEN,
813
- invalid_audio_url: str | NotGiven = NOT_GIVEN,
814
- invalid_media_name: str | NotGiven = NOT_GIVEN,
815
- maximum_digits: int | NotGiven = NOT_GIVEN,
816
- maximum_tries: int | NotGiven = NOT_GIVEN,
817
- media_name: str | NotGiven = NOT_GIVEN,
818
- minimum_digits: int | NotGiven = NOT_GIVEN,
819
- terminating_digit: str | NotGiven = NOT_GIVEN,
820
- timeout_millis: int | NotGiven = NOT_GIVEN,
821
- valid_digits: str | NotGiven = NOT_GIVEN,
797
+ audio_url: str | Omit = omit,
798
+ client_state: str | Omit = omit,
799
+ command_id: str | Omit = omit,
800
+ inter_digit_timeout_millis: int | Omit = omit,
801
+ invalid_audio_url: str | Omit = omit,
802
+ invalid_media_name: str | Omit = omit,
803
+ maximum_digits: int | Omit = omit,
804
+ maximum_tries: int | Omit = omit,
805
+ media_name: str | Omit = omit,
806
+ minimum_digits: int | Omit = omit,
807
+ terminating_digit: str | Omit = omit,
808
+ timeout_millis: int | Omit = omit,
809
+ valid_digits: str | Omit = omit,
822
810
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
823
811
  # The extra values given here take precedence over values defined on the client or passed to this method.
824
812
  extra_headers: Headers | None = None,
825
813
  extra_query: Query | None = None,
826
814
  extra_body: Body | None = None,
827
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
815
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
828
816
  ) -> ActionGatherUsingAudioResponse:
829
817
  """
830
818
  Play an audio file on the call until the required DTMF signals are gathered to
@@ -835,9 +823,7 @@ class ActionsResource(SyncAPIResource):
835
823
  interrupted when a DTMF signal is received. The
836
824
  `Answer command must be issued before the `gather_using_audio` command.
837
825
 
838
- **Expected Webhooks (see
839
- [callback schema](https://developers.telnyx.com/api/call-control/gather-using-audio#callbacks)
840
- below):**
826
+ **Expected Webhooks:**
841
827
 
842
828
  - `call.playback.started`
843
829
  - `call.playback.ended`
@@ -930,10 +916,10 @@ class ActionsResource(SyncAPIResource):
930
916
  *,
931
917
  payload: str,
932
918
  voice: str,
933
- client_state: str | NotGiven = NOT_GIVEN,
934
- command_id: str | NotGiven = NOT_GIVEN,
935
- inter_digit_timeout_millis: int | NotGiven = NOT_GIVEN,
936
- invalid_payload: str | NotGiven = NOT_GIVEN,
919
+ client_state: str | Omit = omit,
920
+ command_id: str | Omit = omit,
921
+ inter_digit_timeout_millis: int | Omit = omit,
922
+ invalid_payload: str | Omit = omit,
937
923
  language: Literal[
938
924
  "arb",
939
925
  "cmn-CN",
@@ -965,22 +951,22 @@ class ActionsResource(SyncAPIResource):
965
951
  "sv-SE",
966
952
  "tr-TR",
967
953
  ]
968
- | NotGiven = NOT_GIVEN,
969
- maximum_digits: int | NotGiven = NOT_GIVEN,
970
- maximum_tries: int | NotGiven = NOT_GIVEN,
971
- minimum_digits: int | NotGiven = NOT_GIVEN,
972
- payload_type: Literal["text", "ssml"] | NotGiven = NOT_GIVEN,
973
- service_level: Literal["basic", "premium"] | NotGiven = NOT_GIVEN,
974
- terminating_digit: str | NotGiven = NOT_GIVEN,
975
- timeout_millis: int | NotGiven = NOT_GIVEN,
976
- valid_digits: str | NotGiven = NOT_GIVEN,
977
- voice_settings: action_gather_using_speak_params.VoiceSettings | NotGiven = NOT_GIVEN,
954
+ | Omit = omit,
955
+ maximum_digits: int | Omit = omit,
956
+ maximum_tries: int | Omit = omit,
957
+ minimum_digits: int | Omit = omit,
958
+ payload_type: Literal["text", "ssml"] | Omit = omit,
959
+ service_level: Literal["basic", "premium"] | Omit = omit,
960
+ terminating_digit: str | Omit = omit,
961
+ timeout_millis: int | Omit = omit,
962
+ valid_digits: str | Omit = omit,
963
+ voice_settings: action_gather_using_speak_params.VoiceSettings | Omit = omit,
978
964
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
979
965
  # The extra values given here take precedence over values defined on the client or passed to this method.
980
966
  extra_headers: Headers | None = None,
981
967
  extra_query: Query | None = None,
982
968
  extra_body: Body | None = None,
983
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
969
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
984
970
  ) -> ActionGatherUsingSpeakResponse:
985
971
  """
986
972
  Convert text to speech and play it on the call until the required DTMF signals
@@ -991,9 +977,7 @@ class ActionsResource(SyncAPIResource):
991
977
  a DTMF signal is received. The `Answer` command must be issued before the
992
978
  `gather_using_speak` command.
993
979
 
994
- **Expected Webhooks (see
995
- [callback schema](https://developers.telnyx.com/api/call-control/gather-using-speak#callbacks)
996
- below):**
980
+ **Expected Webhooks:**
997
981
 
998
982
  - `call.dtmf.received` (you may receive many of these webhooks)
999
983
  - `call.gather.ended`
@@ -1112,21 +1096,19 @@ class ActionsResource(SyncAPIResource):
1112
1096
  self,
1113
1097
  call_control_id: str,
1114
1098
  *,
1115
- client_state: str | NotGiven = NOT_GIVEN,
1116
- command_id: str | NotGiven = NOT_GIVEN,
1099
+ client_state: str | Omit = omit,
1100
+ command_id: str | Omit = omit,
1117
1101
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1118
1102
  # The extra values given here take precedence over values defined on the client or passed to this method.
1119
1103
  extra_headers: Headers | None = None,
1120
1104
  extra_query: Query | None = None,
1121
1105
  extra_body: Body | None = None,
1122
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1106
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1123
1107
  ) -> ActionHangupResponse:
1124
1108
  """
1125
1109
  Hang up the call.
1126
1110
 
1127
- **Expected Webhooks (see
1128
- [callback schema](https://developers.telnyx.com/api/call-control/hangup-call#callbacks)
1129
- below):**
1111
+ **Expected Webhooks:**
1130
1112
 
1131
1113
  - `call.hangup`
1132
1114
  - `call.recording.saved`
@@ -1167,14 +1149,14 @@ class ActionsResource(SyncAPIResource):
1167
1149
  self,
1168
1150
  call_control_id: str,
1169
1151
  *,
1170
- client_state: str | NotGiven = NOT_GIVEN,
1171
- command_id: str | NotGiven = NOT_GIVEN,
1152
+ client_state: str | Omit = omit,
1153
+ command_id: str | Omit = omit,
1172
1154
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1173
1155
  # The extra values given here take precedence over values defined on the client or passed to this method.
1174
1156
  extra_headers: Headers | None = None,
1175
1157
  extra_query: Query | None = None,
1176
1158
  extra_body: Body | None = None,
1177
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1159
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1178
1160
  ) -> ActionLeaveQueueResponse:
1179
1161
  """
1180
1162
  Removes the call from a queue.
@@ -1215,15 +1197,15 @@ class ActionsResource(SyncAPIResource):
1215
1197
  self,
1216
1198
  call_control_id: str,
1217
1199
  *,
1218
- client_state: str | NotGiven = NOT_GIVEN,
1219
- command_id: str | NotGiven = NOT_GIVEN,
1220
- recording_id: str | NotGiven = NOT_GIVEN,
1200
+ client_state: str | Omit = omit,
1201
+ command_id: str | Omit = omit,
1202
+ recording_id: str | Omit = omit,
1221
1203
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1222
1204
  # The extra values given here take precedence over values defined on the client or passed to this method.
1223
1205
  extra_headers: Headers | None = None,
1224
1206
  extra_query: Query | None = None,
1225
1207
  extra_body: Body | None = None,
1226
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1208
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1227
1209
  ) -> ActionPauseRecordingResponse:
1228
1210
  """Pause recording the call.
1229
1211
 
@@ -1273,27 +1255,25 @@ class ActionsResource(SyncAPIResource):
1273
1255
  call_control_id: str,
1274
1256
  *,
1275
1257
  sip_address: str,
1276
- client_state: str | NotGiven = NOT_GIVEN,
1277
- command_id: str | NotGiven = NOT_GIVEN,
1278
- custom_headers: Iterable[CustomSipHeaderParam] | NotGiven = NOT_GIVEN,
1279
- sip_auth_password: str | NotGiven = NOT_GIVEN,
1280
- sip_auth_username: str | NotGiven = NOT_GIVEN,
1281
- sip_headers: Iterable[SipHeaderParam] | NotGiven = NOT_GIVEN,
1258
+ client_state: str | Omit = omit,
1259
+ command_id: str | Omit = omit,
1260
+ custom_headers: Iterable[CustomSipHeaderParam] | Omit = omit,
1261
+ sip_auth_password: str | Omit = omit,
1262
+ sip_auth_username: str | Omit = omit,
1263
+ sip_headers: Iterable[SipHeaderParam] | Omit = omit,
1282
1264
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1283
1265
  # The extra values given here take precedence over values defined on the client or passed to this method.
1284
1266
  extra_headers: Headers | None = None,
1285
1267
  extra_query: Query | None = None,
1286
1268
  extra_body: Body | None = None,
1287
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1269
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1288
1270
  ) -> ActionReferResponse:
1289
1271
  """Initiate a SIP Refer on a Call Control call.
1290
1272
 
1291
1273
  You can initiate a SIP Refer at any
1292
1274
  point in the duration of a call.
1293
1275
 
1294
- **Expected Webhooks (see
1295
- [callback schema](https://developers.telnyx.com/api/call-control/refer-call#callbacks)
1296
- below):**
1276
+ **Expected Webhooks:**
1297
1277
 
1298
1278
  - `call.refer.started`
1299
1279
  - `call.refer.completed`
@@ -1353,21 +1333,19 @@ class ActionsResource(SyncAPIResource):
1353
1333
  call_control_id: str,
1354
1334
  *,
1355
1335
  cause: Literal["CALL_REJECTED", "USER_BUSY"],
1356
- client_state: str | NotGiven = NOT_GIVEN,
1357
- command_id: str | NotGiven = NOT_GIVEN,
1336
+ client_state: str | Omit = omit,
1337
+ command_id: str | Omit = omit,
1358
1338
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1359
1339
  # The extra values given here take precedence over values defined on the client or passed to this method.
1360
1340
  extra_headers: Headers | None = None,
1361
1341
  extra_query: Query | None = None,
1362
1342
  extra_body: Body | None = None,
1363
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1343
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1364
1344
  ) -> ActionRejectResponse:
1365
1345
  """
1366
1346
  Reject an incoming call.
1367
1347
 
1368
- **Expected Webhooks (see
1369
- [callback schema](https://developers.telnyx.com/api/call-control/reject-call#callbacks)
1370
- below):**
1348
+ **Expected Webhooks:**
1371
1349
 
1372
1350
  - `call.hangup`
1373
1351
 
@@ -1410,15 +1388,15 @@ class ActionsResource(SyncAPIResource):
1410
1388
  self,
1411
1389
  call_control_id: str,
1412
1390
  *,
1413
- client_state: str | NotGiven = NOT_GIVEN,
1414
- command_id: str | NotGiven = NOT_GIVEN,
1415
- recording_id: str | NotGiven = NOT_GIVEN,
1391
+ client_state: str | Omit = omit,
1392
+ command_id: str | Omit = omit,
1393
+ recording_id: str | Omit = omit,
1416
1394
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1417
1395
  # The extra values given here take precedence over values defined on the client or passed to this method.
1418
1396
  extra_headers: Headers | None = None,
1419
1397
  extra_query: Query | None = None,
1420
1398
  extra_body: Body | None = None,
1421
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1399
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1422
1400
  ) -> ActionResumeRecordingResponse:
1423
1401
  """
1424
1402
  Resume recording the call.
@@ -1467,15 +1445,15 @@ class ActionsResource(SyncAPIResource):
1467
1445
  call_control_id: str,
1468
1446
  *,
1469
1447
  digits: str,
1470
- client_state: str | NotGiven = NOT_GIVEN,
1471
- command_id: str | NotGiven = NOT_GIVEN,
1472
- duration_millis: int | NotGiven = NOT_GIVEN,
1448
+ client_state: str | Omit = omit,
1449
+ command_id: str | Omit = omit,
1450
+ duration_millis: int | Omit = omit,
1473
1451
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1474
1452
  # The extra values given here take precedence over values defined on the client or passed to this method.
1475
1453
  extra_headers: Headers | None = None,
1476
1454
  extra_query: Query | None = None,
1477
1455
  extra_body: Body | None = None,
1478
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1456
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1479
1457
  ) -> ActionSendDtmfResponse:
1480
1458
  """Sends DTMF tones from this leg.
1481
1459
 
@@ -1532,14 +1510,14 @@ class ActionsResource(SyncAPIResource):
1532
1510
  *,
1533
1511
  body: str,
1534
1512
  content_type: str,
1535
- client_state: str | NotGiven = NOT_GIVEN,
1536
- command_id: str | NotGiven = NOT_GIVEN,
1513
+ client_state: str | Omit = omit,
1514
+ command_id: str | Omit = omit,
1537
1515
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1538
1516
  # The extra values given here take precedence over values defined on the client or passed to this method.
1539
1517
  extra_headers: Headers | None = None,
1540
1518
  extra_query: Query | None = None,
1541
1519
  extra_body: Body | None = None,
1542
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1520
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1543
1521
  ) -> ActionSendSipInfoResponse:
1544
1522
  """
1545
1523
  Sends SIP info from this leg.
@@ -1593,8 +1571,8 @@ class ActionsResource(SyncAPIResource):
1593
1571
  *,
1594
1572
  payload: str,
1595
1573
  voice: str,
1596
- client_state: str | NotGiven = NOT_GIVEN,
1597
- command_id: str | NotGiven = NOT_GIVEN,
1574
+ client_state: str | Omit = omit,
1575
+ command_id: str | Omit = omit,
1598
1576
  language: Literal[
1599
1577
  "arb",
1600
1578
  "cmn-CN",
@@ -1626,17 +1604,17 @@ class ActionsResource(SyncAPIResource):
1626
1604
  "sv-SE",
1627
1605
  "tr-TR",
1628
1606
  ]
1629
- | NotGiven = NOT_GIVEN,
1630
- payload_type: Literal["text", "ssml"] | NotGiven = NOT_GIVEN,
1631
- service_level: Literal["basic", "premium"] | NotGiven = NOT_GIVEN,
1632
- stop: str | NotGiven = NOT_GIVEN,
1633
- voice_settings: action_speak_params.VoiceSettings | NotGiven = NOT_GIVEN,
1607
+ | Omit = omit,
1608
+ payload_type: Literal["text", "ssml"] | Omit = omit,
1609
+ service_level: Literal["basic", "premium"] | Omit = omit,
1610
+ stop: str | Omit = omit,
1611
+ voice_settings: action_speak_params.VoiceSettings | Omit = omit,
1634
1612
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1635
1613
  # The extra values given here take precedence over values defined on the client or passed to this method.
1636
1614
  extra_headers: Headers | None = None,
1637
1615
  extra_query: Query | None = None,
1638
1616
  extra_body: Body | None = None,
1639
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1617
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1640
1618
  ) -> ActionSpeakResponse:
1641
1619
  """Convert text to speech and play it back on the call.
1642
1620
 
@@ -1644,9 +1622,7 @@ class ActionsResource(SyncAPIResource):
1644
1622
  commands are issued consecutively, the audio files will be placed in a queue
1645
1623
  awaiting playback.
1646
1624
 
1647
- **Expected Webhooks (see
1648
- [callback schema](https://developers.telnyx.com/api/call-control/speak-call#callbacks)
1649
- below):**
1625
+ **Expected Webhooks:**
1650
1626
 
1651
1627
  - `call.speak.started`
1652
1628
  - `call.speak.ended`
@@ -1741,27 +1717,25 @@ class ActionsResource(SyncAPIResource):
1741
1717
  self,
1742
1718
  call_control_id: str,
1743
1719
  *,
1744
- assistant: action_start_ai_assistant_params.Assistant | NotGiven = NOT_GIVEN,
1745
- client_state: str | NotGiven = NOT_GIVEN,
1746
- command_id: str | NotGiven = NOT_GIVEN,
1747
- greeting: str | NotGiven = NOT_GIVEN,
1748
- interruption_settings: InterruptionSettingsParam | NotGiven = NOT_GIVEN,
1749
- transcription: TranscriptionConfigParam | NotGiven = NOT_GIVEN,
1750
- voice: str | NotGiven = NOT_GIVEN,
1751
- voice_settings: action_start_ai_assistant_params.VoiceSettings | NotGiven = NOT_GIVEN,
1720
+ assistant: action_start_ai_assistant_params.Assistant | Omit = omit,
1721
+ client_state: str | Omit = omit,
1722
+ command_id: str | Omit = omit,
1723
+ greeting: str | Omit = omit,
1724
+ interruption_settings: InterruptionSettingsParam | Omit = omit,
1725
+ transcription: TranscriptionConfigParam | Omit = omit,
1726
+ voice: str | Omit = omit,
1727
+ voice_settings: action_start_ai_assistant_params.VoiceSettings | Omit = omit,
1752
1728
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1753
1729
  # The extra values given here take precedence over values defined on the client or passed to this method.
1754
1730
  extra_headers: Headers | None = None,
1755
1731
  extra_query: Query | None = None,
1756
1732
  extra_body: Body | None = None,
1757
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1733
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1758
1734
  ) -> ActionStartAIAssistantResponse:
1759
1735
  """
1760
1736
  Start an AI assistant on the call.
1761
1737
 
1762
- **Expected Webhooks (see
1763
- [callback schema](https://developers.telnyx.com/api/call-control/call-start-ai-assistant#callbacks)
1764
- below):**
1738
+ **Expected Webhooks:**
1765
1739
 
1766
1740
  - `call.conversation.ended`
1767
1741
  - `call.conversation_insights.generated`
@@ -1846,17 +1820,17 @@ class ActionsResource(SyncAPIResource):
1846
1820
  self,
1847
1821
  call_control_id: str,
1848
1822
  *,
1849
- client_state: str | NotGiven = NOT_GIVEN,
1850
- command_id: str | NotGiven = NOT_GIVEN,
1851
- rx: str | NotGiven = NOT_GIVEN,
1852
- stream_type: Literal["decrypted"] | NotGiven = NOT_GIVEN,
1853
- tx: str | NotGiven = NOT_GIVEN,
1823
+ client_state: str | Omit = omit,
1824
+ command_id: str | Omit = omit,
1825
+ rx: str | Omit = omit,
1826
+ stream_type: Literal["decrypted"] | Omit = omit,
1827
+ tx: str | Omit = omit,
1854
1828
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1855
1829
  # The extra values given here take precedence over values defined on the client or passed to this method.
1856
1830
  extra_headers: Headers | None = None,
1857
1831
  extra_query: Query | None = None,
1858
1832
  extra_body: Body | None = None,
1859
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1833
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1860
1834
  ) -> ActionStartForkingResponse:
1861
1835
  """
1862
1836
  Call forking allows you to stream the media from a call to a specific target in
@@ -1865,9 +1839,7 @@ class ActionsResource(SyncAPIResource):
1865
1839
  audio responses. Requests must specify either the `target` attribute or the `rx`
1866
1840
  and `tx` attributes.
1867
1841
 
1868
- **Expected Webhooks (see
1869
- [callback schema](https://developers.telnyx.com/api/call-control/start-call-fork#callbacks)
1870
- below):**
1842
+ **Expected Webhooks:**
1871
1843
 
1872
1844
  - `call.fork.started`
1873
1845
  - `call.fork.stopped`
@@ -1921,16 +1893,16 @@ class ActionsResource(SyncAPIResource):
1921
1893
  self,
1922
1894
  call_control_id: str,
1923
1895
  *,
1924
- client_state: str | NotGiven = NOT_GIVEN,
1925
- command_id: str | NotGiven = NOT_GIVEN,
1926
- direction: Literal["inbound", "outbound", "both"] | NotGiven = NOT_GIVEN,
1927
- noise_suppression_engine: Literal["A", "B"] | NotGiven = NOT_GIVEN,
1896
+ client_state: str | Omit = omit,
1897
+ command_id: str | Omit = omit,
1898
+ direction: Literal["inbound", "outbound", "both"] | Omit = omit,
1899
+ noise_suppression_engine: Literal["A", "B"] | Omit = omit,
1928
1900
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1929
1901
  # The extra values given here take precedence over values defined on the client or passed to this method.
1930
1902
  extra_headers: Headers | None = None,
1931
1903
  extra_query: Query | None = None,
1932
1904
  extra_body: Body | None = None,
1933
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1905
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1934
1906
  ) -> ActionStartNoiseSuppressionResponse:
1935
1907
  """
1936
1908
  Noise Suppression Start (BETA)
@@ -1978,23 +1950,23 @@ class ActionsResource(SyncAPIResource):
1978
1950
  self,
1979
1951
  call_control_id: str,
1980
1952
  *,
1981
- audio_type: Literal["mp3", "wav"] | NotGiven = NOT_GIVEN,
1982
- audio_url: str | NotGiven = NOT_GIVEN,
1983
- cache_audio: bool | NotGiven = NOT_GIVEN,
1984
- client_state: str | NotGiven = NOT_GIVEN,
1985
- command_id: str | NotGiven = NOT_GIVEN,
1986
- loop: LoopcountParam | NotGiven = NOT_GIVEN,
1987
- media_name: str | NotGiven = NOT_GIVEN,
1988
- overlay: bool | NotGiven = NOT_GIVEN,
1989
- playback_content: str | NotGiven = NOT_GIVEN,
1990
- stop: str | NotGiven = NOT_GIVEN,
1991
- target_legs: str | NotGiven = NOT_GIVEN,
1953
+ audio_type: Literal["mp3", "wav"] | Omit = omit,
1954
+ audio_url: str | Omit = omit,
1955
+ cache_audio: bool | Omit = omit,
1956
+ client_state: str | Omit = omit,
1957
+ command_id: str | Omit = omit,
1958
+ loop: LoopcountParam | Omit = omit,
1959
+ media_name: str | Omit = omit,
1960
+ overlay: bool | Omit = omit,
1961
+ playback_content: str | Omit = omit,
1962
+ stop: str | Omit = omit,
1963
+ target_legs: str | Omit = omit,
1992
1964
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
1993
1965
  # The extra values given here take precedence over values defined on the client or passed to this method.
1994
1966
  extra_headers: Headers | None = None,
1995
1967
  extra_query: Query | None = None,
1996
1968
  extra_body: Body | None = None,
1997
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
1969
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
1998
1970
  ) -> ActionStartPlaybackResponse:
1999
1971
  """Play an audio file on the call.
2000
1972
 
@@ -2007,9 +1979,7 @@ class ActionsResource(SyncAPIResource):
2007
1979
  - A customer cannot Play Audio with `overlay=true` unless there is a Play Audio
2008
1980
  with `overlay=false` actively playing.
2009
1981
 
2010
- **Expected Webhooks (see
2011
- [callback schema](https://developers.telnyx.com/api/call-control/start-call-playback#callbacks)
2012
- below):**
1982
+ **Expected Webhooks:**
2013
1983
 
2014
1984
  - `call.playback.started`
2015
1985
  - `call.playback.ended`
@@ -2094,15 +2064,15 @@ class ActionsResource(SyncAPIResource):
2094
2064
  *,
2095
2065
  channels: Literal["single", "dual"],
2096
2066
  format: Literal["wav", "mp3"],
2097
- client_state: str | NotGiven = NOT_GIVEN,
2098
- command_id: str | NotGiven = NOT_GIVEN,
2099
- custom_file_name: str | NotGiven = NOT_GIVEN,
2100
- max_length: int | NotGiven = NOT_GIVEN,
2101
- play_beep: bool | NotGiven = NOT_GIVEN,
2102
- recording_track: Literal["both", "inbound", "outbound"] | NotGiven = NOT_GIVEN,
2103
- timeout_secs: int | NotGiven = NOT_GIVEN,
2104
- transcription: bool | NotGiven = NOT_GIVEN,
2105
- transcription_engine: str | NotGiven = NOT_GIVEN,
2067
+ client_state: str | Omit = omit,
2068
+ command_id: str | Omit = omit,
2069
+ custom_file_name: str | Omit = omit,
2070
+ max_length: int | Omit = omit,
2071
+ play_beep: bool | Omit = omit,
2072
+ recording_track: Literal["both", "inbound", "outbound"] | Omit = omit,
2073
+ timeout_secs: int | Omit = omit,
2074
+ transcription: bool | Omit = omit,
2075
+ transcription_engine: str | Omit = omit,
2106
2076
  transcription_language: Literal[
2107
2077
  "af-ZA",
2108
2078
  "am-ET",
@@ -2250,27 +2220,25 @@ class ActionsResource(SyncAPIResource):
2250
2220
  "zh-TW",
2251
2221
  "zu-ZA",
2252
2222
  ]
2253
- | NotGiven = NOT_GIVEN,
2254
- transcription_max_speaker_count: int | NotGiven = NOT_GIVEN,
2255
- transcription_min_speaker_count: int | NotGiven = NOT_GIVEN,
2256
- transcription_profanity_filter: bool | NotGiven = NOT_GIVEN,
2257
- transcription_speaker_diarization: bool | NotGiven = NOT_GIVEN,
2258
- trim: Literal["trim-silence"] | NotGiven = NOT_GIVEN,
2223
+ | Omit = omit,
2224
+ transcription_max_speaker_count: int | Omit = omit,
2225
+ transcription_min_speaker_count: int | Omit = omit,
2226
+ transcription_profanity_filter: bool | Omit = omit,
2227
+ transcription_speaker_diarization: bool | Omit = omit,
2228
+ trim: Literal["trim-silence"] | Omit = omit,
2259
2229
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2260
2230
  # The extra values given here take precedence over values defined on the client or passed to this method.
2261
2231
  extra_headers: Headers | None = None,
2262
2232
  extra_query: Query | None = None,
2263
2233
  extra_body: Body | None = None,
2264
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2234
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2265
2235
  ) -> ActionStartRecordingResponse:
2266
2236
  """Start recording the call.
2267
2237
 
2268
2238
  Recording will stop on call hang-up, or can be
2269
2239
  initiated via the Stop Recording command.
2270
2240
 
2271
- **Expected Webhooks (see
2272
- [callback schema](https://developers.telnyx.com/api/call-control/start-call-record#callbacks)
2273
- below):**
2241
+ **Expected Webhooks:**
2274
2242
 
2275
2243
  - `call.recording.saved`
2276
2244
  - `call.recording.transcription.saved`
@@ -2369,19 +2337,19 @@ class ActionsResource(SyncAPIResource):
2369
2337
  self,
2370
2338
  call_control_id: str,
2371
2339
  *,
2372
- client_state: str | NotGiven = NOT_GIVEN,
2373
- connector_name: str | NotGiven = NOT_GIVEN,
2374
- include_metadata_custom_headers: Literal[True, False] | NotGiven = NOT_GIVEN,
2375
- secure: Literal[True, False] | NotGiven = NOT_GIVEN,
2376
- session_timeout_secs: int | NotGiven = NOT_GIVEN,
2377
- sip_transport: Literal["udp", "tcp", "tls"] | NotGiven = NOT_GIVEN,
2378
- siprec_track: Literal["inbound_track", "outbound_track", "both_tracks"] | NotGiven = NOT_GIVEN,
2340
+ client_state: str | Omit = omit,
2341
+ connector_name: str | Omit = omit,
2342
+ include_metadata_custom_headers: Literal[True, False] | Omit = omit,
2343
+ secure: Literal[True, False] | Omit = omit,
2344
+ session_timeout_secs: int | Omit = omit,
2345
+ sip_transport: Literal["udp", "tcp", "tls"] | Omit = omit,
2346
+ siprec_track: Literal["inbound_track", "outbound_track", "both_tracks"] | Omit = omit,
2379
2347
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2380
2348
  # The extra values given here take precedence over values defined on the client or passed to this method.
2381
2349
  extra_headers: Headers | None = None,
2382
2350
  extra_query: Query | None = None,
2383
2351
  extra_body: Body | None = None,
2384
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2352
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2385
2353
  ) -> ActionStartSiprecResponse:
2386
2354
  """
2387
2355
  Start siprec session to configured in SIPREC connector SRS.
@@ -2447,22 +2415,23 @@ class ActionsResource(SyncAPIResource):
2447
2415
  self,
2448
2416
  call_control_id: str,
2449
2417
  *,
2450
- client_state: str | NotGiven = NOT_GIVEN,
2451
- command_id: str | NotGiven = NOT_GIVEN,
2452
- dialogflow_config: DialogflowConfigParam | NotGiven = NOT_GIVEN,
2453
- enable_dialogflow: bool | NotGiven = NOT_GIVEN,
2454
- stream_bidirectional_codec: StreamBidirectionalCodec | NotGiven = NOT_GIVEN,
2455
- stream_bidirectional_mode: StreamBidirectionalMode | NotGiven = NOT_GIVEN,
2456
- stream_bidirectional_target_legs: StreamBidirectionalTargetLegs | NotGiven = NOT_GIVEN,
2457
- stream_codec: StreamCodec | NotGiven = NOT_GIVEN,
2458
- stream_track: Literal["inbound_track", "outbound_track", "both_tracks"] | NotGiven = NOT_GIVEN,
2459
- stream_url: str | NotGiven = NOT_GIVEN,
2418
+ client_state: str | Omit = omit,
2419
+ command_id: str | Omit = omit,
2420
+ dialogflow_config: DialogflowConfigParam | Omit = omit,
2421
+ enable_dialogflow: bool | Omit = omit,
2422
+ stream_bidirectional_codec: StreamBidirectionalCodec | Omit = omit,
2423
+ stream_bidirectional_mode: StreamBidirectionalMode | Omit = omit,
2424
+ stream_bidirectional_sampling_rate: Literal[8000, 16000, 22050, 24000, 48000] | Omit = omit,
2425
+ stream_bidirectional_target_legs: StreamBidirectionalTargetLegs | Omit = omit,
2426
+ stream_codec: StreamCodec | Omit = omit,
2427
+ stream_track: Literal["inbound_track", "outbound_track", "both_tracks"] | Omit = omit,
2428
+ stream_url: str | Omit = omit,
2460
2429
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2461
2430
  # The extra values given here take precedence over values defined on the client or passed to this method.
2462
2431
  extra_headers: Headers | None = None,
2463
2432
  extra_query: Query | None = None,
2464
2433
  extra_body: Body | None = None,
2465
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2434
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2466
2435
  ) -> ActionStartStreamingResponse:
2467
2436
  """
2468
2437
  Start streaming the media from a call to a specific WebSocket address or
@@ -2486,11 +2455,12 @@ class ActionsResource(SyncAPIResource):
2486
2455
 
2487
2456
  stream_bidirectional_mode: Configures method of bidirectional streaming (mp3, rtp).
2488
2457
 
2458
+ stream_bidirectional_sampling_rate: Audio sampling rate.
2459
+
2489
2460
  stream_bidirectional_target_legs: Specifies which call legs should receive the bidirectional stream audio.
2490
2461
 
2491
2462
  stream_codec: Specifies the codec to be used for the streamed audio. When set to 'default' or
2492
2463
  when transcoding is not possible, the codec from the call will be used.
2493
- Currently, transcoding is only supported between PCMU and PCMA codecs.
2494
2464
 
2495
2465
  stream_track: Specifies which track should be streamed.
2496
2466
 
@@ -2516,6 +2486,7 @@ class ActionsResource(SyncAPIResource):
2516
2486
  "enable_dialogflow": enable_dialogflow,
2517
2487
  "stream_bidirectional_codec": stream_bidirectional_codec,
2518
2488
  "stream_bidirectional_mode": stream_bidirectional_mode,
2489
+ "stream_bidirectional_sampling_rate": stream_bidirectional_sampling_rate,
2519
2490
  "stream_bidirectional_target_legs": stream_bidirectional_target_legs,
2520
2491
  "stream_codec": stream_codec,
2521
2492
  "stream_track": stream_track,
@@ -2533,26 +2504,24 @@ class ActionsResource(SyncAPIResource):
2533
2504
  self,
2534
2505
  call_control_id: str,
2535
2506
  *,
2536
- client_state: str | NotGiven = NOT_GIVEN,
2537
- command_id: str | NotGiven = NOT_GIVEN,
2538
- transcription_engine: Literal["A", "B"] | NotGiven = NOT_GIVEN,
2539
- transcription_engine_config: action_start_transcription_params.TranscriptionEngineConfig | NotGiven = NOT_GIVEN,
2540
- transcription_tracks: str | NotGiven = NOT_GIVEN,
2507
+ client_state: str | Omit = omit,
2508
+ command_id: str | Omit = omit,
2509
+ transcription_engine: Literal["A", "B"] | Omit = omit,
2510
+ transcription_engine_config: action_start_transcription_params.TranscriptionEngineConfig | Omit = omit,
2511
+ transcription_tracks: str | Omit = omit,
2541
2512
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2542
2513
  # The extra values given here take precedence over values defined on the client or passed to this method.
2543
2514
  extra_headers: Headers | None = None,
2544
2515
  extra_query: Query | None = None,
2545
2516
  extra_body: Body | None = None,
2546
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2517
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2547
2518
  ) -> ActionStartTranscriptionResponse:
2548
2519
  """Start real-time transcription.
2549
2520
 
2550
2521
  Transcription will stop on call hang-up, or can
2551
2522
  be initiated via the Transcription stop command.
2552
2523
 
2553
- **Expected Webhooks (see
2554
- [callback schema](https://developers.telnyx.com/api/call-control/start-call-transcription#callbacks)
2555
- below):**
2524
+ **Expected Webhooks:**
2556
2525
 
2557
2526
  - `call.transcription`
2558
2527
 
@@ -2601,14 +2570,14 @@ class ActionsResource(SyncAPIResource):
2601
2570
  self,
2602
2571
  call_control_id: str,
2603
2572
  *,
2604
- client_state: str | NotGiven = NOT_GIVEN,
2605
- command_id: str | NotGiven = NOT_GIVEN,
2573
+ client_state: str | Omit = omit,
2574
+ command_id: str | Omit = omit,
2606
2575
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2607
2576
  # The extra values given here take precedence over values defined on the client or passed to this method.
2608
2577
  extra_headers: Headers | None = None,
2609
2578
  extra_query: Query | None = None,
2610
2579
  extra_body: Body | None = None,
2611
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2580
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2612
2581
  ) -> ActionStopAIAssistantResponse:
2613
2582
  """
2614
2583
  Stop an AI assistant on the call.
@@ -2649,22 +2618,20 @@ class ActionsResource(SyncAPIResource):
2649
2618
  self,
2650
2619
  call_control_id: str,
2651
2620
  *,
2652
- client_state: str | NotGiven = NOT_GIVEN,
2653
- command_id: str | NotGiven = NOT_GIVEN,
2654
- stream_type: Literal["raw", "decrypted"] | NotGiven = NOT_GIVEN,
2621
+ client_state: str | Omit = omit,
2622
+ command_id: str | Omit = omit,
2623
+ stream_type: Literal["raw", "decrypted"] | Omit = omit,
2655
2624
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2656
2625
  # The extra values given here take precedence over values defined on the client or passed to this method.
2657
2626
  extra_headers: Headers | None = None,
2658
2627
  extra_query: Query | None = None,
2659
2628
  extra_body: Body | None = None,
2660
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2629
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2661
2630
  ) -> ActionStopForkingResponse:
2662
2631
  """
2663
2632
  Stop forking a call.
2664
2633
 
2665
- **Expected Webhooks (see
2666
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-fork#callbacks)
2667
- below):**
2634
+ **Expected Webhooks:**
2668
2635
 
2669
2636
  - `call.fork.stopped`
2670
2637
 
@@ -2708,21 +2675,19 @@ class ActionsResource(SyncAPIResource):
2708
2675
  self,
2709
2676
  call_control_id: str,
2710
2677
  *,
2711
- client_state: str | NotGiven = NOT_GIVEN,
2712
- command_id: str | NotGiven = NOT_GIVEN,
2678
+ client_state: str | Omit = omit,
2679
+ command_id: str | Omit = omit,
2713
2680
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2714
2681
  # The extra values given here take precedence over values defined on the client or passed to this method.
2715
2682
  extra_headers: Headers | None = None,
2716
2683
  extra_query: Query | None = None,
2717
2684
  extra_body: Body | None = None,
2718
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2685
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2719
2686
  ) -> ActionStopGatherResponse:
2720
2687
  """
2721
2688
  Stop current gather.
2722
2689
 
2723
- **Expected Webhooks (see
2724
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-gather#callbacks)
2725
- below):**
2690
+ **Expected Webhooks:**
2726
2691
 
2727
2692
  - `call.gather.ended`
2728
2693
 
@@ -2762,14 +2727,14 @@ class ActionsResource(SyncAPIResource):
2762
2727
  self,
2763
2728
  call_control_id: str,
2764
2729
  *,
2765
- client_state: str | NotGiven = NOT_GIVEN,
2766
- command_id: str | NotGiven = NOT_GIVEN,
2730
+ client_state: str | Omit = omit,
2731
+ command_id: str | Omit = omit,
2767
2732
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2768
2733
  # The extra values given here take precedence over values defined on the client or passed to this method.
2769
2734
  extra_headers: Headers | None = None,
2770
2735
  extra_query: Query | None = None,
2771
2736
  extra_body: Body | None = None,
2772
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2737
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2773
2738
  ) -> ActionStopNoiseSuppressionResponse:
2774
2739
  """
2775
2740
  Noise Suppression Stop (BETA)
@@ -2810,23 +2775,21 @@ class ActionsResource(SyncAPIResource):
2810
2775
  self,
2811
2776
  call_control_id: str,
2812
2777
  *,
2813
- client_state: str | NotGiven = NOT_GIVEN,
2814
- command_id: str | NotGiven = NOT_GIVEN,
2815
- overlay: bool | NotGiven = NOT_GIVEN,
2816
- stop: str | NotGiven = NOT_GIVEN,
2778
+ client_state: str | Omit = omit,
2779
+ command_id: str | Omit = omit,
2780
+ overlay: bool | Omit = omit,
2781
+ stop: str | Omit = omit,
2817
2782
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2818
2783
  # The extra values given here take precedence over values defined on the client or passed to this method.
2819
2784
  extra_headers: Headers | None = None,
2820
2785
  extra_query: Query | None = None,
2821
2786
  extra_body: Body | None = None,
2822
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2787
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2823
2788
  ) -> ActionStopPlaybackResponse:
2824
2789
  """
2825
2790
  Stop audio being played on the call.
2826
2791
 
2827
- **Expected Webhooks (see
2828
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-playback#callbacks)
2829
- below):**
2792
+ **Expected Webhooks:**
2830
2793
 
2831
2794
  - `call.playback.ended` or `call.speak.ended`
2832
2795
 
@@ -2873,22 +2836,20 @@ class ActionsResource(SyncAPIResource):
2873
2836
  self,
2874
2837
  call_control_id: str,
2875
2838
  *,
2876
- client_state: str | NotGiven = NOT_GIVEN,
2877
- command_id: str | NotGiven = NOT_GIVEN,
2878
- recording_id: str | NotGiven = NOT_GIVEN,
2839
+ client_state: str | Omit = omit,
2840
+ command_id: str | Omit = omit,
2841
+ recording_id: str | Omit = omit,
2879
2842
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2880
2843
  # The extra values given here take precedence over values defined on the client or passed to this method.
2881
2844
  extra_headers: Headers | None = None,
2882
2845
  extra_query: Query | None = None,
2883
2846
  extra_body: Body | None = None,
2884
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2847
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2885
2848
  ) -> ActionStopRecordingResponse:
2886
2849
  """
2887
2850
  Stop recording the call.
2888
2851
 
2889
- **Expected Webhooks (see
2890
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-recording#callbacks)
2891
- below):**
2852
+ **Expected Webhooks:**
2892
2853
 
2893
2854
  - `call.recording.saved`
2894
2855
 
@@ -2931,14 +2892,14 @@ class ActionsResource(SyncAPIResource):
2931
2892
  self,
2932
2893
  call_control_id: str,
2933
2894
  *,
2934
- client_state: str | NotGiven = NOT_GIVEN,
2935
- command_id: str | NotGiven = NOT_GIVEN,
2895
+ client_state: str | Omit = omit,
2896
+ command_id: str | Omit = omit,
2936
2897
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2937
2898
  # The extra values given here take precedence over values defined on the client or passed to this method.
2938
2899
  extra_headers: Headers | None = None,
2939
2900
  extra_query: Query | None = None,
2940
2901
  extra_body: Body | None = None,
2941
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2902
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2942
2903
  ) -> ActionStopSiprecResponse:
2943
2904
  """
2944
2905
  Stop SIPREC session.
@@ -2983,22 +2944,20 @@ class ActionsResource(SyncAPIResource):
2983
2944
  self,
2984
2945
  call_control_id: str,
2985
2946
  *,
2986
- client_state: str | NotGiven = NOT_GIVEN,
2987
- command_id: str | NotGiven = NOT_GIVEN,
2988
- stream_id: str | NotGiven = NOT_GIVEN,
2947
+ client_state: str | Omit = omit,
2948
+ command_id: str | Omit = omit,
2949
+ stream_id: str | Omit = omit,
2989
2950
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
2990
2951
  # The extra values given here take precedence over values defined on the client or passed to this method.
2991
2952
  extra_headers: Headers | None = None,
2992
2953
  extra_query: Query | None = None,
2993
2954
  extra_body: Body | None = None,
2994
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
2955
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
2995
2956
  ) -> ActionStopStreamingResponse:
2996
2957
  """
2997
2958
  Stop streaming a call to a WebSocket.
2998
2959
 
2999
- **Expected Webhooks (see
3000
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-streaming#callbacks)
3001
- below):**
2960
+ **Expected Webhooks:**
3002
2961
 
3003
2962
  - `streaming.stopped`
3004
2963
 
@@ -3042,14 +3001,14 @@ class ActionsResource(SyncAPIResource):
3042
3001
  self,
3043
3002
  call_control_id: str,
3044
3003
  *,
3045
- client_state: str | NotGiven = NOT_GIVEN,
3046
- command_id: str | NotGiven = NOT_GIVEN,
3004
+ client_state: str | Omit = omit,
3005
+ command_id: str | Omit = omit,
3047
3006
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
3048
3007
  # The extra values given here take precedence over values defined on the client or passed to this method.
3049
3008
  extra_headers: Headers | None = None,
3050
3009
  extra_query: Query | None = None,
3051
3010
  extra_body: Body | None = None,
3052
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3011
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3053
3012
  ) -> ActionStopTranscriptionResponse:
3054
3013
  """
3055
3014
  Stop real-time transcription.
@@ -3096,7 +3055,7 @@ class ActionsResource(SyncAPIResource):
3096
3055
  extra_headers: Headers | None = None,
3097
3056
  extra_query: Query | None = None,
3098
3057
  extra_body: Body | None = None,
3099
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3058
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3100
3059
  ) -> ActionSwitchSupervisorRoleResponse:
3101
3060
  """Switch the supervisor role for a bridged call.
3102
3061
 
@@ -3134,36 +3093,43 @@ class ActionsResource(SyncAPIResource):
3134
3093
  answering_machine_detection: Literal[
3135
3094
  "premium", "detect", "detect_beep", "detect_words", "greeting_end", "disabled"
3136
3095
  ]
3137
- | NotGiven = NOT_GIVEN,
3138
- answering_machine_detection_config: action_transfer_params.AnsweringMachineDetectionConfig
3139
- | NotGiven = NOT_GIVEN,
3140
- audio_url: str | NotGiven = NOT_GIVEN,
3141
- client_state: str | NotGiven = NOT_GIVEN,
3142
- command_id: str | NotGiven = NOT_GIVEN,
3143
- custom_headers: Iterable[CustomSipHeaderParam] | NotGiven = NOT_GIVEN,
3144
- early_media: bool | NotGiven = NOT_GIVEN,
3145
- from_: str | NotGiven = NOT_GIVEN,
3146
- from_display_name: str | NotGiven = NOT_GIVEN,
3147
- media_encryption: Literal["disabled", "SRTP", "DTLS"] | NotGiven = NOT_GIVEN,
3148
- media_name: str | NotGiven = NOT_GIVEN,
3149
- mute_dtmf: Literal["none", "both", "self", "opposite"] | NotGiven = NOT_GIVEN,
3150
- park_after_unbridge: str | NotGiven = NOT_GIVEN,
3151
- sip_auth_password: str | NotGiven = NOT_GIVEN,
3152
- sip_auth_username: str | NotGiven = NOT_GIVEN,
3153
- sip_headers: Iterable[SipHeaderParam] | NotGiven = NOT_GIVEN,
3154
- sip_transport_protocol: Literal["UDP", "TCP", "TLS"] | NotGiven = NOT_GIVEN,
3155
- sound_modifications: SoundModificationsParam | NotGiven = NOT_GIVEN,
3156
- target_leg_client_state: str | NotGiven = NOT_GIVEN,
3157
- time_limit_secs: int | NotGiven = NOT_GIVEN,
3158
- timeout_secs: int | NotGiven = NOT_GIVEN,
3159
- webhook_url: str | NotGiven = NOT_GIVEN,
3160
- webhook_url_method: Literal["POST", "GET"] | NotGiven = NOT_GIVEN,
3096
+ | Omit = omit,
3097
+ answering_machine_detection_config: action_transfer_params.AnsweringMachineDetectionConfig | Omit = omit,
3098
+ audio_url: str | Omit = omit,
3099
+ client_state: str | Omit = omit,
3100
+ command_id: str | Omit = omit,
3101
+ custom_headers: Iterable[CustomSipHeaderParam] | Omit = omit,
3102
+ early_media: bool | Omit = omit,
3103
+ from_: str | Omit = omit,
3104
+ from_display_name: str | Omit = omit,
3105
+ media_encryption: Literal["disabled", "SRTP", "DTLS"] | Omit = omit,
3106
+ media_name: str | Omit = omit,
3107
+ mute_dtmf: Literal["none", "both", "self", "opposite"] | Omit = omit,
3108
+ park_after_unbridge: str | Omit = omit,
3109
+ record: Literal["record-from-answer"] | Omit = omit,
3110
+ record_channels: Literal["single", "dual"] | Omit = omit,
3111
+ record_custom_file_name: str | Omit = omit,
3112
+ record_format: Literal["wav", "mp3"] | Omit = omit,
3113
+ record_max_length: int | Omit = omit,
3114
+ record_timeout_secs: int | Omit = omit,
3115
+ record_track: Literal["both", "inbound", "outbound"] | Omit = omit,
3116
+ record_trim: Literal["trim-silence"] | Omit = omit,
3117
+ sip_auth_password: str | Omit = omit,
3118
+ sip_auth_username: str | Omit = omit,
3119
+ sip_headers: Iterable[SipHeaderParam] | Omit = omit,
3120
+ sip_transport_protocol: Literal["UDP", "TCP", "TLS"] | Omit = omit,
3121
+ sound_modifications: SoundModificationsParam | Omit = omit,
3122
+ target_leg_client_state: str | Omit = omit,
3123
+ time_limit_secs: int | Omit = omit,
3124
+ timeout_secs: int | Omit = omit,
3125
+ webhook_url: str | Omit = omit,
3126
+ webhook_url_method: Literal["POST", "GET"] | Omit = omit,
3161
3127
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
3162
3128
  # The extra values given here take precedence over values defined on the client or passed to this method.
3163
3129
  extra_headers: Headers | None = None,
3164
3130
  extra_query: Query | None = None,
3165
3131
  extra_body: Body | None = None,
3166
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3132
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3167
3133
  ) -> ActionTransferResponse:
3168
3134
  """Transfer a call to a new destination.
3169
3135
 
@@ -3173,9 +3139,7 @@ class ActionsResource(SyncAPIResource):
3173
3139
  may be issued additional commands, potentially transfering the call to an
3174
3140
  alternate destination.
3175
3141
 
3176
- **Expected Webhooks (see
3177
- [callback schema](https://developers.telnyx.com/api/call-control/transfer-call#callbacks)
3178
- below):**
3142
+ **Expected Webhooks:**
3179
3143
 
3180
3144
  - `call.initiated`
3181
3145
  - `call.bridged` to Leg B
@@ -3240,6 +3204,33 @@ class ActionsResource(SyncAPIResource):
3240
3204
  or is transferred). If supplied with the value `self`, the current leg will be
3241
3205
  parked after unbridge. If not set, the default behavior is to hang up the leg.
3242
3206
 
3207
+ record: Start recording automatically after an event. Disabled by default.
3208
+
3209
+ record_channels: Defines which channel should be recorded ('single' or 'dual') when `record` is
3210
+ specified.
3211
+
3212
+ record_custom_file_name: The custom recording file name to be used instead of the default `call_leg_id`.
3213
+ Telnyx will still add a Unix timestamp suffix.
3214
+
3215
+ record_format: Defines the format of the recording ('wav' or 'mp3') when `record` is specified.
3216
+
3217
+ record_max_length: Defines the maximum length for the recording in seconds when `record` is
3218
+ specified. The minimum value is 0. The maximum value is 43200. The default value
3219
+ is 0 (infinite).
3220
+
3221
+ record_timeout_secs: The number of seconds that Telnyx will wait for the recording to be stopped if
3222
+ silence is detected when `record` is specified. The timer only starts when the
3223
+ speech is detected. Please note that call transcription is used to detect
3224
+ silence and the related charge will be applied. The minimum value is 0. The
3225
+ default value is 0 (infinite).
3226
+
3227
+ record_track: The audio track to be recorded. Can be either `both`, `inbound` or `outbound`.
3228
+ If only single track is specified (`inbound`, `outbound`), `channels`
3229
+ configuration is ignored and it will be recorded as mono (single channel).
3230
+
3231
+ record_trim: When set to `trim-silence`, silence will be removed from the beginning and end
3232
+ of the recording.
3233
+
3243
3234
  sip_auth_password: SIP Authentication password used for SIP challenges.
3244
3235
 
3245
3236
  sip_auth_username: SIP Authentication username used for SIP challenges.
@@ -3300,6 +3291,14 @@ class ActionsResource(SyncAPIResource):
3300
3291
  "media_name": media_name,
3301
3292
  "mute_dtmf": mute_dtmf,
3302
3293
  "park_after_unbridge": park_after_unbridge,
3294
+ "record": record,
3295
+ "record_channels": record_channels,
3296
+ "record_custom_file_name": record_custom_file_name,
3297
+ "record_format": record_format,
3298
+ "record_max_length": record_max_length,
3299
+ "record_timeout_secs": record_timeout_secs,
3300
+ "record_track": record_track,
3301
+ "record_trim": record_trim,
3303
3302
  "sip_auth_password": sip_auth_password,
3304
3303
  "sip_auth_username": sip_auth_username,
3305
3304
  "sip_headers": sip_headers,
@@ -3329,7 +3328,7 @@ class ActionsResource(SyncAPIResource):
3329
3328
  extra_headers: Headers | None = None,
3330
3329
  extra_query: Query | None = None,
3331
3330
  extra_body: Body | None = None,
3332
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3331
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3333
3332
  ) -> ActionUpdateClientStateResponse:
3334
3333
  """
3335
3334
  Updates client state
@@ -3384,47 +3383,45 @@ class AsyncActionsResource(AsyncAPIResource):
3384
3383
  self,
3385
3384
  call_control_id: str,
3386
3385
  *,
3387
- billing_group_id: str | NotGiven = NOT_GIVEN,
3388
- client_state: str | NotGiven = NOT_GIVEN,
3389
- command_id: str | NotGiven = NOT_GIVEN,
3390
- custom_headers: Iterable[CustomSipHeaderParam] | NotGiven = NOT_GIVEN,
3391
- preferred_codecs: Literal["G722,PCMU,PCMA,G729,OPUS,VP8,H264"] | NotGiven = NOT_GIVEN,
3392
- record: Literal["record-from-answer"] | NotGiven = NOT_GIVEN,
3393
- record_channels: Literal["single", "dual"] | NotGiven = NOT_GIVEN,
3394
- record_custom_file_name: str | NotGiven = NOT_GIVEN,
3395
- record_format: Literal["wav", "mp3"] | NotGiven = NOT_GIVEN,
3396
- record_max_length: int | NotGiven = NOT_GIVEN,
3397
- record_timeout_secs: int | NotGiven = NOT_GIVEN,
3398
- record_track: Literal["both", "inbound", "outbound"] | NotGiven = NOT_GIVEN,
3399
- record_trim: Literal["trim-silence"] | NotGiven = NOT_GIVEN,
3400
- send_silence_when_idle: bool | NotGiven = NOT_GIVEN,
3401
- sip_headers: Iterable[SipHeaderParam] | NotGiven = NOT_GIVEN,
3402
- sound_modifications: SoundModificationsParam | NotGiven = NOT_GIVEN,
3403
- stream_bidirectional_codec: StreamBidirectionalCodec | NotGiven = NOT_GIVEN,
3404
- stream_bidirectional_mode: StreamBidirectionalMode | NotGiven = NOT_GIVEN,
3405
- stream_bidirectional_target_legs: StreamBidirectionalTargetLegs | NotGiven = NOT_GIVEN,
3406
- stream_codec: StreamCodec | NotGiven = NOT_GIVEN,
3407
- stream_track: Literal["inbound_track", "outbound_track", "both_tracks"] | NotGiven = NOT_GIVEN,
3408
- stream_url: str | NotGiven = NOT_GIVEN,
3409
- transcription: bool | NotGiven = NOT_GIVEN,
3410
- transcription_config: TranscriptionStartRequestParam | NotGiven = NOT_GIVEN,
3411
- webhook_url: str | NotGiven = NOT_GIVEN,
3412
- webhook_url_method: Literal["POST", "GET"] | NotGiven = NOT_GIVEN,
3386
+ billing_group_id: str | Omit = omit,
3387
+ client_state: str | Omit = omit,
3388
+ command_id: str | Omit = omit,
3389
+ custom_headers: Iterable[CustomSipHeaderParam] | Omit = omit,
3390
+ preferred_codecs: Literal["G722,PCMU,PCMA,G729,OPUS,VP8,H264"] | Omit = omit,
3391
+ record: Literal["record-from-answer"] | Omit = omit,
3392
+ record_channels: Literal["single", "dual"] | Omit = omit,
3393
+ record_custom_file_name: str | Omit = omit,
3394
+ record_format: Literal["wav", "mp3"] | Omit = omit,
3395
+ record_max_length: int | Omit = omit,
3396
+ record_timeout_secs: int | Omit = omit,
3397
+ record_track: Literal["both", "inbound", "outbound"] | Omit = omit,
3398
+ record_trim: Literal["trim-silence"] | Omit = omit,
3399
+ send_silence_when_idle: bool | Omit = omit,
3400
+ sip_headers: Iterable[SipHeaderParam] | Omit = omit,
3401
+ sound_modifications: SoundModificationsParam | Omit = omit,
3402
+ stream_bidirectional_codec: StreamBidirectionalCodec | Omit = omit,
3403
+ stream_bidirectional_mode: StreamBidirectionalMode | Omit = omit,
3404
+ stream_bidirectional_target_legs: StreamBidirectionalTargetLegs | Omit = omit,
3405
+ stream_codec: StreamCodec | Omit = omit,
3406
+ stream_track: Literal["inbound_track", "outbound_track", "both_tracks"] | Omit = omit,
3407
+ stream_url: str | Omit = omit,
3408
+ transcription: bool | Omit = omit,
3409
+ transcription_config: TranscriptionStartRequestParam | Omit = omit,
3410
+ webhook_url: str | Omit = omit,
3411
+ webhook_url_method: Literal["POST", "GET"] | Omit = omit,
3413
3412
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
3414
3413
  # The extra values given here take precedence over values defined on the client or passed to this method.
3415
3414
  extra_headers: Headers | None = None,
3416
3415
  extra_query: Query | None = None,
3417
3416
  extra_body: Body | None = None,
3418
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3417
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3419
3418
  ) -> ActionAnswerResponse:
3420
3419
  """Answer an incoming call.
3421
3420
 
3422
3421
  You must issue this command before executing subsequent
3423
3422
  commands on an incoming call.
3424
3423
 
3425
- **Expected Webhooks (see
3426
- [callback schema](https://developers.telnyx.com/api/call-control/answer-call#callbacks)
3427
- below):**
3424
+ **Expected Webhooks:**
3428
3425
 
3429
3426
  - `call.answered`
3430
3427
  - `streaming.started`, `streaming.stopped` or `streaming.failed` if `stream_url`
@@ -3491,7 +3488,6 @@ class AsyncActionsResource(AsyncAPIResource):
3491
3488
 
3492
3489
  stream_codec: Specifies the codec to be used for the streamed audio. When set to 'default' or
3493
3490
  when transcoding is not possible, the codec from the call will be used.
3494
- Currently, transcoding is only supported between PCMU and PCMA codecs.
3495
3491
 
3496
3492
  stream_track: Specifies which track should be streamed.
3497
3493
 
@@ -3558,20 +3554,20 @@ class AsyncActionsResource(AsyncAPIResource):
3558
3554
  path_call_control_id: str,
3559
3555
  *,
3560
3556
  body_call_control_id: str,
3561
- client_state: str | NotGiven = NOT_GIVEN,
3562
- command_id: str | NotGiven = NOT_GIVEN,
3563
- mute_dtmf: Literal["none", "both", "self", "opposite"] | NotGiven = NOT_GIVEN,
3564
- park_after_unbridge: str | NotGiven = NOT_GIVEN,
3565
- play_ringtone: bool | NotGiven = NOT_GIVEN,
3566
- queue: str | NotGiven = NOT_GIVEN,
3567
- record: Literal["record-from-answer"] | NotGiven = NOT_GIVEN,
3568
- record_channels: Literal["single", "dual"] | NotGiven = NOT_GIVEN,
3569
- record_custom_file_name: str | NotGiven = NOT_GIVEN,
3570
- record_format: Literal["wav", "mp3"] | NotGiven = NOT_GIVEN,
3571
- record_max_length: int | NotGiven = NOT_GIVEN,
3572
- record_timeout_secs: int | NotGiven = NOT_GIVEN,
3573
- record_track: Literal["both", "inbound", "outbound"] | NotGiven = NOT_GIVEN,
3574
- record_trim: Literal["trim-silence"] | NotGiven = NOT_GIVEN,
3557
+ client_state: str | Omit = omit,
3558
+ command_id: str | Omit = omit,
3559
+ mute_dtmf: Literal["none", "both", "self", "opposite"] | Omit = omit,
3560
+ park_after_unbridge: str | Omit = omit,
3561
+ play_ringtone: bool | Omit = omit,
3562
+ queue: str | Omit = omit,
3563
+ record: Literal["record-from-answer"] | Omit = omit,
3564
+ record_channels: Literal["single", "dual"] | Omit = omit,
3565
+ record_custom_file_name: str | Omit = omit,
3566
+ record_format: Literal["wav", "mp3"] | Omit = omit,
3567
+ record_max_length: int | Omit = omit,
3568
+ record_timeout_secs: int | Omit = omit,
3569
+ record_track: Literal["both", "inbound", "outbound"] | Omit = omit,
3570
+ record_trim: Literal["trim-silence"] | Omit = omit,
3575
3571
  ringtone: Literal[
3576
3572
  "at",
3577
3573
  "au",
@@ -3614,22 +3610,20 @@ class AsyncActionsResource(AsyncAPIResource):
3614
3610
  "ve",
3615
3611
  "za",
3616
3612
  ]
3617
- | NotGiven = NOT_GIVEN,
3618
- video_room_context: str | NotGiven = NOT_GIVEN,
3619
- video_room_id: str | NotGiven = NOT_GIVEN,
3613
+ | Omit = omit,
3614
+ video_room_context: str | Omit = omit,
3615
+ video_room_id: str | Omit = omit,
3620
3616
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
3621
3617
  # The extra values given here take precedence over values defined on the client or passed to this method.
3622
3618
  extra_headers: Headers | None = None,
3623
3619
  extra_query: Query | None = None,
3624
3620
  extra_body: Body | None = None,
3625
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3621
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3626
3622
  ) -> ActionBridgeResponse:
3627
3623
  """
3628
3624
  Bridge two call control calls.
3629
3625
 
3630
- **Expected Webhooks (see
3631
- [callback schema](https://developers.telnyx.com/api/call-control/bridge-call#callbacks)
3632
- below):**
3626
+ **Expected Webhooks:**
3633
3627
 
3634
3628
  - `call.bridged` for Leg A
3635
3629
  - `call.bridged` for Leg B
@@ -3746,16 +3740,16 @@ class AsyncActionsResource(AsyncAPIResource):
3746
3740
  call_control_id: str,
3747
3741
  *,
3748
3742
  queue_name: str,
3749
- client_state: str | NotGiven = NOT_GIVEN,
3750
- command_id: str | NotGiven = NOT_GIVEN,
3751
- max_size: int | NotGiven = NOT_GIVEN,
3752
- max_wait_time_secs: int | NotGiven = NOT_GIVEN,
3743
+ client_state: str | Omit = omit,
3744
+ command_id: str | Omit = omit,
3745
+ max_size: int | Omit = omit,
3746
+ max_wait_time_secs: int | Omit = omit,
3753
3747
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
3754
3748
  # The extra values given here take precedence over values defined on the client or passed to this method.
3755
3749
  extra_headers: Headers | None = None,
3756
3750
  extra_query: Query | None = None,
3757
3751
  extra_body: Body | None = None,
3758
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3752
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3759
3753
  ) -> ActionEnqueueResponse:
3760
3754
  """
3761
3755
  Put the call in a queue.
@@ -3807,22 +3801,22 @@ class AsyncActionsResource(AsyncAPIResource):
3807
3801
  self,
3808
3802
  call_control_id: str,
3809
3803
  *,
3810
- client_state: str | NotGiven = NOT_GIVEN,
3811
- command_id: str | NotGiven = NOT_GIVEN,
3812
- gather_id: str | NotGiven = NOT_GIVEN,
3813
- initial_timeout_millis: int | NotGiven = NOT_GIVEN,
3814
- inter_digit_timeout_millis: int | NotGiven = NOT_GIVEN,
3815
- maximum_digits: int | NotGiven = NOT_GIVEN,
3816
- minimum_digits: int | NotGiven = NOT_GIVEN,
3817
- terminating_digit: str | NotGiven = NOT_GIVEN,
3818
- timeout_millis: int | NotGiven = NOT_GIVEN,
3819
- valid_digits: str | NotGiven = NOT_GIVEN,
3804
+ client_state: str | Omit = omit,
3805
+ command_id: str | Omit = omit,
3806
+ gather_id: str | Omit = omit,
3807
+ initial_timeout_millis: int | Omit = omit,
3808
+ inter_digit_timeout_millis: int | Omit = omit,
3809
+ maximum_digits: int | Omit = omit,
3810
+ minimum_digits: int | Omit = omit,
3811
+ terminating_digit: str | Omit = omit,
3812
+ timeout_millis: int | Omit = omit,
3813
+ valid_digits: str | Omit = omit,
3820
3814
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
3821
3815
  # The extra values given here take precedence over values defined on the client or passed to this method.
3822
3816
  extra_headers: Headers | None = None,
3823
3817
  extra_query: Query | None = None,
3824
3818
  extra_body: Body | None = None,
3825
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3819
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3826
3820
  ) -> ActionGatherResponse:
3827
3821
  """
3828
3822
  Gather DTMF signals to build interactive menus.
@@ -3830,9 +3824,7 @@ class AsyncActionsResource(AsyncAPIResource):
3830
3824
  You can pass a list of valid digits. The `Answer` command must be issued before
3831
3825
  the `gather` command.
3832
3826
 
3833
- **Expected Webhooks (see
3834
- [callback schema](https://developers.telnyx.com/api/call-control/gather-call#callbacks)
3835
- below):**
3827
+ **Expected Webhooks:**
3836
3828
 
3837
3829
  - `call.dtmf.received` (you may receive many of these webhooks)
3838
3830
  - `call.gather.ended`
@@ -3901,25 +3893,25 @@ class AsyncActionsResource(AsyncAPIResource):
3901
3893
  call_control_id: str,
3902
3894
  *,
3903
3895
  parameters: object,
3904
- assistant: AssistantParam | NotGiven = NOT_GIVEN,
3905
- client_state: str | NotGiven = NOT_GIVEN,
3906
- command_id: str | NotGiven = NOT_GIVEN,
3907
- greeting: str | NotGiven = NOT_GIVEN,
3908
- interruption_settings: InterruptionSettingsParam | NotGiven = NOT_GIVEN,
3909
- language: GoogleTranscriptionLanguage | NotGiven = NOT_GIVEN,
3910
- message_history: Iterable[action_gather_using_ai_params.MessageHistory] | NotGiven = NOT_GIVEN,
3911
- send_message_history_updates: bool | NotGiven = NOT_GIVEN,
3912
- send_partial_results: bool | NotGiven = NOT_GIVEN,
3913
- transcription: TranscriptionConfigParam | NotGiven = NOT_GIVEN,
3914
- user_response_timeout_ms: int | NotGiven = NOT_GIVEN,
3915
- voice: str | NotGiven = NOT_GIVEN,
3916
- voice_settings: action_gather_using_ai_params.VoiceSettings | NotGiven = NOT_GIVEN,
3896
+ assistant: AssistantParam | Omit = omit,
3897
+ client_state: str | Omit = omit,
3898
+ command_id: str | Omit = omit,
3899
+ greeting: str | Omit = omit,
3900
+ interruption_settings: InterruptionSettingsParam | Omit = omit,
3901
+ language: GoogleTranscriptionLanguage | Omit = omit,
3902
+ message_history: Iterable[action_gather_using_ai_params.MessageHistory] | Omit = omit,
3903
+ send_message_history_updates: bool | Omit = omit,
3904
+ send_partial_results: bool | Omit = omit,
3905
+ transcription: TranscriptionConfigParam | Omit = omit,
3906
+ user_response_timeout_ms: int | Omit = omit,
3907
+ voice: str | Omit = omit,
3908
+ voice_settings: action_gather_using_ai_params.VoiceSettings | Omit = omit,
3917
3909
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
3918
3910
  # The extra values given here take precedence over values defined on the client or passed to this method.
3919
3911
  extra_headers: Headers | None = None,
3920
3912
  extra_query: Query | None = None,
3921
3913
  extra_body: Body | None = None,
3922
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
3914
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
3923
3915
  ) -> ActionGatherUsingAIResponse:
3924
3916
  """
3925
3917
  Gather parameters defined in the request payload using a voice assistant.
@@ -3927,9 +3919,7 @@ class AsyncActionsResource(AsyncAPIResource):
3927
3919
  You can pass parameters described as a JSON Schema object and the voice
3928
3920
  assistant will attempt to gather these informations.
3929
3921
 
3930
- **Expected Webhooks (see
3931
- [callback schema](https://developers.telnyx.com/api/call-control/call-gather-using-ai#callbacks)
3932
- below):**
3922
+ **Expected Webhooks:**
3933
3923
 
3934
3924
  - `call.ai_gather.ended`
3935
3925
  - `call.conversation.ended`
@@ -3964,16 +3954,13 @@ class AsyncActionsResource(AsyncAPIResource):
3964
3954
  information to the voice assistant.
3965
3955
 
3966
3956
  send_message_history_updates: Default is `false`. If set to `true`, the voice assistant will send updates to
3967
- the message history via the `call.ai_gather.message_history_updated`
3968
- [callback](https://developers.telnyx.com/api/call-control/call-gather-using-ai#callbacks)
3969
- in real time as the message history is updated.
3957
+ the message history via the `call.ai_gather.message_history_updated` callback in
3958
+ real time as the message history is updated.
3970
3959
 
3971
3960
  send_partial_results: Default is `false`. If set to `true`, the voice assistant will send partial
3972
- results via the `call.ai_gather.partial_results`
3973
- [callback](https://developers.telnyx.com/api/call-control/call-gather-using-ai#callbacks)
3974
- in real time as individual fields are gathered. If set to `false`, the voice
3975
- assistant will only send the final result via the `call.ai_gather.ended`
3976
- callback.
3961
+ results via the `call.ai_gather.partial_results` callback in real time as
3962
+ individual fields are gathered. If set to `false`, the voice assistant will only
3963
+ send the final result via the `call.ai_gather.ended` callback.
3977
3964
 
3978
3965
  transcription: The settings associated with speech to text for the voice assistant. This is
3979
3966
  only relevant if the assistant uses a text-to-text language model. Any assistant
@@ -4049,25 +4036,25 @@ class AsyncActionsResource(AsyncAPIResource):
4049
4036
  self,
4050
4037
  call_control_id: str,
4051
4038
  *,
4052
- audio_url: str | NotGiven = NOT_GIVEN,
4053
- client_state: str | NotGiven = NOT_GIVEN,
4054
- command_id: str | NotGiven = NOT_GIVEN,
4055
- inter_digit_timeout_millis: int | NotGiven = NOT_GIVEN,
4056
- invalid_audio_url: str | NotGiven = NOT_GIVEN,
4057
- invalid_media_name: str | NotGiven = NOT_GIVEN,
4058
- maximum_digits: int | NotGiven = NOT_GIVEN,
4059
- maximum_tries: int | NotGiven = NOT_GIVEN,
4060
- media_name: str | NotGiven = NOT_GIVEN,
4061
- minimum_digits: int | NotGiven = NOT_GIVEN,
4062
- terminating_digit: str | NotGiven = NOT_GIVEN,
4063
- timeout_millis: int | NotGiven = NOT_GIVEN,
4064
- valid_digits: str | NotGiven = NOT_GIVEN,
4039
+ audio_url: str | Omit = omit,
4040
+ client_state: str | Omit = omit,
4041
+ command_id: str | Omit = omit,
4042
+ inter_digit_timeout_millis: int | Omit = omit,
4043
+ invalid_audio_url: str | Omit = omit,
4044
+ invalid_media_name: str | Omit = omit,
4045
+ maximum_digits: int | Omit = omit,
4046
+ maximum_tries: int | Omit = omit,
4047
+ media_name: str | Omit = omit,
4048
+ minimum_digits: int | Omit = omit,
4049
+ terminating_digit: str | Omit = omit,
4050
+ timeout_millis: int | Omit = omit,
4051
+ valid_digits: str | Omit = omit,
4065
4052
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4066
4053
  # The extra values given here take precedence over values defined on the client or passed to this method.
4067
4054
  extra_headers: Headers | None = None,
4068
4055
  extra_query: Query | None = None,
4069
4056
  extra_body: Body | None = None,
4070
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4057
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4071
4058
  ) -> ActionGatherUsingAudioResponse:
4072
4059
  """
4073
4060
  Play an audio file on the call until the required DTMF signals are gathered to
@@ -4078,9 +4065,7 @@ class AsyncActionsResource(AsyncAPIResource):
4078
4065
  interrupted when a DTMF signal is received. The
4079
4066
  `Answer command must be issued before the `gather_using_audio` command.
4080
4067
 
4081
- **Expected Webhooks (see
4082
- [callback schema](https://developers.telnyx.com/api/call-control/gather-using-audio#callbacks)
4083
- below):**
4068
+ **Expected Webhooks:**
4084
4069
 
4085
4070
  - `call.playback.started`
4086
4071
  - `call.playback.ended`
@@ -4173,10 +4158,10 @@ class AsyncActionsResource(AsyncAPIResource):
4173
4158
  *,
4174
4159
  payload: str,
4175
4160
  voice: str,
4176
- client_state: str | NotGiven = NOT_GIVEN,
4177
- command_id: str | NotGiven = NOT_GIVEN,
4178
- inter_digit_timeout_millis: int | NotGiven = NOT_GIVEN,
4179
- invalid_payload: str | NotGiven = NOT_GIVEN,
4161
+ client_state: str | Omit = omit,
4162
+ command_id: str | Omit = omit,
4163
+ inter_digit_timeout_millis: int | Omit = omit,
4164
+ invalid_payload: str | Omit = omit,
4180
4165
  language: Literal[
4181
4166
  "arb",
4182
4167
  "cmn-CN",
@@ -4208,22 +4193,22 @@ class AsyncActionsResource(AsyncAPIResource):
4208
4193
  "sv-SE",
4209
4194
  "tr-TR",
4210
4195
  ]
4211
- | NotGiven = NOT_GIVEN,
4212
- maximum_digits: int | NotGiven = NOT_GIVEN,
4213
- maximum_tries: int | NotGiven = NOT_GIVEN,
4214
- minimum_digits: int | NotGiven = NOT_GIVEN,
4215
- payload_type: Literal["text", "ssml"] | NotGiven = NOT_GIVEN,
4216
- service_level: Literal["basic", "premium"] | NotGiven = NOT_GIVEN,
4217
- terminating_digit: str | NotGiven = NOT_GIVEN,
4218
- timeout_millis: int | NotGiven = NOT_GIVEN,
4219
- valid_digits: str | NotGiven = NOT_GIVEN,
4220
- voice_settings: action_gather_using_speak_params.VoiceSettings | NotGiven = NOT_GIVEN,
4196
+ | Omit = omit,
4197
+ maximum_digits: int | Omit = omit,
4198
+ maximum_tries: int | Omit = omit,
4199
+ minimum_digits: int | Omit = omit,
4200
+ payload_type: Literal["text", "ssml"] | Omit = omit,
4201
+ service_level: Literal["basic", "premium"] | Omit = omit,
4202
+ terminating_digit: str | Omit = omit,
4203
+ timeout_millis: int | Omit = omit,
4204
+ valid_digits: str | Omit = omit,
4205
+ voice_settings: action_gather_using_speak_params.VoiceSettings | Omit = omit,
4221
4206
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4222
4207
  # The extra values given here take precedence over values defined on the client or passed to this method.
4223
4208
  extra_headers: Headers | None = None,
4224
4209
  extra_query: Query | None = None,
4225
4210
  extra_body: Body | None = None,
4226
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4211
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4227
4212
  ) -> ActionGatherUsingSpeakResponse:
4228
4213
  """
4229
4214
  Convert text to speech and play it on the call until the required DTMF signals
@@ -4234,9 +4219,7 @@ class AsyncActionsResource(AsyncAPIResource):
4234
4219
  a DTMF signal is received. The `Answer` command must be issued before the
4235
4220
  `gather_using_speak` command.
4236
4221
 
4237
- **Expected Webhooks (see
4238
- [callback schema](https://developers.telnyx.com/api/call-control/gather-using-speak#callbacks)
4239
- below):**
4222
+ **Expected Webhooks:**
4240
4223
 
4241
4224
  - `call.dtmf.received` (you may receive many of these webhooks)
4242
4225
  - `call.gather.ended`
@@ -4355,21 +4338,19 @@ class AsyncActionsResource(AsyncAPIResource):
4355
4338
  self,
4356
4339
  call_control_id: str,
4357
4340
  *,
4358
- client_state: str | NotGiven = NOT_GIVEN,
4359
- command_id: str | NotGiven = NOT_GIVEN,
4341
+ client_state: str | Omit = omit,
4342
+ command_id: str | Omit = omit,
4360
4343
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4361
4344
  # The extra values given here take precedence over values defined on the client or passed to this method.
4362
4345
  extra_headers: Headers | None = None,
4363
4346
  extra_query: Query | None = None,
4364
4347
  extra_body: Body | None = None,
4365
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4348
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4366
4349
  ) -> ActionHangupResponse:
4367
4350
  """
4368
4351
  Hang up the call.
4369
4352
 
4370
- **Expected Webhooks (see
4371
- [callback schema](https://developers.telnyx.com/api/call-control/hangup-call#callbacks)
4372
- below):**
4353
+ **Expected Webhooks:**
4373
4354
 
4374
4355
  - `call.hangup`
4375
4356
  - `call.recording.saved`
@@ -4410,14 +4391,14 @@ class AsyncActionsResource(AsyncAPIResource):
4410
4391
  self,
4411
4392
  call_control_id: str,
4412
4393
  *,
4413
- client_state: str | NotGiven = NOT_GIVEN,
4414
- command_id: str | NotGiven = NOT_GIVEN,
4394
+ client_state: str | Omit = omit,
4395
+ command_id: str | Omit = omit,
4415
4396
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4416
4397
  # The extra values given here take precedence over values defined on the client or passed to this method.
4417
4398
  extra_headers: Headers | None = None,
4418
4399
  extra_query: Query | None = None,
4419
4400
  extra_body: Body | None = None,
4420
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4401
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4421
4402
  ) -> ActionLeaveQueueResponse:
4422
4403
  """
4423
4404
  Removes the call from a queue.
@@ -4458,15 +4439,15 @@ class AsyncActionsResource(AsyncAPIResource):
4458
4439
  self,
4459
4440
  call_control_id: str,
4460
4441
  *,
4461
- client_state: str | NotGiven = NOT_GIVEN,
4462
- command_id: str | NotGiven = NOT_GIVEN,
4463
- recording_id: str | NotGiven = NOT_GIVEN,
4442
+ client_state: str | Omit = omit,
4443
+ command_id: str | Omit = omit,
4444
+ recording_id: str | Omit = omit,
4464
4445
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4465
4446
  # The extra values given here take precedence over values defined on the client or passed to this method.
4466
4447
  extra_headers: Headers | None = None,
4467
4448
  extra_query: Query | None = None,
4468
4449
  extra_body: Body | None = None,
4469
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4450
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4470
4451
  ) -> ActionPauseRecordingResponse:
4471
4452
  """Pause recording the call.
4472
4453
 
@@ -4516,27 +4497,25 @@ class AsyncActionsResource(AsyncAPIResource):
4516
4497
  call_control_id: str,
4517
4498
  *,
4518
4499
  sip_address: str,
4519
- client_state: str | NotGiven = NOT_GIVEN,
4520
- command_id: str | NotGiven = NOT_GIVEN,
4521
- custom_headers: Iterable[CustomSipHeaderParam] | NotGiven = NOT_GIVEN,
4522
- sip_auth_password: str | NotGiven = NOT_GIVEN,
4523
- sip_auth_username: str | NotGiven = NOT_GIVEN,
4524
- sip_headers: Iterable[SipHeaderParam] | NotGiven = NOT_GIVEN,
4500
+ client_state: str | Omit = omit,
4501
+ command_id: str | Omit = omit,
4502
+ custom_headers: Iterable[CustomSipHeaderParam] | Omit = omit,
4503
+ sip_auth_password: str | Omit = omit,
4504
+ sip_auth_username: str | Omit = omit,
4505
+ sip_headers: Iterable[SipHeaderParam] | Omit = omit,
4525
4506
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4526
4507
  # The extra values given here take precedence over values defined on the client or passed to this method.
4527
4508
  extra_headers: Headers | None = None,
4528
4509
  extra_query: Query | None = None,
4529
4510
  extra_body: Body | None = None,
4530
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4511
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4531
4512
  ) -> ActionReferResponse:
4532
4513
  """Initiate a SIP Refer on a Call Control call.
4533
4514
 
4534
4515
  You can initiate a SIP Refer at any
4535
4516
  point in the duration of a call.
4536
4517
 
4537
- **Expected Webhooks (see
4538
- [callback schema](https://developers.telnyx.com/api/call-control/refer-call#callbacks)
4539
- below):**
4518
+ **Expected Webhooks:**
4540
4519
 
4541
4520
  - `call.refer.started`
4542
4521
  - `call.refer.completed`
@@ -4596,21 +4575,19 @@ class AsyncActionsResource(AsyncAPIResource):
4596
4575
  call_control_id: str,
4597
4576
  *,
4598
4577
  cause: Literal["CALL_REJECTED", "USER_BUSY"],
4599
- client_state: str | NotGiven = NOT_GIVEN,
4600
- command_id: str | NotGiven = NOT_GIVEN,
4578
+ client_state: str | Omit = omit,
4579
+ command_id: str | Omit = omit,
4601
4580
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4602
4581
  # The extra values given here take precedence over values defined on the client or passed to this method.
4603
4582
  extra_headers: Headers | None = None,
4604
4583
  extra_query: Query | None = None,
4605
4584
  extra_body: Body | None = None,
4606
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4585
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4607
4586
  ) -> ActionRejectResponse:
4608
4587
  """
4609
4588
  Reject an incoming call.
4610
4589
 
4611
- **Expected Webhooks (see
4612
- [callback schema](https://developers.telnyx.com/api/call-control/reject-call#callbacks)
4613
- below):**
4590
+ **Expected Webhooks:**
4614
4591
 
4615
4592
  - `call.hangup`
4616
4593
 
@@ -4653,15 +4630,15 @@ class AsyncActionsResource(AsyncAPIResource):
4653
4630
  self,
4654
4631
  call_control_id: str,
4655
4632
  *,
4656
- client_state: str | NotGiven = NOT_GIVEN,
4657
- command_id: str | NotGiven = NOT_GIVEN,
4658
- recording_id: str | NotGiven = NOT_GIVEN,
4633
+ client_state: str | Omit = omit,
4634
+ command_id: str | Omit = omit,
4635
+ recording_id: str | Omit = omit,
4659
4636
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4660
4637
  # The extra values given here take precedence over values defined on the client or passed to this method.
4661
4638
  extra_headers: Headers | None = None,
4662
4639
  extra_query: Query | None = None,
4663
4640
  extra_body: Body | None = None,
4664
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4641
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4665
4642
  ) -> ActionResumeRecordingResponse:
4666
4643
  """
4667
4644
  Resume recording the call.
@@ -4710,15 +4687,15 @@ class AsyncActionsResource(AsyncAPIResource):
4710
4687
  call_control_id: str,
4711
4688
  *,
4712
4689
  digits: str,
4713
- client_state: str | NotGiven = NOT_GIVEN,
4714
- command_id: str | NotGiven = NOT_GIVEN,
4715
- duration_millis: int | NotGiven = NOT_GIVEN,
4690
+ client_state: str | Omit = omit,
4691
+ command_id: str | Omit = omit,
4692
+ duration_millis: int | Omit = omit,
4716
4693
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4717
4694
  # The extra values given here take precedence over values defined on the client or passed to this method.
4718
4695
  extra_headers: Headers | None = None,
4719
4696
  extra_query: Query | None = None,
4720
4697
  extra_body: Body | None = None,
4721
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4698
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4722
4699
  ) -> ActionSendDtmfResponse:
4723
4700
  """Sends DTMF tones from this leg.
4724
4701
 
@@ -4775,14 +4752,14 @@ class AsyncActionsResource(AsyncAPIResource):
4775
4752
  *,
4776
4753
  body: str,
4777
4754
  content_type: str,
4778
- client_state: str | NotGiven = NOT_GIVEN,
4779
- command_id: str | NotGiven = NOT_GIVEN,
4755
+ client_state: str | Omit = omit,
4756
+ command_id: str | Omit = omit,
4780
4757
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4781
4758
  # The extra values given here take precedence over values defined on the client or passed to this method.
4782
4759
  extra_headers: Headers | None = None,
4783
4760
  extra_query: Query | None = None,
4784
4761
  extra_body: Body | None = None,
4785
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4762
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4786
4763
  ) -> ActionSendSipInfoResponse:
4787
4764
  """
4788
4765
  Sends SIP info from this leg.
@@ -4836,8 +4813,8 @@ class AsyncActionsResource(AsyncAPIResource):
4836
4813
  *,
4837
4814
  payload: str,
4838
4815
  voice: str,
4839
- client_state: str | NotGiven = NOT_GIVEN,
4840
- command_id: str | NotGiven = NOT_GIVEN,
4816
+ client_state: str | Omit = omit,
4817
+ command_id: str | Omit = omit,
4841
4818
  language: Literal[
4842
4819
  "arb",
4843
4820
  "cmn-CN",
@@ -4869,17 +4846,17 @@ class AsyncActionsResource(AsyncAPIResource):
4869
4846
  "sv-SE",
4870
4847
  "tr-TR",
4871
4848
  ]
4872
- | NotGiven = NOT_GIVEN,
4873
- payload_type: Literal["text", "ssml"] | NotGiven = NOT_GIVEN,
4874
- service_level: Literal["basic", "premium"] | NotGiven = NOT_GIVEN,
4875
- stop: str | NotGiven = NOT_GIVEN,
4876
- voice_settings: action_speak_params.VoiceSettings | NotGiven = NOT_GIVEN,
4849
+ | Omit = omit,
4850
+ payload_type: Literal["text", "ssml"] | Omit = omit,
4851
+ service_level: Literal["basic", "premium"] | Omit = omit,
4852
+ stop: str | Omit = omit,
4853
+ voice_settings: action_speak_params.VoiceSettings | Omit = omit,
4877
4854
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4878
4855
  # The extra values given here take precedence over values defined on the client or passed to this method.
4879
4856
  extra_headers: Headers | None = None,
4880
4857
  extra_query: Query | None = None,
4881
4858
  extra_body: Body | None = None,
4882
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4859
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
4883
4860
  ) -> ActionSpeakResponse:
4884
4861
  """Convert text to speech and play it back on the call.
4885
4862
 
@@ -4887,9 +4864,7 @@ class AsyncActionsResource(AsyncAPIResource):
4887
4864
  commands are issued consecutively, the audio files will be placed in a queue
4888
4865
  awaiting playback.
4889
4866
 
4890
- **Expected Webhooks (see
4891
- [callback schema](https://developers.telnyx.com/api/call-control/speak-call#callbacks)
4892
- below):**
4867
+ **Expected Webhooks:**
4893
4868
 
4894
4869
  - `call.speak.started`
4895
4870
  - `call.speak.ended`
@@ -4984,27 +4959,25 @@ class AsyncActionsResource(AsyncAPIResource):
4984
4959
  self,
4985
4960
  call_control_id: str,
4986
4961
  *,
4987
- assistant: action_start_ai_assistant_params.Assistant | NotGiven = NOT_GIVEN,
4988
- client_state: str | NotGiven = NOT_GIVEN,
4989
- command_id: str | NotGiven = NOT_GIVEN,
4990
- greeting: str | NotGiven = NOT_GIVEN,
4991
- interruption_settings: InterruptionSettingsParam | NotGiven = NOT_GIVEN,
4992
- transcription: TranscriptionConfigParam | NotGiven = NOT_GIVEN,
4993
- voice: str | NotGiven = NOT_GIVEN,
4994
- voice_settings: action_start_ai_assistant_params.VoiceSettings | NotGiven = NOT_GIVEN,
4962
+ assistant: action_start_ai_assistant_params.Assistant | Omit = omit,
4963
+ client_state: str | Omit = omit,
4964
+ command_id: str | Omit = omit,
4965
+ greeting: str | Omit = omit,
4966
+ interruption_settings: InterruptionSettingsParam | Omit = omit,
4967
+ transcription: TranscriptionConfigParam | Omit = omit,
4968
+ voice: str | Omit = omit,
4969
+ voice_settings: action_start_ai_assistant_params.VoiceSettings | Omit = omit,
4995
4970
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
4996
4971
  # The extra values given here take precedence over values defined on the client or passed to this method.
4997
4972
  extra_headers: Headers | None = None,
4998
4973
  extra_query: Query | None = None,
4999
4974
  extra_body: Body | None = None,
5000
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
4975
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5001
4976
  ) -> ActionStartAIAssistantResponse:
5002
4977
  """
5003
4978
  Start an AI assistant on the call.
5004
4979
 
5005
- **Expected Webhooks (see
5006
- [callback schema](https://developers.telnyx.com/api/call-control/call-start-ai-assistant#callbacks)
5007
- below):**
4980
+ **Expected Webhooks:**
5008
4981
 
5009
4982
  - `call.conversation.ended`
5010
4983
  - `call.conversation_insights.generated`
@@ -5089,17 +5062,17 @@ class AsyncActionsResource(AsyncAPIResource):
5089
5062
  self,
5090
5063
  call_control_id: str,
5091
5064
  *,
5092
- client_state: str | NotGiven = NOT_GIVEN,
5093
- command_id: str | NotGiven = NOT_GIVEN,
5094
- rx: str | NotGiven = NOT_GIVEN,
5095
- stream_type: Literal["decrypted"] | NotGiven = NOT_GIVEN,
5096
- tx: str | NotGiven = NOT_GIVEN,
5065
+ client_state: str | Omit = omit,
5066
+ command_id: str | Omit = omit,
5067
+ rx: str | Omit = omit,
5068
+ stream_type: Literal["decrypted"] | Omit = omit,
5069
+ tx: str | Omit = omit,
5097
5070
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5098
5071
  # The extra values given here take precedence over values defined on the client or passed to this method.
5099
5072
  extra_headers: Headers | None = None,
5100
5073
  extra_query: Query | None = None,
5101
5074
  extra_body: Body | None = None,
5102
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5075
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5103
5076
  ) -> ActionStartForkingResponse:
5104
5077
  """
5105
5078
  Call forking allows you to stream the media from a call to a specific target in
@@ -5108,9 +5081,7 @@ class AsyncActionsResource(AsyncAPIResource):
5108
5081
  audio responses. Requests must specify either the `target` attribute or the `rx`
5109
5082
  and `tx` attributes.
5110
5083
 
5111
- **Expected Webhooks (see
5112
- [callback schema](https://developers.telnyx.com/api/call-control/start-call-fork#callbacks)
5113
- below):**
5084
+ **Expected Webhooks:**
5114
5085
 
5115
5086
  - `call.fork.started`
5116
5087
  - `call.fork.stopped`
@@ -5164,16 +5135,16 @@ class AsyncActionsResource(AsyncAPIResource):
5164
5135
  self,
5165
5136
  call_control_id: str,
5166
5137
  *,
5167
- client_state: str | NotGiven = NOT_GIVEN,
5168
- command_id: str | NotGiven = NOT_GIVEN,
5169
- direction: Literal["inbound", "outbound", "both"] | NotGiven = NOT_GIVEN,
5170
- noise_suppression_engine: Literal["A", "B"] | NotGiven = NOT_GIVEN,
5138
+ client_state: str | Omit = omit,
5139
+ command_id: str | Omit = omit,
5140
+ direction: Literal["inbound", "outbound", "both"] | Omit = omit,
5141
+ noise_suppression_engine: Literal["A", "B"] | Omit = omit,
5171
5142
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5172
5143
  # The extra values given here take precedence over values defined on the client or passed to this method.
5173
5144
  extra_headers: Headers | None = None,
5174
5145
  extra_query: Query | None = None,
5175
5146
  extra_body: Body | None = None,
5176
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5147
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5177
5148
  ) -> ActionStartNoiseSuppressionResponse:
5178
5149
  """
5179
5150
  Noise Suppression Start (BETA)
@@ -5221,23 +5192,23 @@ class AsyncActionsResource(AsyncAPIResource):
5221
5192
  self,
5222
5193
  call_control_id: str,
5223
5194
  *,
5224
- audio_type: Literal["mp3", "wav"] | NotGiven = NOT_GIVEN,
5225
- audio_url: str | NotGiven = NOT_GIVEN,
5226
- cache_audio: bool | NotGiven = NOT_GIVEN,
5227
- client_state: str | NotGiven = NOT_GIVEN,
5228
- command_id: str | NotGiven = NOT_GIVEN,
5229
- loop: LoopcountParam | NotGiven = NOT_GIVEN,
5230
- media_name: str | NotGiven = NOT_GIVEN,
5231
- overlay: bool | NotGiven = NOT_GIVEN,
5232
- playback_content: str | NotGiven = NOT_GIVEN,
5233
- stop: str | NotGiven = NOT_GIVEN,
5234
- target_legs: str | NotGiven = NOT_GIVEN,
5195
+ audio_type: Literal["mp3", "wav"] | Omit = omit,
5196
+ audio_url: str | Omit = omit,
5197
+ cache_audio: bool | Omit = omit,
5198
+ client_state: str | Omit = omit,
5199
+ command_id: str | Omit = omit,
5200
+ loop: LoopcountParam | Omit = omit,
5201
+ media_name: str | Omit = omit,
5202
+ overlay: bool | Omit = omit,
5203
+ playback_content: str | Omit = omit,
5204
+ stop: str | Omit = omit,
5205
+ target_legs: str | Omit = omit,
5235
5206
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5236
5207
  # The extra values given here take precedence over values defined on the client or passed to this method.
5237
5208
  extra_headers: Headers | None = None,
5238
5209
  extra_query: Query | None = None,
5239
5210
  extra_body: Body | None = None,
5240
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5211
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5241
5212
  ) -> ActionStartPlaybackResponse:
5242
5213
  """Play an audio file on the call.
5243
5214
 
@@ -5250,9 +5221,7 @@ class AsyncActionsResource(AsyncAPIResource):
5250
5221
  - A customer cannot Play Audio with `overlay=true` unless there is a Play Audio
5251
5222
  with `overlay=false` actively playing.
5252
5223
 
5253
- **Expected Webhooks (see
5254
- [callback schema](https://developers.telnyx.com/api/call-control/start-call-playback#callbacks)
5255
- below):**
5224
+ **Expected Webhooks:**
5256
5225
 
5257
5226
  - `call.playback.started`
5258
5227
  - `call.playback.ended`
@@ -5337,15 +5306,15 @@ class AsyncActionsResource(AsyncAPIResource):
5337
5306
  *,
5338
5307
  channels: Literal["single", "dual"],
5339
5308
  format: Literal["wav", "mp3"],
5340
- client_state: str | NotGiven = NOT_GIVEN,
5341
- command_id: str | NotGiven = NOT_GIVEN,
5342
- custom_file_name: str | NotGiven = NOT_GIVEN,
5343
- max_length: int | NotGiven = NOT_GIVEN,
5344
- play_beep: bool | NotGiven = NOT_GIVEN,
5345
- recording_track: Literal["both", "inbound", "outbound"] | NotGiven = NOT_GIVEN,
5346
- timeout_secs: int | NotGiven = NOT_GIVEN,
5347
- transcription: bool | NotGiven = NOT_GIVEN,
5348
- transcription_engine: str | NotGiven = NOT_GIVEN,
5309
+ client_state: str | Omit = omit,
5310
+ command_id: str | Omit = omit,
5311
+ custom_file_name: str | Omit = omit,
5312
+ max_length: int | Omit = omit,
5313
+ play_beep: bool | Omit = omit,
5314
+ recording_track: Literal["both", "inbound", "outbound"] | Omit = omit,
5315
+ timeout_secs: int | Omit = omit,
5316
+ transcription: bool | Omit = omit,
5317
+ transcription_engine: str | Omit = omit,
5349
5318
  transcription_language: Literal[
5350
5319
  "af-ZA",
5351
5320
  "am-ET",
@@ -5493,27 +5462,25 @@ class AsyncActionsResource(AsyncAPIResource):
5493
5462
  "zh-TW",
5494
5463
  "zu-ZA",
5495
5464
  ]
5496
- | NotGiven = NOT_GIVEN,
5497
- transcription_max_speaker_count: int | NotGiven = NOT_GIVEN,
5498
- transcription_min_speaker_count: int | NotGiven = NOT_GIVEN,
5499
- transcription_profanity_filter: bool | NotGiven = NOT_GIVEN,
5500
- transcription_speaker_diarization: bool | NotGiven = NOT_GIVEN,
5501
- trim: Literal["trim-silence"] | NotGiven = NOT_GIVEN,
5465
+ | Omit = omit,
5466
+ transcription_max_speaker_count: int | Omit = omit,
5467
+ transcription_min_speaker_count: int | Omit = omit,
5468
+ transcription_profanity_filter: bool | Omit = omit,
5469
+ transcription_speaker_diarization: bool | Omit = omit,
5470
+ trim: Literal["trim-silence"] | Omit = omit,
5502
5471
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5503
5472
  # The extra values given here take precedence over values defined on the client or passed to this method.
5504
5473
  extra_headers: Headers | None = None,
5505
5474
  extra_query: Query | None = None,
5506
5475
  extra_body: Body | None = None,
5507
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5476
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5508
5477
  ) -> ActionStartRecordingResponse:
5509
5478
  """Start recording the call.
5510
5479
 
5511
5480
  Recording will stop on call hang-up, or can be
5512
5481
  initiated via the Stop Recording command.
5513
5482
 
5514
- **Expected Webhooks (see
5515
- [callback schema](https://developers.telnyx.com/api/call-control/start-call-record#callbacks)
5516
- below):**
5483
+ **Expected Webhooks:**
5517
5484
 
5518
5485
  - `call.recording.saved`
5519
5486
  - `call.recording.transcription.saved`
@@ -5612,19 +5579,19 @@ class AsyncActionsResource(AsyncAPIResource):
5612
5579
  self,
5613
5580
  call_control_id: str,
5614
5581
  *,
5615
- client_state: str | NotGiven = NOT_GIVEN,
5616
- connector_name: str | NotGiven = NOT_GIVEN,
5617
- include_metadata_custom_headers: Literal[True, False] | NotGiven = NOT_GIVEN,
5618
- secure: Literal[True, False] | NotGiven = NOT_GIVEN,
5619
- session_timeout_secs: int | NotGiven = NOT_GIVEN,
5620
- sip_transport: Literal["udp", "tcp", "tls"] | NotGiven = NOT_GIVEN,
5621
- siprec_track: Literal["inbound_track", "outbound_track", "both_tracks"] | NotGiven = NOT_GIVEN,
5582
+ client_state: str | Omit = omit,
5583
+ connector_name: str | Omit = omit,
5584
+ include_metadata_custom_headers: Literal[True, False] | Omit = omit,
5585
+ secure: Literal[True, False] | Omit = omit,
5586
+ session_timeout_secs: int | Omit = omit,
5587
+ sip_transport: Literal["udp", "tcp", "tls"] | Omit = omit,
5588
+ siprec_track: Literal["inbound_track", "outbound_track", "both_tracks"] | Omit = omit,
5622
5589
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5623
5590
  # The extra values given here take precedence over values defined on the client or passed to this method.
5624
5591
  extra_headers: Headers | None = None,
5625
5592
  extra_query: Query | None = None,
5626
5593
  extra_body: Body | None = None,
5627
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5594
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5628
5595
  ) -> ActionStartSiprecResponse:
5629
5596
  """
5630
5597
  Start siprec session to configured in SIPREC connector SRS.
@@ -5690,22 +5657,23 @@ class AsyncActionsResource(AsyncAPIResource):
5690
5657
  self,
5691
5658
  call_control_id: str,
5692
5659
  *,
5693
- client_state: str | NotGiven = NOT_GIVEN,
5694
- command_id: str | NotGiven = NOT_GIVEN,
5695
- dialogflow_config: DialogflowConfigParam | NotGiven = NOT_GIVEN,
5696
- enable_dialogflow: bool | NotGiven = NOT_GIVEN,
5697
- stream_bidirectional_codec: StreamBidirectionalCodec | NotGiven = NOT_GIVEN,
5698
- stream_bidirectional_mode: StreamBidirectionalMode | NotGiven = NOT_GIVEN,
5699
- stream_bidirectional_target_legs: StreamBidirectionalTargetLegs | NotGiven = NOT_GIVEN,
5700
- stream_codec: StreamCodec | NotGiven = NOT_GIVEN,
5701
- stream_track: Literal["inbound_track", "outbound_track", "both_tracks"] | NotGiven = NOT_GIVEN,
5702
- stream_url: str | NotGiven = NOT_GIVEN,
5660
+ client_state: str | Omit = omit,
5661
+ command_id: str | Omit = omit,
5662
+ dialogflow_config: DialogflowConfigParam | Omit = omit,
5663
+ enable_dialogflow: bool | Omit = omit,
5664
+ stream_bidirectional_codec: StreamBidirectionalCodec | Omit = omit,
5665
+ stream_bidirectional_mode: StreamBidirectionalMode | Omit = omit,
5666
+ stream_bidirectional_sampling_rate: Literal[8000, 16000, 22050, 24000, 48000] | Omit = omit,
5667
+ stream_bidirectional_target_legs: StreamBidirectionalTargetLegs | Omit = omit,
5668
+ stream_codec: StreamCodec | Omit = omit,
5669
+ stream_track: Literal["inbound_track", "outbound_track", "both_tracks"] | Omit = omit,
5670
+ stream_url: str | Omit = omit,
5703
5671
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5704
5672
  # The extra values given here take precedence over values defined on the client or passed to this method.
5705
5673
  extra_headers: Headers | None = None,
5706
5674
  extra_query: Query | None = None,
5707
5675
  extra_body: Body | None = None,
5708
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5676
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5709
5677
  ) -> ActionStartStreamingResponse:
5710
5678
  """
5711
5679
  Start streaming the media from a call to a specific WebSocket address or
@@ -5729,11 +5697,12 @@ class AsyncActionsResource(AsyncAPIResource):
5729
5697
 
5730
5698
  stream_bidirectional_mode: Configures method of bidirectional streaming (mp3, rtp).
5731
5699
 
5700
+ stream_bidirectional_sampling_rate: Audio sampling rate.
5701
+
5732
5702
  stream_bidirectional_target_legs: Specifies which call legs should receive the bidirectional stream audio.
5733
5703
 
5734
5704
  stream_codec: Specifies the codec to be used for the streamed audio. When set to 'default' or
5735
5705
  when transcoding is not possible, the codec from the call will be used.
5736
- Currently, transcoding is only supported between PCMU and PCMA codecs.
5737
5706
 
5738
5707
  stream_track: Specifies which track should be streamed.
5739
5708
 
@@ -5759,6 +5728,7 @@ class AsyncActionsResource(AsyncAPIResource):
5759
5728
  "enable_dialogflow": enable_dialogflow,
5760
5729
  "stream_bidirectional_codec": stream_bidirectional_codec,
5761
5730
  "stream_bidirectional_mode": stream_bidirectional_mode,
5731
+ "stream_bidirectional_sampling_rate": stream_bidirectional_sampling_rate,
5762
5732
  "stream_bidirectional_target_legs": stream_bidirectional_target_legs,
5763
5733
  "stream_codec": stream_codec,
5764
5734
  "stream_track": stream_track,
@@ -5776,26 +5746,24 @@ class AsyncActionsResource(AsyncAPIResource):
5776
5746
  self,
5777
5747
  call_control_id: str,
5778
5748
  *,
5779
- client_state: str | NotGiven = NOT_GIVEN,
5780
- command_id: str | NotGiven = NOT_GIVEN,
5781
- transcription_engine: Literal["A", "B"] | NotGiven = NOT_GIVEN,
5782
- transcription_engine_config: action_start_transcription_params.TranscriptionEngineConfig | NotGiven = NOT_GIVEN,
5783
- transcription_tracks: str | NotGiven = NOT_GIVEN,
5749
+ client_state: str | Omit = omit,
5750
+ command_id: str | Omit = omit,
5751
+ transcription_engine: Literal["A", "B"] | Omit = omit,
5752
+ transcription_engine_config: action_start_transcription_params.TranscriptionEngineConfig | Omit = omit,
5753
+ transcription_tracks: str | Omit = omit,
5784
5754
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5785
5755
  # The extra values given here take precedence over values defined on the client or passed to this method.
5786
5756
  extra_headers: Headers | None = None,
5787
5757
  extra_query: Query | None = None,
5788
5758
  extra_body: Body | None = None,
5789
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5759
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5790
5760
  ) -> ActionStartTranscriptionResponse:
5791
5761
  """Start real-time transcription.
5792
5762
 
5793
5763
  Transcription will stop on call hang-up, or can
5794
5764
  be initiated via the Transcription stop command.
5795
5765
 
5796
- **Expected Webhooks (see
5797
- [callback schema](https://developers.telnyx.com/api/call-control/start-call-transcription#callbacks)
5798
- below):**
5766
+ **Expected Webhooks:**
5799
5767
 
5800
5768
  - `call.transcription`
5801
5769
 
@@ -5844,14 +5812,14 @@ class AsyncActionsResource(AsyncAPIResource):
5844
5812
  self,
5845
5813
  call_control_id: str,
5846
5814
  *,
5847
- client_state: str | NotGiven = NOT_GIVEN,
5848
- command_id: str | NotGiven = NOT_GIVEN,
5815
+ client_state: str | Omit = omit,
5816
+ command_id: str | Omit = omit,
5849
5817
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5850
5818
  # The extra values given here take precedence over values defined on the client or passed to this method.
5851
5819
  extra_headers: Headers | None = None,
5852
5820
  extra_query: Query | None = None,
5853
5821
  extra_body: Body | None = None,
5854
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5822
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5855
5823
  ) -> ActionStopAIAssistantResponse:
5856
5824
  """
5857
5825
  Stop an AI assistant on the call.
@@ -5892,22 +5860,20 @@ class AsyncActionsResource(AsyncAPIResource):
5892
5860
  self,
5893
5861
  call_control_id: str,
5894
5862
  *,
5895
- client_state: str | NotGiven = NOT_GIVEN,
5896
- command_id: str | NotGiven = NOT_GIVEN,
5897
- stream_type: Literal["raw", "decrypted"] | NotGiven = NOT_GIVEN,
5863
+ client_state: str | Omit = omit,
5864
+ command_id: str | Omit = omit,
5865
+ stream_type: Literal["raw", "decrypted"] | Omit = omit,
5898
5866
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5899
5867
  # The extra values given here take precedence over values defined on the client or passed to this method.
5900
5868
  extra_headers: Headers | None = None,
5901
5869
  extra_query: Query | None = None,
5902
5870
  extra_body: Body | None = None,
5903
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5871
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5904
5872
  ) -> ActionStopForkingResponse:
5905
5873
  """
5906
5874
  Stop forking a call.
5907
5875
 
5908
- **Expected Webhooks (see
5909
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-fork#callbacks)
5910
- below):**
5876
+ **Expected Webhooks:**
5911
5877
 
5912
5878
  - `call.fork.stopped`
5913
5879
 
@@ -5951,21 +5917,19 @@ class AsyncActionsResource(AsyncAPIResource):
5951
5917
  self,
5952
5918
  call_control_id: str,
5953
5919
  *,
5954
- client_state: str | NotGiven = NOT_GIVEN,
5955
- command_id: str | NotGiven = NOT_GIVEN,
5920
+ client_state: str | Omit = omit,
5921
+ command_id: str | Omit = omit,
5956
5922
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
5957
5923
  # The extra values given here take precedence over values defined on the client or passed to this method.
5958
5924
  extra_headers: Headers | None = None,
5959
5925
  extra_query: Query | None = None,
5960
5926
  extra_body: Body | None = None,
5961
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5927
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
5962
5928
  ) -> ActionStopGatherResponse:
5963
5929
  """
5964
5930
  Stop current gather.
5965
5931
 
5966
- **Expected Webhooks (see
5967
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-gather#callbacks)
5968
- below):**
5932
+ **Expected Webhooks:**
5969
5933
 
5970
5934
  - `call.gather.ended`
5971
5935
 
@@ -6005,14 +5969,14 @@ class AsyncActionsResource(AsyncAPIResource):
6005
5969
  self,
6006
5970
  call_control_id: str,
6007
5971
  *,
6008
- client_state: str | NotGiven = NOT_GIVEN,
6009
- command_id: str | NotGiven = NOT_GIVEN,
5972
+ client_state: str | Omit = omit,
5973
+ command_id: str | Omit = omit,
6010
5974
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
6011
5975
  # The extra values given here take precedence over values defined on the client or passed to this method.
6012
5976
  extra_headers: Headers | None = None,
6013
5977
  extra_query: Query | None = None,
6014
5978
  extra_body: Body | None = None,
6015
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
5979
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6016
5980
  ) -> ActionStopNoiseSuppressionResponse:
6017
5981
  """
6018
5982
  Noise Suppression Stop (BETA)
@@ -6053,23 +6017,21 @@ class AsyncActionsResource(AsyncAPIResource):
6053
6017
  self,
6054
6018
  call_control_id: str,
6055
6019
  *,
6056
- client_state: str | NotGiven = NOT_GIVEN,
6057
- command_id: str | NotGiven = NOT_GIVEN,
6058
- overlay: bool | NotGiven = NOT_GIVEN,
6059
- stop: str | NotGiven = NOT_GIVEN,
6020
+ client_state: str | Omit = omit,
6021
+ command_id: str | Omit = omit,
6022
+ overlay: bool | Omit = omit,
6023
+ stop: str | Omit = omit,
6060
6024
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
6061
6025
  # The extra values given here take precedence over values defined on the client or passed to this method.
6062
6026
  extra_headers: Headers | None = None,
6063
6027
  extra_query: Query | None = None,
6064
6028
  extra_body: Body | None = None,
6065
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
6029
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6066
6030
  ) -> ActionStopPlaybackResponse:
6067
6031
  """
6068
6032
  Stop audio being played on the call.
6069
6033
 
6070
- **Expected Webhooks (see
6071
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-playback#callbacks)
6072
- below):**
6034
+ **Expected Webhooks:**
6073
6035
 
6074
6036
  - `call.playback.ended` or `call.speak.ended`
6075
6037
 
@@ -6116,22 +6078,20 @@ class AsyncActionsResource(AsyncAPIResource):
6116
6078
  self,
6117
6079
  call_control_id: str,
6118
6080
  *,
6119
- client_state: str | NotGiven = NOT_GIVEN,
6120
- command_id: str | NotGiven = NOT_GIVEN,
6121
- recording_id: str | NotGiven = NOT_GIVEN,
6081
+ client_state: str | Omit = omit,
6082
+ command_id: str | Omit = omit,
6083
+ recording_id: str | Omit = omit,
6122
6084
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
6123
6085
  # The extra values given here take precedence over values defined on the client or passed to this method.
6124
6086
  extra_headers: Headers | None = None,
6125
6087
  extra_query: Query | None = None,
6126
6088
  extra_body: Body | None = None,
6127
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
6089
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6128
6090
  ) -> ActionStopRecordingResponse:
6129
6091
  """
6130
6092
  Stop recording the call.
6131
6093
 
6132
- **Expected Webhooks (see
6133
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-recording#callbacks)
6134
- below):**
6094
+ **Expected Webhooks:**
6135
6095
 
6136
6096
  - `call.recording.saved`
6137
6097
 
@@ -6174,14 +6134,14 @@ class AsyncActionsResource(AsyncAPIResource):
6174
6134
  self,
6175
6135
  call_control_id: str,
6176
6136
  *,
6177
- client_state: str | NotGiven = NOT_GIVEN,
6178
- command_id: str | NotGiven = NOT_GIVEN,
6137
+ client_state: str | Omit = omit,
6138
+ command_id: str | Omit = omit,
6179
6139
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
6180
6140
  # The extra values given here take precedence over values defined on the client or passed to this method.
6181
6141
  extra_headers: Headers | None = None,
6182
6142
  extra_query: Query | None = None,
6183
6143
  extra_body: Body | None = None,
6184
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
6144
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6185
6145
  ) -> ActionStopSiprecResponse:
6186
6146
  """
6187
6147
  Stop SIPREC session.
@@ -6226,22 +6186,20 @@ class AsyncActionsResource(AsyncAPIResource):
6226
6186
  self,
6227
6187
  call_control_id: str,
6228
6188
  *,
6229
- client_state: str | NotGiven = NOT_GIVEN,
6230
- command_id: str | NotGiven = NOT_GIVEN,
6231
- stream_id: str | NotGiven = NOT_GIVEN,
6189
+ client_state: str | Omit = omit,
6190
+ command_id: str | Omit = omit,
6191
+ stream_id: str | Omit = omit,
6232
6192
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
6233
6193
  # The extra values given here take precedence over values defined on the client or passed to this method.
6234
6194
  extra_headers: Headers | None = None,
6235
6195
  extra_query: Query | None = None,
6236
6196
  extra_body: Body | None = None,
6237
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
6197
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6238
6198
  ) -> ActionStopStreamingResponse:
6239
6199
  """
6240
6200
  Stop streaming a call to a WebSocket.
6241
6201
 
6242
- **Expected Webhooks (see
6243
- [callback schema](https://developers.telnyx.com/api/call-control/stop-call-streaming#callbacks)
6244
- below):**
6202
+ **Expected Webhooks:**
6245
6203
 
6246
6204
  - `streaming.stopped`
6247
6205
 
@@ -6285,14 +6243,14 @@ class AsyncActionsResource(AsyncAPIResource):
6285
6243
  self,
6286
6244
  call_control_id: str,
6287
6245
  *,
6288
- client_state: str | NotGiven = NOT_GIVEN,
6289
- command_id: str | NotGiven = NOT_GIVEN,
6246
+ client_state: str | Omit = omit,
6247
+ command_id: str | Omit = omit,
6290
6248
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
6291
6249
  # The extra values given here take precedence over values defined on the client or passed to this method.
6292
6250
  extra_headers: Headers | None = None,
6293
6251
  extra_query: Query | None = None,
6294
6252
  extra_body: Body | None = None,
6295
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
6253
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6296
6254
  ) -> ActionStopTranscriptionResponse:
6297
6255
  """
6298
6256
  Stop real-time transcription.
@@ -6339,7 +6297,7 @@ class AsyncActionsResource(AsyncAPIResource):
6339
6297
  extra_headers: Headers | None = None,
6340
6298
  extra_query: Query | None = None,
6341
6299
  extra_body: Body | None = None,
6342
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
6300
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6343
6301
  ) -> ActionSwitchSupervisorRoleResponse:
6344
6302
  """Switch the supervisor role for a bridged call.
6345
6303
 
@@ -6379,36 +6337,43 @@ class AsyncActionsResource(AsyncAPIResource):
6379
6337
  answering_machine_detection: Literal[
6380
6338
  "premium", "detect", "detect_beep", "detect_words", "greeting_end", "disabled"
6381
6339
  ]
6382
- | NotGiven = NOT_GIVEN,
6383
- answering_machine_detection_config: action_transfer_params.AnsweringMachineDetectionConfig
6384
- | NotGiven = NOT_GIVEN,
6385
- audio_url: str | NotGiven = NOT_GIVEN,
6386
- client_state: str | NotGiven = NOT_GIVEN,
6387
- command_id: str | NotGiven = NOT_GIVEN,
6388
- custom_headers: Iterable[CustomSipHeaderParam] | NotGiven = NOT_GIVEN,
6389
- early_media: bool | NotGiven = NOT_GIVEN,
6390
- from_: str | NotGiven = NOT_GIVEN,
6391
- from_display_name: str | NotGiven = NOT_GIVEN,
6392
- media_encryption: Literal["disabled", "SRTP", "DTLS"] | NotGiven = NOT_GIVEN,
6393
- media_name: str | NotGiven = NOT_GIVEN,
6394
- mute_dtmf: Literal["none", "both", "self", "opposite"] | NotGiven = NOT_GIVEN,
6395
- park_after_unbridge: str | NotGiven = NOT_GIVEN,
6396
- sip_auth_password: str | NotGiven = NOT_GIVEN,
6397
- sip_auth_username: str | NotGiven = NOT_GIVEN,
6398
- sip_headers: Iterable[SipHeaderParam] | NotGiven = NOT_GIVEN,
6399
- sip_transport_protocol: Literal["UDP", "TCP", "TLS"] | NotGiven = NOT_GIVEN,
6400
- sound_modifications: SoundModificationsParam | NotGiven = NOT_GIVEN,
6401
- target_leg_client_state: str | NotGiven = NOT_GIVEN,
6402
- time_limit_secs: int | NotGiven = NOT_GIVEN,
6403
- timeout_secs: int | NotGiven = NOT_GIVEN,
6404
- webhook_url: str | NotGiven = NOT_GIVEN,
6405
- webhook_url_method: Literal["POST", "GET"] | NotGiven = NOT_GIVEN,
6340
+ | Omit = omit,
6341
+ answering_machine_detection_config: action_transfer_params.AnsweringMachineDetectionConfig | Omit = omit,
6342
+ audio_url: str | Omit = omit,
6343
+ client_state: str | Omit = omit,
6344
+ command_id: str | Omit = omit,
6345
+ custom_headers: Iterable[CustomSipHeaderParam] | Omit = omit,
6346
+ early_media: bool | Omit = omit,
6347
+ from_: str | Omit = omit,
6348
+ from_display_name: str | Omit = omit,
6349
+ media_encryption: Literal["disabled", "SRTP", "DTLS"] | Omit = omit,
6350
+ media_name: str | Omit = omit,
6351
+ mute_dtmf: Literal["none", "both", "self", "opposite"] | Omit = omit,
6352
+ park_after_unbridge: str | Omit = omit,
6353
+ record: Literal["record-from-answer"] | Omit = omit,
6354
+ record_channels: Literal["single", "dual"] | Omit = omit,
6355
+ record_custom_file_name: str | Omit = omit,
6356
+ record_format: Literal["wav", "mp3"] | Omit = omit,
6357
+ record_max_length: int | Omit = omit,
6358
+ record_timeout_secs: int | Omit = omit,
6359
+ record_track: Literal["both", "inbound", "outbound"] | Omit = omit,
6360
+ record_trim: Literal["trim-silence"] | Omit = omit,
6361
+ sip_auth_password: str | Omit = omit,
6362
+ sip_auth_username: str | Omit = omit,
6363
+ sip_headers: Iterable[SipHeaderParam] | Omit = omit,
6364
+ sip_transport_protocol: Literal["UDP", "TCP", "TLS"] | Omit = omit,
6365
+ sound_modifications: SoundModificationsParam | Omit = omit,
6366
+ target_leg_client_state: str | Omit = omit,
6367
+ time_limit_secs: int | Omit = omit,
6368
+ timeout_secs: int | Omit = omit,
6369
+ webhook_url: str | Omit = omit,
6370
+ webhook_url_method: Literal["POST", "GET"] | Omit = omit,
6406
6371
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
6407
6372
  # The extra values given here take precedence over values defined on the client or passed to this method.
6408
6373
  extra_headers: Headers | None = None,
6409
6374
  extra_query: Query | None = None,
6410
6375
  extra_body: Body | None = None,
6411
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
6376
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6412
6377
  ) -> ActionTransferResponse:
6413
6378
  """Transfer a call to a new destination.
6414
6379
 
@@ -6418,9 +6383,7 @@ class AsyncActionsResource(AsyncAPIResource):
6418
6383
  may be issued additional commands, potentially transfering the call to an
6419
6384
  alternate destination.
6420
6385
 
6421
- **Expected Webhooks (see
6422
- [callback schema](https://developers.telnyx.com/api/call-control/transfer-call#callbacks)
6423
- below):**
6386
+ **Expected Webhooks:**
6424
6387
 
6425
6388
  - `call.initiated`
6426
6389
  - `call.bridged` to Leg B
@@ -6485,6 +6448,33 @@ class AsyncActionsResource(AsyncAPIResource):
6485
6448
  or is transferred). If supplied with the value `self`, the current leg will be
6486
6449
  parked after unbridge. If not set, the default behavior is to hang up the leg.
6487
6450
 
6451
+ record: Start recording automatically after an event. Disabled by default.
6452
+
6453
+ record_channels: Defines which channel should be recorded ('single' or 'dual') when `record` is
6454
+ specified.
6455
+
6456
+ record_custom_file_name: The custom recording file name to be used instead of the default `call_leg_id`.
6457
+ Telnyx will still add a Unix timestamp suffix.
6458
+
6459
+ record_format: Defines the format of the recording ('wav' or 'mp3') when `record` is specified.
6460
+
6461
+ record_max_length: Defines the maximum length for the recording in seconds when `record` is
6462
+ specified. The minimum value is 0. The maximum value is 43200. The default value
6463
+ is 0 (infinite).
6464
+
6465
+ record_timeout_secs: The number of seconds that Telnyx will wait for the recording to be stopped if
6466
+ silence is detected when `record` is specified. The timer only starts when the
6467
+ speech is detected. Please note that call transcription is used to detect
6468
+ silence and the related charge will be applied. The minimum value is 0. The
6469
+ default value is 0 (infinite).
6470
+
6471
+ record_track: The audio track to be recorded. Can be either `both`, `inbound` or `outbound`.
6472
+ If only single track is specified (`inbound`, `outbound`), `channels`
6473
+ configuration is ignored and it will be recorded as mono (single channel).
6474
+
6475
+ record_trim: When set to `trim-silence`, silence will be removed from the beginning and end
6476
+ of the recording.
6477
+
6488
6478
  sip_auth_password: SIP Authentication password used for SIP challenges.
6489
6479
 
6490
6480
  sip_auth_username: SIP Authentication username used for SIP challenges.
@@ -6545,6 +6535,14 @@ class AsyncActionsResource(AsyncAPIResource):
6545
6535
  "media_name": media_name,
6546
6536
  "mute_dtmf": mute_dtmf,
6547
6537
  "park_after_unbridge": park_after_unbridge,
6538
+ "record": record,
6539
+ "record_channels": record_channels,
6540
+ "record_custom_file_name": record_custom_file_name,
6541
+ "record_format": record_format,
6542
+ "record_max_length": record_max_length,
6543
+ "record_timeout_secs": record_timeout_secs,
6544
+ "record_track": record_track,
6545
+ "record_trim": record_trim,
6548
6546
  "sip_auth_password": sip_auth_password,
6549
6547
  "sip_auth_username": sip_auth_username,
6550
6548
  "sip_headers": sip_headers,
@@ -6574,7 +6572,7 @@ class AsyncActionsResource(AsyncAPIResource):
6574
6572
  extra_headers: Headers | None = None,
6575
6573
  extra_query: Query | None = None,
6576
6574
  extra_body: Body | None = None,
6577
- timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
6575
+ timeout: float | httpx.Timeout | None | NotGiven = not_given,
6578
6576
  ) -> ActionUpdateClientStateResponse:
6579
6577
  """
6580
6578
  Updates client state