DeepSeek offers 2 models through Lava’s AI Gateway, supporting Chat Completions. Authentication uses Authorization: Bearer. See the DeepSeek API docs for provider-specific parameters.
Supports both managed API keys (from Lava) and BYOK mode.
Quick Start
const response = await fetch('https://api.lavapayments.com/v1/forward?u=https%3A%2F%2Fapi.deepseek.com%2Fchat%2Fcompletions', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
Authorization: `Bearer ${forwardToken}`,
},
body: JSON.stringify({
model: 'deepseek-chat',
messages: [{ role: "user", content: "Hello!" }],
}),
});
Chat Completions
Target URL: https://api.deepseek.com/chat/completions
| |
|---|
| Content Type | application/json |
| Streaming | Yes (set stream: true in request body) |
| Model | Input / 1M tokens | Output / 1M tokens |
|---|
| deepseek-chat | $0.28 | $0.42 |
| deepseek-reasoner | $0.28 | $0.42 |
Next Steps