One API compatible with OpenAI and Anthropic
Point the SDK your code already uses, OpenAI or Anthropic, at Gonka Broker. Change the base URL and your API key, and your existing code runs open-source models on the Gonka network.
OpenAI-compatible API
Set base_url to
https://proxy.gonkabroker.com/v1 and use your
gnk-prx- key. Everything
else (request shape, streaming, tool calls) works the same in nearly every case.
from openai import OpenAI
client = OpenAI(
base_url="https://proxy.gonkabroker.com/v1",
api_key="gnk-prx-YOUR_KEY_HERE",
)
resp = client.chat.completions.create(
model="MiniMaxAI/MiniMax-M2.7",
messages=[{"role": "user", "content": "Hello!"}],
)
print(resp.choices[0].message.content) import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://proxy.gonkabroker.com/v1",
apiKey: "gnk-prx-YOUR_KEY_HERE",
});
const resp = await client.chat.completions.create({
model: "MiniMaxAI/MiniMax-M2.7",
messages: [{ role: "user", content: "Hello!" }],
});
console.log(resp.choices[0].message.content); curl https://proxy.gonkabroker.com/v1/chat/completions \
-H "Authorization: Bearer gnk-prx-YOUR_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{"model":"MiniMaxAI/MiniMax-M2.7",
"messages":[{"role":"user","content":"Hello!"}]}' Here's what that unlocks. Tool-by-tool setup guides live in the integrations catalog.
SDKs
Official OpenAI libraries for Python, JavaScript/TypeScript, Go, and more.
AI tools
Cursor, Continue, LibreChat, and anything with a custom OpenAI endpoint.
Frameworks
LangChain, LlamaIndex, and other libraries built on the OpenAI format.
Migrating an existing app? See the OpenAI migration guide.
Anthropic-compatible API
The same models over the Anthropic Messages protocol: point your client at
https://proxy.gonkabroker.com and authenticate with
x-api-key. Streaming, tool use, thinking
blocks, and count_tokens all work.
from anthropic import Anthropic
client = Anthropic(
base_url="https://proxy.gonkabroker.com",
api_key="gnk-prx-YOUR_KEY_HERE",
)
resp = client.messages.create(
model="moonshotai/Kimi-K2.6",
max_tokens=1024,
messages=[{"role": "user", "content": "Hello!"}],
)
print(resp.content[0].text) import Anthropic from "@anthropic-ai/sdk";
const client = new Anthropic({
baseURL: "https://proxy.gonkabroker.com",
apiKey: "gnk-prx-YOUR_KEY_HERE",
});
const resp = await client.messages.create({
model: "moonshotai/Kimi-K2.6",
max_tokens: 1024,
messages: [{ role: "user", content: "Hello!" }],
});
console.log(resp.content[0].text); curl https://proxy.gonkabroker.com/v1/messages \
-H "x-api-key: gnk-prx-YOUR_KEY_HERE" \
-H "anthropic-version: 2023-06-01" \
-H "Content-Type: application/json" \
-d '{"model":"moonshotai/Kimi-K2.6",
"max_tokens":1024,
"messages":[{"role":"user","content":"Hello!"}]}' Here's what that unlocks on the Anthropic side. Setup guides are in the integrations catalog.
SDKs
Official Anthropic libraries for Python and TypeScript: the Messages API, streaming, and tool use included.
Claude Code
Point your Claude Code agent at Gonka via ANTHROPIC_BASE_URL and run it on open-source models.
Agent tools
Any tool or framework that speaks the Anthropic Messages protocol and lets you set a base URL.
Running a Claude Code agent? See how to run it on open-source models.
Compatibility FAQ
Is the Anthropic API compatible with OpenAI?
Not directly: the official APIs use different endpoints and request shapes. That's why Gonka Broker exposes both surfaces over the same models and the same key. OpenAI clients use /v1/chat/completions, Anthropic clients use /v1/messages.
Do I need different keys for the two protocols?
No. One gnk-prx- key works on both surfaces: a Bearer token on the OpenAI side, x-api-key (or Bearer) on the Anthropic side. Billing and the free tier are shared.
Do you serve GPT or Claude models?
No. Gonka Broker serves open-source models (Kimi K2, MiniMax M2, BGE-M3) over both the OpenAI and Anthropic protocols. We are an independent service, not affiliated with OpenAI or Anthropic.
Drop Gonka into your app
Get a key, change two lines in your OpenAI or Anthropic client, and run open-source models in plain USD.
Get startedAlready have an account? Sign in