Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Is that skill safe to install?
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
Are you the author of Deepgram?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/ashish7802-deepgram)
# Deepgram Speech-to-Text API Skill
> **Verification Tier:** `code_example_tested` | **Last Verified:** 2026-11-18
> **Official Docs:** https://developers.deepgram.com/docs/getting-started-with-pre-recorded-audio
## Overview
Deepgram provides high-accuracy, low-latency Speech-to-Text (STT) using the `nova-3` model family for both pre-recorded audio files/URLs and real-time bidirectional WebSocket streaming.
## Installation
```bash
npm install @deepgram/sdk
pip install deepgram-sdk
```
## Authentication
Send `Authorization: Token <DEEPGRAM_API_KEY>` (handled by `createClient(process.env.DEEPGRAM_API_KEY)`). For browser-direct live streaming, mint short-lived scoped tokens on your backend rather than exposing long-lived admin keys.
## Core Concepts
- **Model & Features**: Use `model: "nova-3"` with `smart_format: true`, `diarize: true` (speaker labels), `punctuate: true`, and `keyterm` boosting for domain vocabulary.
- **Live Streaming KeepAlive**: Deepgram closes idle WebSocket connections after ~10 seconds of no audio bytes. Send `{ type: "KeepAlive" }` frames every 5–8 seconds during silence and `{ type: "CloseStream" }` when ending cleanly.
- **Callback Webhooks**: For long audio files (>10 min), pass a `callback` URL to receive asynchronous completion instead of holding an HTTP connection open.
## Error Handling & Rate Limits
- Check both `error` and `result` returned by SDK calls.
- Monitor concurrency limits (varies by plan, e.g., 100 concurrent REST / 50 concurrent WebSockets on Pay-As-You-Go) and handle HTTP `429` with exponential backoff.
## Security Best Practices
- Restrict API keys to least-privilege scopes (`usage:write`) and set TTLs on temporary frontend tokens.
- Enable `redact: ["pci", "pii"]` when transcribing regulated financial or healthcare audio.
## AI Pitfalls
- Forgetting `KeepAlive` frames on paused microphone streams, triggering unexpected `NET-0001` WebSocket disconnects.
- Passing `Authorization: Bearer` instead of `Authorization: Token` when calling REST endpoints directly with `fetch`.
- Specifying legacy `nova-2` keyword parameters when migrating to `nova-3` (`keyterm`).
## Production Checklist
- [ ] `DEEPGRAM_API_KEY` kept server-side or exchanged for short-lived scoped tokens
- [ ] `smart_format: true` and explicit `model: "nova-3"` set
- [ ] Live WebSockets implement `KeepAlive` timer and graceful `CloseStream`
- [ ] Long recordings use asynchronous `callback` webhooks
## References
- [Deepgram Pre-Recorded Audio](https://developers.deepgram.com/docs/getting-started-with-pre-recorded-audio)
- [Deepgram Live Streaming](https://developers.deepgram.com/docs/getting-started-with-live-streaming-audio)
## Related skills
- [`elevenlabs`](../elevenlabs/SKILL.md) — works well with
- [`openai-responses`](../openai-responses/SKILL.md) — works well with
- [`twilio`](../twilio/SKILL.md) — integrates with