openapi: 3.0.1 info: title: Twilio - Accounts A2p Recordings API description: This is the public Twilio REST API. termsOfService: https://www.twilio.com/legal/tos contact: name: Twilio Support url: https://support.twilio.com email: support@twilio.com license: name: Apache 2.0 url: https://www.apache.org/licenses/LICENSE-2.0.html version: 1.52.0 servers: - url: https://accounts.twilio.com tags: - name: Recordings description: Manage video and audio recordings paths: /Rooms/{RoomSid}/Recordings: get: operationId: listRoomRecordings summary: Twilio List Room Recordings tags: - Recordings parameters: - $ref: '#/components/parameters/RoomSid' - name: Status in: query schema: type: string enum: - processing - completed - deleted - failed - name: PageSize in: query schema: type: integer minimum: 1 maximum: 100 responses: '200': description: List of recordings content: application/json: schema: $ref: '#/components/schemas/VideoRecordingList' /Recordings/{RecordingSid}: get: operationId: fetchRecording summary: Twilio Fetch a Recording tags: - Recordings parameters: - name: RecordingSid in: path required: true schema: type: string pattern: ^RT[0-9a-fA-F]{32}$ responses: '200': description: Recording details content: application/json: schema: $ref: '#/components/schemas/VideoRecording' '404': description: Recording not found delete: operationId: deleteRecording summary: Twilio Delete a Recording tags: - Recordings parameters: - name: RecordingSid in: path required: true schema: type: string pattern: ^RT[0-9a-fA-F]{32}$ responses: '204': description: Recording deleted '404': description: Recording not found /RecordingSettings/Default: get: operationId: fetchRecordingSettings summary: Twilio Fetch Recording Settings tags: - Recordings responses: '200': description: Recording settings content: application/json: schema: $ref: '#/components/schemas/RecordingSettings' post: operationId: createRecordingSettings summary: Twilio Create or Update Recording Settings description: Configure the AWS credentials and S3 bucket for storing recordings. tags: - Recordings requestBody: required: true content: application/x-www-form-urlencoded: schema: type: object required: - FriendlyName properties: FriendlyName: type: string AwsCredentialsSid: type: string AwsS3Url: type: string format: uri AwsStorageEnabled: type: boolean EncryptionKeySid: type: string EncryptionEnabled: type: boolean responses: '201': description: Recording settings created /Accounts/{AccountSid}/Calls/{CallSid}/Recordings.json: get: operationId: listCallRecordings summary: Twilio List Recordings for a Call description: Retrieve a list of recordings associated with a specific call. tags: - Recordings parameters: - $ref: '#/components/parameters/AccountSid' - $ref: '#/components/parameters/CallSid' responses: '200': description: List of recordings content: application/json: schema: $ref: '#/components/schemas/RecordingList' '401': description: Unauthorized post: operationId: createCallRecording summary: Twilio Start Recording a Call description: Start recording an in-progress call. tags: - Recordings parameters: - $ref: '#/components/parameters/AccountSid' - $ref: '#/components/parameters/CallSid' requestBody: content: application/x-www-form-urlencoded: schema: type: object properties: RecordingStatusCallback: type: string format: uri description: URL for recording status webhooks RecordingStatusCallbackMethod: type: string enum: - GET - POST RecordingChannels: type: string enum: - mono - dual description: Number of recording channels Trim: type: string enum: - trim-silence - do-not-trim responses: '201': description: Recording started content: application/json: schema: $ref: '#/components/schemas/Recording' '401': description: Unauthorized /Accounts/{AccountSid}/Recordings.json: get: operationId: listRecordings summary: Twilio List All Recordings description: Retrieve a list of all recordings associated with your account. tags: - Recordings parameters: - $ref: '#/components/parameters/AccountSid' - name: DateCreated in: query schema: type: string format: date - name: CallSid in: query schema: type: string pattern: ^CA[0-9a-fA-F]{32}$ - name: PageSize in: query schema: type: integer minimum: 1 maximum: 1000 responses: '200': description: List of recordings content: application/json: schema: $ref: '#/components/schemas/RecordingList' '401': description: Unauthorized /Accounts/{AccountSid}/Recordings/{RecordingSid}.json: get: operationId: fetchRecording summary: Twilio Fetch a Recording tags: - Recordings parameters: - $ref: '#/components/parameters/AccountSid' - $ref: '#/components/parameters/RecordingSid' responses: '200': description: Recording details content: application/json: schema: $ref: '#/components/schemas/Recording' '404': description: Recording not found delete: operationId: deleteRecording summary: Twilio Delete a Recording tags: - Recordings parameters: - $ref: '#/components/parameters/AccountSid' - $ref: '#/components/parameters/RecordingSid' responses: '204': description: Recording deleted '404': description: Recording not found /v1/Recordings/{Sid}: servers: - url: https://video.twilio.com description: Single-track, single-media recordings x-twilio: defaultOutputProperties: - sid - date_created - status - type - duration - codec pathType: instance dependentProperties: media: mapping: recording_sid: sid resource_url: /v1None get: description: Returns a single Recording resource identified by a Recording SID. tags: - Recordings parameters: - name: Sid in: path description: The SID of the Recording resource to fetch. schema: type: string minLength: 34 maxLength: 34 pattern: ^RT[0-9a-fA-F]{32}$ required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/video.v1.recording' description: OK security: - accountSid_authToken: [] operationId: FetchRecording x-maturity: - GA delete: description: Delete a Recording resource identified by a Recording SID. tags: - Recordings parameters: - name: Sid in: path description: The SID of the Recording resource to delete. schema: type: string minLength: 34 maxLength: 34 pattern: ^RT[0-9a-fA-F]{32}$ required: true responses: '204': description: The resource was deleted successfully. security: - accountSid_authToken: [] operationId: DeleteRecording x-maturity: - GA /v1/Recordings: servers: - url: https://video.twilio.com description: Single-track, single-media recordings x-twilio: defaultOutputProperties: - sid - date_created - status - type - duration - codec pathType: list dependentProperties: media: mapping: recording_sid: sid resource_url: /v1None get: description: List of all Track recordings. tags: - Recordings parameters: - name: Status in: query description: 'Read only the recordings that have this status. Can be: `processing`, `completed`, or `deleted`.' schema: type: string $ref: '#/components/schemas/recording_enum_status' - name: SourceSid in: query description: Read only the recordings that have this `source_sid`. schema: type: string minLength: 34 maxLength: 34 pattern: ^[a-zA-Z]{2}[0-9a-fA-F]{32}$ - name: GroupingSid in: query description: Read only recordings with this `grouping_sid`, which may include a `participant_sid` and/or a `room_sid`. schema: type: array items: type: string minLength: 34 maxLength: 34 pattern: ^[a-zA-Z]{2}[0-9a-fA-F]{32}$ - name: DateCreatedAfter in: query description: Read only recordings that started on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time with time zone. schema: type: string format: date-time - name: DateCreatedBefore in: query description: Read only recordings that started before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time with time zone, given as `YYYY-MM-DDThh:mm:ss+|-hh:mm` or `YYYY-MM-DDThh:mm:ssZ`. schema: type: string format: date-time - name: MediaType in: query description: Read only recordings that have this media type. Can be either `audio` or `video`. schema: type: string $ref: '#/components/schemas/recording_enum_type' - name: PageSize in: query description: How many resources to return in each list page. The default is 50, and the maximum is 1000. schema: type: integer minimum: 1 maximum: 1000 - name: Page in: query description: The page index. This value is simply for client state. schema: type: integer minimum: 0 - name: PageToken in: query description: The page token. This is provided by the API. schema: type: string responses: '200': content: application/json: schema: $ref: '#/components/schemas/ListRecordingResponse' description: OK security: - accountSid_authToken: [] operationId: ListRecording x-maturity: - GA components: schemas: Recording: type: object properties: sid: type: string pattern: ^RE[0-9a-fA-F]{32}$ description: Unique identifier for the recording account_sid: type: string pattern: ^AC[0-9a-fA-F]{32}$ call_sid: type: string pattern: ^CA[0-9a-fA-F]{32}$ conference_sid: type: string description: SID of the conference if applicable channels: type: integer description: Number of channels in the recording status: type: string enum: - processing - completed - absent description: Status of the recording duration: type: string description: Duration of the recording in seconds price: type: string price_unit: type: string source: type: string enum: - DialVerb - Conference - OutboundAPI - Trunking - RecordVerb - StartCallRecordingAPI - StartConferenceRecordingAPI date_created: type: string format: date-time date_updated: type: string format: date-time uri: type: string recording_enum_type: type: string enum: - audio - video - data recording_enum_codec: type: string enum: - VP8 - H264 - OPUS - PCMU VideoRecordingList: type: object properties: recordings: type: array items: $ref: '#/components/schemas/VideoRecording' meta: $ref: '#/components/schemas/PaginationMeta' VideoRecording: type: object properties: sid: type: string pattern: ^RT[0-9a-fA-F]{32}$ description: Unique identifier for the recording account_sid: type: string pattern: ^AC[0-9a-fA-F]{32}$ room_sid: type: string pattern: ^RM[0-9a-fA-F]{32}$ source_sid: type: string description: SID of the track being recorded status: type: string enum: - processing - completed - deleted - failed type: type: string enum: - audio - video duration: type: integer description: Duration in seconds size: type: integer description: Size of the recording in bytes container_format: type: string enum: - mka - mkv codec: type: string enum: - VP8 - H264 - OPUS - PCMU grouping_sids: type: object description: Grouping identifiers track_name: type: string offset: type: integer description: Offset in milliseconds from room start media_external_location: type: string format: uri date_created: type: string format: date-time date_updated: type: string format: date-time url: type: string format: uri links: type: object properties: media: type: string format: uri recording_enum_format: type: string enum: - mka - mkv PaginationMeta: type: object properties: page: type: integer page_size: type: integer first_page_url: type: string format: uri previous_page_url: type: string format: uri next_page_url: type: string format: uri url: type: string format: uri key: type: string recording_enum_status: type: string enum: - processing - completed - deleted - failed video.v1.recording: type: object properties: account_sid: type: string minLength: 34 maxLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ nullable: true description: The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the Recording resource. status: type: string $ref: '#/components/schemas/recording_enum_status' nullable: true description: 'The status of the recording. Can be: `processing`, `completed`, or `deleted`. `processing` indicates the recording is still being captured; `completed` indicates the recording has been captured and is now available for download. `deleted` means the recording media has been deleted from the system, but its metadata is still available.' date_created: type: string format: date-time nullable: true description: The date and time in GMT when the resource was created specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format. sid: type: string minLength: 34 maxLength: 34 pattern: ^RT[0-9a-fA-F]{32}$ nullable: true description: The unique string that we created to identify the Recording resource. source_sid: type: string minLength: 34 maxLength: 34 pattern: ^[a-zA-Z]{2}[0-9a-fA-F]{32}$ nullable: true description: The SID of the recording source. For a Room Recording, this value is a `track_sid`. size: type: integer format: int64 nullable: true description: The size of the recorded track, in bytes. url: type: string format: uri nullable: true description: The absolute URL of the resource. type: type: string $ref: '#/components/schemas/recording_enum_type' nullable: true description: 'The recording''s media type. Can be: `audio` or `video`.' duration: type: integer nullable: true description: The duration of the recording in seconds rounded to the nearest second. Sub-second tracks have a `Duration` property of 1 second container_format: type: string $ref: '#/components/schemas/recording_enum_format' nullable: true description: 'The file format for the recording. Can be: `mka` or `mkv`. Video Room recordings are captured in [Matroska container format](https://matroska.org/), `mka` is for audio files and `mkv` for video files.' codec: type: string $ref: '#/components/schemas/recording_enum_codec' nullable: true description: 'The codec used to encode the track. Can be: `VP8`, `H264`, `OPUS`, and `PCMU`.' grouping_sids: nullable: true description: A list of SIDs related to the recording. Includes the `room_sid` and `participant_sid`. track_name: type: string nullable: true description: The name that was given to the source track of the recording. If no name is given, the `source_sid` is used. x-twilio: pii: handling: standard deleteSla: 30 offset: type: integer format: int64 nullable: true description: The time in milliseconds elapsed between an arbitrary point in time, common to all group rooms, and the moment when the source room of this track started. This information provides a synchronization mechanism for recordings belonging to the same room. media_external_location: type: string format: uri nullable: true description: The URL of the media file associated with the recording when stored externally. See [External S3 Recordings](/docs/video/api/external-s3-recordings) for more details. status_callback: type: string format: uri nullable: true description: The URL called using the `status_callback_method` to send status information on every recording event. status_callback_method: type: string format: http-method enum: - HEAD - GET - POST - PATCH - PUT - DELETE nullable: true description: 'The HTTP method used to call `status_callback`. Can be: `POST` or `GET`, defaults to `POST`.' links: type: object format: uri-map nullable: true description: The URLs of related resources. ListRecordingResponse: type: object properties: recordings: type: array items: $ref: '#/components/schemas/video.v1.recording' meta: type: object properties: first_page_url: type: string format: uri next_page_url: type: string format: uri nullable: true page: type: integer page_size: type: integer previous_page_url: type: string format: uri nullable: true url: type: string format: uri key: type: string RecordingSettings: type: object properties: account_sid: type: string pattern: ^AC[0-9a-fA-F]{32}$ friendly_name: type: string aws_credentials_sid: type: string aws_s3_url: type: string format: uri aws_storage_enabled: type: boolean encryption_key_sid: type: string encryption_enabled: type: boolean url: type: string format: uri RecordingList: type: object properties: recordings: type: array items: $ref: '#/components/schemas/Recording' first_page_uri: type: string next_page_uri: type: string page: type: integer page_size: type: integer uri: type: string parameters: AccountSid: name: AccountSid in: path required: true description: The unique identifier of the Twilio account schema: type: string pattern: ^AC[0-9a-fA-F]{32}$ CallSid: name: CallSid in: path required: true description: The unique identifier of the call schema: type: string pattern: ^CA[0-9a-fA-F]{32}$ RoomSid: name: RoomSid in: path required: true description: The SID or unique name of the room schema: type: string RecordingSid: name: RecordingSid in: path required: true description: The unique identifier of the recording schema: type: string pattern: ^RE[0-9a-fA-F]{32}$ securitySchemes: accountSid_authToken: type: http scheme: basic x-maturity: - name: GA description: This product is Generally Available. - name: Beta description: PLEASE NOTE that this is a Beta product that is subject to change. Use it with caution.