SDK-first: always use the official SDK — see gladia-sdk-integration for policy, setup, and fallback criteria.
Consult these sibling skills as needed:
Gladia is a speech-to-text (STT) API that transcribes audio and video files asynchronously (pre-recorded) or in real-time (live). It supports 100+ languages, speaker diarization, translation, and audio intelligence features like summarization, sentiment analysis, and entity recognition. Use the JavaScript/Python SDKs ( @gladiaio/sdk or gladiaio-sdk), REST API endpoints, or the CLI ( gladia command) to transcribe. Authentication uses the x-gladia-key header. Primary docs: https://docs.gladia.io
Key endpoints:
POST /v2/pre-recorded (create job), GET /v2/pre-recorded/{id} (get result), POST /v2/upload (upload file)POST /v2/live (init session), WebSocket connection for streaming audiox-gladia-key header on all requestsReach for this skill when:
ModelUse caseLanguagesCode switchingLive supportsolaria-3Highest accuracy on European audioen, fr, de, es, itNoNo (pre-recorded only)solaria-1Generalist, maximum coverage100+ languagesYesYes
POST /v2/upload with multipart form-data → get audio_urlPOST /v2/pre-recorded with audio_url and options → get idGET /v2/pre-recorded/{id} until status: "done" or use webhooks/callbacksPOST /v2/live with audio config → get WebSocket url and idstop_recording message or close with code 1000FeatureParameterUse caseSpeaker diarizationdiarization: trueIdentify who spoke whenTranslationtranslation: trueTranslate to multiple languagesSummarizationsummarization: trueGenerate summaries or bullet pointsSentiment analysissentiment_analysis: trueExtract emotions and toneNamed entity recognitionnamed_entity_recognition: trueDetect people, organizations, datesPII redactionpii_redaction: trueAnonymize sensitive dataCustom vocabularycustom_vocabulary: trueBoost accuracy for domain termsSubtitlessubtitles: trueGenerate SRT or VTT files
bash
# JavaScript
npm install @gladiaio/sdk
# Python
pip install gladiaio-sdk
# or
uv add gladiaio-sdk
bash
# macOS & Linux
curl -fsSL https://github.com/gladiaio/gladia-cli/releases/latest/download/install.sh | sh
# Windows (PowerShell)
powershell -c "irm https://github.com/gladiaio/gladia-cli/releases/latest/download/install.ps1 | iex"
bash
gladia auth set YOUR_API_KEY
gladia transcribe audio.wav # plain text
gladia transcribe audio.wav -o json # JSON output
gladia transcribe audio.wav --diarize # with speaker labels
gladia transcribe audio.wav --language en,fr # constrain languages
gladia transcribe audio.wav --model solaria-3 # use specific model
ScenarioUseUser uploads a file, you transcribe laterPre-recorded ( /v2/pre-recorded)Real-time call, meeting, or voice agentLive ( /v2/live + WebSocket)Batch processing many filesPre-recorded with polling or webhooksNeed results immediately as user speaksLive with receive_partial_transcripts: true
ApproachBest forTrade-offPollingSmall jobs, quick feedbackKeeps connection open, higher latencyWebhooksProduction, many jobsConfigure once at https://app.gladia.io/webhooksCallbacksPer-job controlSet callback_config in request body
ConditionChooseEuropean audio, high accuracy neededsolaria-3Multiple languages or code switchingsolaria-1Live transcription requiredsolaria-1 (only option)Unknown language or 100+ language supportsolaria-1
ScenarioEnableMulti-speaker call or meetingYesSingle speaker or known channelsNo (use channel field instead)Want speaker labels in outputYes, set diarization: trueKnow exact speaker countSet diarization_config.number_of_speakersSpeaker count variesSet diarization_config.min_speakers and max_speakers
Initialize client: Create GladiaClient with API key
Transcribe in one call: Use .transcribe(audioPath, options) for end-to-end flow
Or use individual steps for fine control:
.uploadFile(path) → get audio_url.createUntyped({audio_url, ...options}) → get id.get(id) until status: "done"Access results: Extract result.transcription.full_transcript, utterances, translations, etc.
POST /v2/upload with multipart form-dataPOST /v2/pre-recorded with JSON body containing audio_url and optionsGET /v2/pre-recorded/{id} every 2–5 seconds until status: "done"
callback_config in request to receive POST when doneresult.transcription, result.translation, result.summarization, etc..startSession(config) with audio format (encoding, sample_rate, bit_depth, channels)message, started, ended, error.sendAudio(chunk) as audio arrivesmessage event, check message.type === 'transcript' and is_final flag.stopRecording() to finalize and trigger post-processingGET /v2/live/{id} after session endsPOST /v2/live with audio config → get WebSocket url and idurltype and is_final fields{"type": "stop_recording"} or close with code 1000GET /v2/live/{id} after WebSocket closesgladia auth set YOUR_KEY (or export GLADIA_API_KEY)gladia transcribe <file-or-url> [options]-o text|json|json-full|srt|vtt--diarize, --language en,fr, --code-switching, --model solaria-3gladia transcribe audio.wav -o json | jq '.transcription'language_config.languages — do not pass multiple or enable code switching. Use solaria-1 for multi-language.solaria-1. Attempting solaria-3 will fail.encoding, sample_rate, bit_depth, and channels correctly in live init — mismatches cause garbled output.x-gladia-key in frontend code. Generate WebSocket URL on backend and pass only the URL to clients.number_of_speakers, min_speakers, max_speakers are hints; actual detection may differ.custom_spelling for strict spelling control./v2/transcription/* endpoints (deprecated); use /v2/pre-recorded/* instead.Before submitting transcription work:
transcription, translation, summarization, etc.)Comprehensive page listing: https://docs.gladia.io/llms.txt
Critical documentation pages:
For additional documentation and navigation, see: https://docs.gladia.io/llms.txt
This file is auto-synced from https://docs.gladia.io/.well-known/agent-skills/gladia/skill.md Do not edit manually — changes will be overwritten by CI. For additional documentation and navigation, see: https://docs.gladia.io/llms.txt