Class: Telnyx::Models::Calls::ActionStartPlaybackParams
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Telnyx::Models::Calls::ActionStartPlaybackParams
- Extended by:
- Internal::Type::RequestParameters::Converter
- Includes:
- Internal::Type::RequestParameters
- Defined in:
- lib/telnyx/models/calls/action_start_playback_params.rb
Overview
Defined Under Namespace
Modules: AudioType
Instance Attribute Summary collapse
-
#audio_type ⇒ Symbol, ...
Specifies the type of audio provided in ‘audio_url` or `playback_content`.
-
#audio_url ⇒ String?
The URL of a file to be played back on the call.
-
#cache_audio ⇒ Boolean?
Caches the audio file.
- #call_control_id ⇒ String
-
#client_state ⇒ String?
Use this field to add state to every subsequent webhook.
-
#command_id ⇒ String?
Use this field to avoid duplicate commands.
-
#loop_ ⇒ String, ...
The number of times the audio file should be played.
-
#media_name ⇒ String?
The media_name of a file to be played back on the call.
-
#overlay ⇒ Boolean?
When enabled, audio will be mixed on top of any other audio that is actively being played back.
-
#playback_content ⇒ String?
Allows a user to provide base64 encoded mp3 or wav.
-
#stop ⇒ String?
When specified, it stops the current audio being played.
-
#target_legs ⇒ String?
Specifies the leg or legs on which audio will be played.
Attributes included from Internal::Type::RequestParameters
Instance Method Summary collapse
-
#initialize(call_control_id:, audio_type: nil, audio_url: nil, cache_audio: nil, client_state: nil, command_id: nil, loop_: nil, media_name: nil, overlay: nil, playback_content: nil, stop: nil, target_legs: nil, request_options: {}) ⇒ Object
constructor
Some parameter documentations has been truncated, see ActionStartPlaybackParams for more details.
Methods included from Internal::Type::RequestParameters::Converter
Methods included from Internal::Type::RequestParameters
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(call_control_id:, audio_type: nil, audio_url: nil, cache_audio: nil, client_state: nil, command_id: nil, loop_: nil, media_name: nil, overlay: nil, playback_content: nil, stop: nil, target_legs: nil, request_options: {}) ⇒ Object
Some parameter documentations has been truncated, see Telnyx::Models::Calls::ActionStartPlaybackParams for more details.
|
|
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 99
|
Instance Attribute Details
#audio_type ⇒ Symbol, ...
Specifies the type of audio provided in ‘audio_url` or `playback_content`.
20 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 20 optional :audio_type, enum: -> { Telnyx::Calls::ActionStartPlaybackParams::AudioType } |
#audio_url ⇒ String?
The URL of a file to be played back on the call. The URL can point to either a WAV or MP3 file. media_name and audio_url cannot be used together in one request.
28 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 28 optional :audio_url, String |
#cache_audio ⇒ Boolean?
Caches the audio file. Useful when playing the same audio file multiple times during the call.
35 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 35 optional :cache_audio, Telnyx::Internal::Type::Boolean |
#call_control_id ⇒ String
14 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 14 required :call_control_id, String |
#client_state ⇒ String?
Use this field to add state to every subsequent webhook. It must be a valid Base-64 encoded string.
42 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 42 optional :client_state, String |
#command_id ⇒ String?
Use this field to avoid duplicate commands. Telnyx will ignore any command with the same ‘command_id` for the same `call_control_id`.
49 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 49 optional :command_id, String |
#loop_ ⇒ String, ...
The number of times the audio file should be played. If supplied, the value must be an integer between 1 and 100, or the special string ‘infinity` for an endless loop.
57 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 57 optional :loop_, union: -> { Telnyx::Calls::Loopcount }, api_name: :loop |
#media_name ⇒ String?
The media_name of a file to be played back on the call. The media_name must point to a file previously uploaded to api.telnyx.com/v2/media by the same user/organization. The file must either be a WAV or MP3 file.
65 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 65 optional :media_name, String |
#overlay ⇒ Boolean?
When enabled, audio will be mixed on top of any other audio that is actively being played back. Note that ‘overlay: true` will only work if there is another audio file already being played on the call.
73 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 73 optional :overlay, Telnyx::Internal::Type::Boolean |
#playback_content ⇒ String?
Allows a user to provide base64 encoded mp3 or wav. Note: when using this parameter, ‘media_url` and `media_name` in the `playback_started` and `playback_ended` webhooks will be empty
81 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 81 optional :playback_content, String |
#stop ⇒ String?
When specified, it stops the current audio being played. Specify ‘current` to stop the current audio being played, and to play the next file in the queue. Specify `all` to stop the current audio file being played and to also clear all audio files from the queue.
90 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 90 optional :stop, String |
#target_legs ⇒ String?
Specifies the leg or legs on which audio will be played. If supplied, the value must be either ‘self`, `opposite` or `both`.
97 |
# File 'lib/telnyx/models/calls/action_start_playback_params.rb', line 97 optional :target_legs, String |