Class: Telnyx::Resources::Texml::Accounts::Calls::RecordingsJson

Inherits:
Object
  • Object
show all
Defined in:
lib/telnyx/resources/texml/accounts/calls/recordings_json.rb

Overview

TeXML REST Commands

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ RecordingsJson

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of RecordingsJson.

Parameters:



88
89
90
# File 'lib/telnyx/resources/texml/accounts/calls/recordings_json.rb', line 88

def initialize(client:)
  @client = client
end

Instance Method Details

#recordings_json(call_sid, account_sid:, play_beep: nil, recording_channels: nil, recording_status_callback: nil, recording_status_callback_event: nil, recording_status_callback_method: nil, recording_track: nil, send_recording_url: nil, request_options: {}) ⇒ Telnyx::Models::Texml::Accounts::Calls::RecordingsJsonRecordingsJsonResponse

Some parameter documentations has been truncated, see Models::Texml::Accounts::Calls::RecordingsJsonRecordingsJsonParams for more details.

Starts recording with specified parameters for call idientified by call_sid.

Parameters:

Returns:

See Also:



41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# File 'lib/telnyx/resources/texml/accounts/calls/recordings_json.rb', line 41

def recordings_json(call_sid, params)
  parsed, options = Telnyx::Texml::Accounts::Calls::RecordingsJsonRecordingsJsonParams.dump_request(params)
   =
    parsed.delete(:account_sid) do
      raise ArgumentError.new("missing required path argument #{_1}")
    end
  @client.request(
    method: :post,
    path: ["texml/Accounts/%1$s/Calls/%2$s/Recordings.json", , call_sid],
    headers: {"content-type" => "application/x-www-form-urlencoded"},
    body: parsed,
    model: Telnyx::Models::Texml::Accounts::Calls::RecordingsJsonRecordingsJsonResponse,
    options: options
  )
end

#retrieve_recordings_json(call_sid, account_sid:, request_options: {}) ⇒ Telnyx::Models::Texml::Accounts::Calls::RecordingsJsonRetrieveRecordingsJsonResponse

Returns recordings for a call identified by call_sid.

Parameters:

  • call_sid (String)

    The CallSid that identifies the call to update.

  • account_sid (String)

    The id of the account the resource belongs to.

  • request_options (Telnyx::RequestOptions, Hash{Symbol=>Object}, nil)

Returns:

See Also:



70
71
72
73
74
75
76
77
78
79
80
81
82
83
# File 'lib/telnyx/resources/texml/accounts/calls/recordings_json.rb', line 70

def retrieve_recordings_json(call_sid, params)
  parsed, options =
    Telnyx::Texml::Accounts::Calls::RecordingsJsonRetrieveRecordingsJsonParams.dump_request(params)
   =
    parsed.delete(:account_sid) do
      raise ArgumentError.new("missing required path argument #{_1}")
    end
  @client.request(
    method: :get,
    path: ["texml/Accounts/%1$s/Calls/%2$s/Recordings.json", , call_sid],
    model: Telnyx::Models::Texml::Accounts::Calls::RecordingsJsonRetrieveRecordingsJsonResponse,
    options: options
  )
end