Skip to main content
POST
JavaScript

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

account_sid
string
required

The UUID of the Telnyx account that owns the resource, for example f5586561-8ff0-4291-a51b-c7dfe4139ff9. The account_sid path segment is kept for Twilio API compatibility, but the value is a Telnyx account UUID, not a Twilio AC... SID. It must match the account that owns the API key used to authenticate the request, otherwise the endpoint returns 404. The same value is sent as AccountSid in TeXML webhooks.

Example:

"f5586561-8ff0-4291-a51b-c7dfe4139ff9"

call_sid
string
required

The CallSid that identifies the call to update.

Body

application/x-www-form-urlencoded

Starts call recording on a call.

PlayBeep
boolean
default:true

Whether to play a beep when recording is started.

Example:

false

RecordingStatusCallbackEvent
string

The changes to the recording's state that should generate a call to RecoridngStatusCallback. Can be: in-progress, completed and absent. Separate multiple values with a space. Defaults to completed.

Example:

"in-progress completed absent"

RecordingStatusCallback
string<uri>

Url where status callbacks will be sent.

Example:

"http://webhook.com/callback"

RecordingStatusCallbackMethod
enum<string>
default:POST

HTTP method used to send status callbacks.

Available options:
GET,
POST
Example:

"GET"

RecordingChannels
enum<string>
default:dual

When dual, final audio file has the first leg on channel A, and the rest on channel B. single mixes both tracks into a single channel.

Available options:
single,
dual
Example:

"single"

RecordingTrack
enum<string>

The audio track to record for the call. The default is both.

Available options:
inbound,
outbound,
both
Example:

"inbound"

SendRecordingUrl
boolean
default:true

Whether to send RecordingUrl in webhooks.

Example:

false

Response

Successful call recording create response

account_sid
string
Example:

"61bf923e-5e4d-4595-a110-56190ea18a1b"

call_sid
string
Example:

"v3:KBnLO0ZK3DhKM5s7bE9VluaSmKsOchKht_fUYvxcp8ysbmzCCtpkmA"

conference_sid
string<uuid> | null
Example:

"cd5a70f4-759b-4d5e-9c06-88c00f16f3c1"

channels
enum<integer>
default:2
Available options:
1,
2
Example:

1

date_created
string<date-time>
Example:

"2023-08-11T19:12:11Z"

date_updated
string<date-time>
Example:

"2023-08-11T19:12:11Z"

start_time
string<date-time>
Example:

"2023-08-11T19:12:11Z"

price
string | null

The price of this recording, the currency is specified in the price_unit field.

Example:

"0.10"

price_unit
string | null

The unit in which the price is given.

Example:

"USD"

duration
string | null

The duration of this recording, given in seconds.

Example:

"12"

sid
string

Identifier of a resource.

Example:

"e9cea0be-7dbd-4b98-98b1-c0089d9d43b0"

source
enum<string>

Defines how the recording was created.

Available options:
StartCallRecordingAPI,
StartConferenceRecordingAPI,
OutboundAPI,
DialVerb,
Conference,
RecordVerb,
Trunking
error_code
string | null
Example:

null

track
enum<string>

The audio track to record for the call. The default is both.

Available options:
inbound,
outbound,
both
Example:

"inbound"

uri
string

The relative URI for this recording resource.

Example:

"/v2/texml/Accounts/61bf923e-5e4d-4595-a110-56190ea18a1b/Calls/v3:KBnLO0ZK3DhKM5s7bE9VluaSmKsOchKht_fUYvxcp8ysbmzCCtpkmA/Recordings/b08f0fa1-a32c-4218-b3b5-9cf78941ccac.json"