{
  "$schema": "https://json-structure.org/meta/core/v0/#",
  "$id": "https://raw.githubusercontent.com/api-evangelist/bandwidth/refs/heads/main/json-structure/voice-recording-structure.json",
  "name": "Recording",
  "description": "Recording schema from Bandwidth voice API",
  "type": "object",
  "properties": {
    "recordingId": {
      "type": "string",
      "description": "The unique identifier for the recording"
    },
    "accountId": {
      "type": "string",
      "description": "The Bandwidth account ID"
    },
    "callId": {
      "type": "string",
      "description": "The call ID associated with this recording"
    },
    "applicationId": {
      "type": "string",
      "description": "The application ID"
    },
    "duration": {
      "type": "string",
      "description": "The duration of the recording in ISO 8601 format"
    },
    "channels": {
      "type": "int32",
      "description": "The number of audio channels in the recording"
    },
    "startTime": {
      "type": "datetime",
      "description": "The time the recording started"
    },
    "endTime": {
      "type": "datetime",
      "description": "The time the recording ended"
    },
    "fileFormat": {
      "type": "string",
      "enum": [
        "wav",
        "mp3"
      ],
      "description": "The audio format of the recording"
    },
    "status": {
      "type": "string",
      "enum": [
        "complete",
        "partial",
        "error"
      ],
      "description": "The status of the recording"
    },
    "mediaUrl": {
      "type": "uri",
      "description": "The URL to download the recording media"
    },
    "transcription": {
      "$ref": "#/components/schemas/Transcription"
    }
  }
}