Studio uses Widgets to represent various parts of Twilio's API that can then be stitched together in your Studio Flow to build out robust applications that require no coding on your part.
New to Twilio Studio? Check out our Getting Started guide!
The Call Recording Widget allows you to switch Voice Call Recording ON or OFF at any point during a call flow.
The Call Recording widget can only be used for Incoming Calls and must be placed after an initial Say/Play or Gather widget. Be sure to announce to the caller that the call is being recorded, if your local laws require it.
The Call Recording Widget requires specification on whether the Recording should be switched on or off.
Name | Description | Default |
---|---|---|
Record Call | A toggle button (Boolean) to allow users to Toggle Call Recording to On or Off within a Call Flow. | False |
These options are not for pausing and resuming a Video Recording — they are specifically meant for Start and Stop actions. Please read Legal Considerations with Recording Voice and Video Communications.
The Call Recording Widget also accepts a number of configuration options that you can use to declare recording Status Callback URL, Recording Channels, and trim behavior for the request initiated by this Widget.
Name | Description | Default |
---|---|---|
Recording Status Callback URL | The URL we should call using the recording_status_callback_method on each recording event specified in recording_status_callback_event. | empty |
Recording Status Callback Method | The HTTP method we should use to call recording_status_callback. Can be GET or POST | POST |
Recording Status Event | The recording status events on which we should call the recording_status_callback URL. Can be: in-progress, completed and absent. Separate multiple event values with space. | completed |
Recording Channels | The number of channels used in the recording. Can be: mono or dual. mono records all parties of the call into one channel. dual records each party of a 2-party call into separate channels. | dual |
Trim | Whether to trim any leading and trailing silence in the recording. Can be: trim-silence or do-not-trim. trim-silence trims the silence from the beginning and end of the recording and do-not-trim does not. | do-not-trim |
Learn more about RecordingStatusCallback parameters.
These events trigger transitions from this Widget to another Widget in your Flow. For more information on working with Studio transitions, see this guide.
Name | Description |
---|---|
Success | The call recording was successfully toggled. |
Failed | Could not toggle call recording. |
When the Call Recording Widget executes, it will have stored the following variables for use throughout your Studio Flow (where MY_WIDGET_NAME
is the name of your actual widget). For more information on working with variables in Studio, see this guide.
Find definitions and examples for these variables at the Recording page.
Name | Liquid Template Language |
---|---|
Account SID | {{widgets.MY_WIDGET_NAME.AccountSid}} |
API Version | {{widgets.MY_WIDGET_NAME.ApiVersion}} |
Call SID | {{widgets.MY_WIDGET_NAME.CallSid}} |
Channels | {{widgets.MY_WIDGET_NAME.Channels}} |
Conference SID | {{widgets.MY_WIDGET_NAME.ConferenceSid}} |
Date Created | {{widgets.MY_WIDGET_NAME.DateCreated}} |
Date Updated | {{widgets.MY_WIDGET_NAME.DateUpdated}} |
Duration | {{widgets.MY_WIDGET_NAME.Duration}} |
Encryption Details | {{widgets.MY_WIDGET_NAME.EncryptionDetails}} |
Error Code | {{widgets.MY_WIDGET_NAME.ErrorCode}} |
Price | {{widgets.MY_WIDGET_NAME.Price}} |
Price Unit | {{widgets.MY_WIDGET_NAME.PriceUnit}} |
Recording SID | {{widgets.MY_WIDGET_NAME.Sid}} |
Recording Uri | {{widgets.MY_WIDGET_NAME.Uri}} |
Source of Recording Start | {{widgets.MY_WIDGET_NAME.Source}} |
Start Time | {{widgets.MY_WIDGET_NAME.StartTime}} |
Status | {{widgets.MY_WIDGET_NAME.Status}} |
In this Flow, a client will be notified that their call will be recorded. The call recording will then proceed and, if successful, will ask the client what their experience was like. After the client stops talking, the recording will be stopped. The specified Recording Status Callback URL for the Widget will handle all events of the recording.
Now that you know the basics of the Call Recording Widget, you may want to learn more about Recordings:
We can't wait to see what you build!