Skip to main content
POST
/
voice
/
recognize
Recognize speech
curl --request POST \
  --url https://api.spikelabs.com/v1/voice/recognize \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form audio='@example-file' \
  --form language=en \
  --form 'prompt=<string>'
{
  "text": "<string>",
  "language": "<string>",
  "duration": 123,
  "words": [
    {
      "word": "<string>",
      "start": 123,
      "end": 123,
      "confidence": 123
    }
  ]
}

Authorizations

Authorization
string
header
required

API key authentication. Use your secret key (starts with sk_) as a Bearer token.

Body

multipart/form-data
audio
file
required

Audio file (mp3, wav, webm, ogg)

language
string
default:en

Language code (e.g., 'en', 'es')

prompt
string

Optional context to improve recognition

Response

Transcription result

text
string
required

Transcribed text

language
string

Detected language code

duration
number

Audio duration in seconds

words
object[]