Text · DeepSeek

DeepSeek API

Reasoning-first LLMs via RunAPI — flash for fast, low-cost work; pro for complex agentic tasks.

Operativo · 2 variants · da $0.010
runapi.ai
# Base URL
https://runapi.ai

# Endpoints
POST /v1/chat/completions
POST /v1/responses
POST /v1/messages
POST /v1beta/models/{model}:generateContent
POST /v1beta/models/{model}:streamGenerateContent
curl https://runapi.ai/v1/chat/completions \
  -H "Authorization: Bearer $RUNAPI_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "deepseek-v4-flash",
  "max_tokens": 1024,
  "messages": [
    {
      "role": "user",
      "content": "Refactor this Python module for readability, explain each change, then add unit tests for the edge cases."
    }
  ]
}'
from openai import OpenAI

client = OpenAI(
    base_url="https://runapi.ai/v1",
    api_key="your-runapi-key"
)

response = client.chat.completions.create(
    model="deepseek-v4-flash",
    messages=[{"role": "user", "content": "Refactor this Python module for readability, explain each change, then add unit tests for the edge cases."}]
)
import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://runapi.ai/v1",
  apiKey: "your-runapi-key"
});

const response = await client.chat.completions.create({
  model: "deepseek-v4-flash",
  messages: [{ role: "user", content: "Refactor this Python module for readability, explain each change, then add unit tests for the edge cases." }]
});
https://runapi.ai 5 endpoints
OVERVIEW

DeepSeek is a family of reasoning-first language models. deepseek-v4-flash is the fast, low-cost tier with an optional thinking mode; deepseek-v4-pro targets the hardest reasoning and agentic workloads. Both are available through RunAPI with one key and per-token billing.

  • Più varianti per diversi livelli di velocità / qualità
  • Il model skill include documentazione, schema e note di setup
  • Funziona con workflow di sviluppo app
  • Le generazioni fallite non vengono addebitate
VARIANTS

Confronta tutte le varianti API

Variant Billing From
deepseek-v4-flash 1K tokens $0.010 Visualizza →
deepseek-v4-pro 1K tokens $0.010 Visualizza →
API

Endpoint API DeepSeek

Usa l'SDK OpenAI o Anthropic con la tua chiave RunAPI. Nessun SDK aggiuntivo necessario.

Endpoint Protocol
/v1/chat/completions OpenAI compatible
/v1/responses OpenAI Responses
/v1/messages Anthropic compatible
/v1beta/models/{model}:generateContent Gemini generateContent
/v1beta/models/{model}:streamGenerateContent Gemini streamGenerateContent
COME FUNZIONA

Dal model skill al primo risultato in quattro passaggi

01

Scegli il modello

Seleziona modello e variante adatti al tipo di output, al livello qualità e alla latenza target.

02

Configura

Imposta la tua chiave RunAPI e installa il model skill nel workspace di codice.

03

Implementa

Usa le istruzioni dello skill per aggiungere la feature modello dentro la tua applicazione.

04

Ricevi

Interroga per task ID, usa streaming dove supportato o gestisci il callback webhook.

CONTEXT

Che cos'è l'API DeepSeek?

DeepSeek models are large language models tuned for reasoning, code, and agentic tool use. Through RunAPI they share a single API key with pay-as-you-go token billing, and are callable from both the OpenAI and Anthropic SDKs.

Provider
DeepSeek
Modality
Text
PERCHÉ RUNAPI

Perché usare l'API DeepSeek tramite RunAPI

Un’unica autenticazione, tutti i provider

Una sola chiave RunAPI sblocca l’intero catalogo. Niente account separati, niente rotazione delle chiavi per integrazione.

Prezzi e billing unificati

Prezzi per chiamata in USD, fatturati mensilmente. Le generazioni fallite non vengono addebitate.

Skill con schema

Schema tipizzati e note di setup sono inclusi nel model skill, così l'implementazione parte dal contratto corretto.

FAQ

Domande frequenti

What is the difference between deepseek-v4-flash and deepseek-v4-pro?

Flash is the fast, low-cost tier for everyday tasks; pro targets the most complex reasoning and long agentic workflows at a higher token price.

How do I turn on thinking (reasoning) mode?

Thinking is a request parameter on deepseek-v4-flash, not a separate model — set it per request when you want step-by-step reasoning.

Can I call DeepSeek with both the OpenAI and Anthropic SDKs?

Yes. DeepSeek is available on both the OpenAI Chat Completions and the Anthropic Messages surfaces; point either SDK at RunAPI and pass the deepseek model id.

How are cached prompt tokens billed?

Cached prompt tokens bill at a much lower cache-read rate than fresh input tokens; cache hits are detected automatically and reflected in usage.

Which DeepSeek variants should I use?

Use deepseek-v4-flash for fast everyday work and deepseek-v4-pro for more complex reasoning and agentic workflows.

Da quale variante dovrei iniziare?

Scegli la variante più economica che soddisfa il tuo livello di qualità. La maggior parte dei team inizia con la variante veloce e passa alla pro per la produzione.

C’è un piano gratuito?

I nuovi account ricevono le prime chiamate gratuite su ogni modello. Dopo, paghi per chiamata.

Trasmettete i risultati in streaming?

Dove lo streaming è disponibile, RunAPI trasmette end-to-end.

Come vengono addebitati i fallimenti?

Le generazioni non riuscite non vengono addebitate.

Gli output vengono memorizzati nella cache?

Gli output generati vengono salvati e recuperabili tramite ID del task. Gli input non vengono memorizzati nella cache.

Posso usarlo a fini commerciali?

Sì — l’uso commerciale è incluso per ogni variante, salvo che una licenza del modello lo limiti esplicitamente; in tal caso è indicato nella pagina della variante.

E i limiti di rate limit?

I rate limit per chiave scalano in base al tier di utilizzo. Vedi la pagina prezzi per i limiti aggiornati.

Dove posso segnalare problemi?

Apri un issue nel repo GitHub pubblico oppure scrivi al supporto.

INIZIA ORA

Inizia a sviluppare con l'API DeepSeek.