@todoforai/assemblyai-api
v0.1.0
Published
JSON-first CLI for the AssemblyAI speech-to-text API (transcripts, upload, LLM Gateway, streaming tokens)
Readme
AssemblyAI CLI
Independent JSON-first CLI over the AssemblyAI speech-to-text API. Not an official AssemblyAI product. Plain fetch, Node >= 20.
cd api-apps/assemblyai-api && npm install --workspaces=false && bun run build
node dist/index.js --helpAuth
API key from https://www.assemblyai.com/dashboard/api-keys.
<secret-manager> | assemblyai-api auth --key-stdin # validates, saves ~/.config/assemblyai-api/credentials.json (0600)
# or: ASSEMBLYAI_API_KEY=... assemblyai-api whoami
# EU data zone: ASSEMBLYAI_REGION=euCommands
| command | endpoint |
|---|---|
| auth, whoami, logout | GET /v2/transcript?limit=1 (no account endpoint exists) |
| upload <file> | POST /v2/upload |
| transcribe <url\|file> [--speaker-labels] [--language-code] [--data json] [--wait] | POST /v2/transcript (+ polling) |
| get <id> [--wait], list, delete <id> | /v2/transcript[/{id}] |
| sentences, paragraphs, redacted-audio, subtitles <id> srt\|vtt, word-search <id> <words> | /v2/transcript/{id}/... |
| chat --model m --prompt p, models | LLM Gateway https://llm-gateway.assemblyai.com/v1 (paid plans) |
| streaming-token --expires-in-seconds n | GET https://streaming.assemblyai.com/v3/token |
| api <METHOD> <path> [--host api\|llm\|streaming] | anything else |
Real-time streaming itself is a WebSocket (wss://streaming.assemblyai.com/v3/ws); use the official SDK for that.
