> ## Documentation Index
> Fetch the complete documentation index at: https://docs.portkey.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Deepgram

> Use Deepgram's Speech-to-Text API through Prisma AIRS AI Gateway for audio transcription.

Deepgram provides industry-leading speech-to-text capabilities. The AI Gateway allows you to use Deepgram's API with full observability and reliability features.

<Note>
  Deepgram currently uses a custom host setup. SDK support is available through the custom host pattern.
</Note>

## Quick Start

Get started with Deepgram in under 2 minutes:

### Speech to Text - Local File

Transcribe audio from a local file:

```bash cURL theme={"system"}
curl https://aigw.portkey.ai/v1/listen \
  -H "Authorization: Token $DEEPGRAM_API_KEY" \
  -H "Content-Type: audio/mp3" \
  -H "x-portkey-custom-host: https://api.deepgram.com/v1" \
  -H "x-portkey-provider: openai" \
  -H "x-portkey-api-key: $PORTKEY_API_KEY" \
  --data-binary '@audio.mp3'
```

### Speech to Text - Remote File

Transcribe audio from a URL:

```bash cURL theme={"system"}
curl https://aigw.portkey.ai/v1/listen \
  -H "Authorization: Token $DEEPGRAM_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -H "x-portkey-custom-host: https://api.deepgram.com/v1" \
  -H "x-portkey-provider: openai" \
  -H "x-portkey-api-key: $PORTKEY_API_KEY" \
  -d '{"url": "https://dpgr.am/spacewalk.wav"}'
```

## Add Provider in Model Catalog

Before making requests, add Deepgram to your Model Catalog:

1. Go to [**Model Catalog → Add Provider**](https://stratacloudmanager.paloaltonetworks.com/)
2. Select **Deepgram**
3. Enter your [Deepgram API key](https://console.deepgram.com/)
4. Set the custom host to `https://api.deepgram.com/v1`
5. Name your provider (e.g., `deepgram`)

<Card title="Complete Setup Guide" icon="book" href="/docs/aigw/product/model-catalog">
  See all setup options and detailed configuration instructions
</Card>

***

## Using with the OpenAI SDK

You can also use Deepgram with the OpenAI SDK using custom host configuration:

***

## Deepgram Features

Deepgram offers advanced speech recognition capabilities:

* **Real-time Streaming**: Transcribe audio in real-time
* **Multiple Languages**: Support for 30+ languages
* **Custom Models**: Train custom models for domain-specific terminology
* **Diarization**: Identify different speakers in audio
* **Punctuation & Formatting**: Automatic punctuation and formatting

<Card icon="link" title="Deepgram API Documentation" href="https://developers.deepgram.com/reference/listen-file">
  Explore the complete Deepgram API documentation
</Card>

***

## Next Steps

<CardGroup cols={2}>
  <Card title="Gateway Configs" icon="sliders" href="/docs/aigw/product/ai-gateway">
    Add retries and timeouts for audio processing
  </Card>

  <Card title="Observability" icon="chart-line" href="/docs/aigw/product/observability">
    Monitor and trace your Deepgram requests
  </Card>

  <Card title="Custom Host Setup" icon="server" href="/docs/aigw/product/ai-gateway/universal-api#integrating-local-or-private-models">
    Learn more about custom host configuration
  </Card>

  <Card title="Metadata" icon="tag" href="/docs/aigw/product/observability/metadata">
    Add custom metadata to track audio sources
  </Card>
</CardGroup>


## Related topics

- [Enterprise Gateway](/docs/aigw/changelog/enterprise.md)
- [Supported Providers](/docs/aigw/api-reference/inference-api/supported-providers.md)
