API REFERENCE
Transcribe Audio
On this page
/api/transcribeTranscribe audio files using OpenAI Whisper. The API saves both the original audio file and the generated markdown transcript to the customer's files in Supabase Storage. The owner account is derived from your credentials; you must have access to the specified artist_account_id.
Authentication
x-api-key in header
bearerAuth bearer
Request
curl --request POST \
--url 'https://api.recoupable.dev/api/transcribe' \
--header 'x-api-key: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"audio_url": "https://example.com/song.mp3",
"artist_account_id": "550e8400-e29b-41d4-a716-446655440001"
}'Request body required
Audio transcription request
application/json
audio_urlstringrequiredPublic URL to the audio file (mp3, wav, m4a, webm)
account_idstringDeprecated and ignored. The owner account is derived from your credentials. Sending this field is harmless but no longer affects attribution.
format: uuid
artist_account_idstringrequiredArtist account ID for file storage
format: uuid
titlestringOptional title for the audio and transcription files
include_timestampsbooleanWhether to include timestamps in the markdown transcript
Default: false
Responses
200Audio transcribed successfully+
application/json
successbooleanrequiredWhether the transcription was successful
audioFileobjectrequiredInformation about the saved audio file
Properties for audioFile
idstringUUID of the file record in the database
format: uuid
fileNamestringName of the saved file
storageKeystringStorage path in Supabase Storage
transcriptFileobjectrequiredInformation about the saved transcript file
Properties for transcriptFile
idstringUUID of the file record in the database
format: uuid
fileNamestringName of the saved file
storageKeystringStorage path in Supabase Storage
textstringrequiredThe full transcription text
languagestringDetected language code (e.g., 'en', 'es', 'fr')
400Bad request - missing required fields or invalid audio URL+
application/json
errorstringrequiredError message describing what went wrong
401Missing or invalid credentials+
application/json
errorstringrequiredError message describing what went wrong
403Caller has no access to the specified artist_account_id+
application/json
errorstringrequiredError message describing what went wrong
413Audio file exceeds the 25MB limit+
application/json
errorstringrequiredError message describing what went wrong
429Rate limit exceeded+
application/json
errorstringrequiredError message describing what went wrong
500Server error - OpenAI API key not configured+
application/json
errorstringrequiredError message describing what went wrong
Full specification
Download the OpenAPI file for complete schemas, constraints, and examples.
Download content.jsonView operation source
{
"description": "Transcribe audio files using OpenAI Whisper. The API saves both the original audio file and the generated markdown transcript to the customer's files in Supabase Storage. The owner account is derived from your credentials; you must have access to the specified artist_account_id.",
"security": [
{
"apiKeyAuth": []
},
{
"bearerAuth": []
}
],
"requestBody": {
"description": "Audio transcription request",
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/TranscribeAudioRequest"
}
}
}
},
"responses": {
"200": {
"description": "Audio transcribed successfully",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/TranscribeAudioResponse"
}
}
}
},
"400": {
"description": "Bad request - missing required fields or invalid audio URL",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/TranscribeAudioErrorResponse"
}
}
}
},
"401": {
"description": "Missing or invalid credentials",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/TranscribeAudioErrorResponse"
}
}
}
},
"403": {
"description": "Caller has no access to the specified artist_account_id",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/TranscribeAudioErrorResponse"
}
}
}
},
"413": {
"description": "Audio file exceeds the 25MB limit",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/TranscribeAudioErrorResponse"
}
}
}
},
"429": {
"description": "Rate limit exceeded",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/TranscribeAudioErrorResponse"
}
}
}
},
"500": {
"description": "Server error - OpenAI API key not configured",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/TranscribeAudioErrorResponse"
}
}
}
}
}
}