01
Create one key
Sign in, create a scoped API key, and choose the service group for your project.
Une passerelle API unifiée pour modèles IA. Meilleurs prix, meilleure fiabilité. Remplacez simplement votre URL de base pour commencer.
Compatible avec les formats OpenAI, Anthropic, Gemini
from openai import OpenAI client = OpenAI( api_key="sk-xxx", base_url="https://tokencode.dev/v1", ) # Switch to any model by name resp = client.chat.completions.create( model="gpt-5.5", messages=[{"role": "user", "content": "Hello!"}], stream=True, ) for chunk in resp: print(chunk.choices[0].delta.content, end="")
import OpenAI from 'openai' const client = new OpenAI({ apiKey: 'sk-xxx', baseURL: 'https://tokencode.dev/v1', }) // Switch to any model by name const stream = await client.chat.completions.create({ model: 'gpt-5.5', messages: [{ role: 'user', content: 'Hello!' }], stream: true, }) for await (const chunk of stream) { process.stdout.write( chunk.choices[0]?.delta?.content ?? '' ) }
curl https://tokencode.dev/v1/chat/completions \ -H "Authorization: Bearer sk-xxx" \ -H "Content-Type: application/json" \ -d { "model": "gpt-5.5", "stream": true, "messages": [ {"role": "user", "content": "Hello!"} ] }
Sign in, create a scoped API key, and choose the service group for your project.
Keep your OpenAI-compatible client and point it at the gateway endpoint.
Track token usage, latency, provider status, and cost from the portal.
Inscrivez-vous, obtenez votre clé et effectuez votre premier appel API.