Knowledge Base Sections ▾
Navigation
▸ Start here By rolesCategories
- OpenCode: free models, providers and API key
- Cursor + Gonka AI - cheap LLM for coding
- Claude Code + Gonka AI - LLM for the terminal
- DeepSeek Harness: Your Own Provider via JoinGonka Gateway
- Codex CLI: your own key instead of a subscription
- Pi + JoinGonka Gateway — terminal agent on cheap inference
- omp (Oh My Pi) + JoinGonka Gateway: an agent with model roles
- Zoo Code + JoinGonka Gateway: Migrating from Roo Code to Gonka models
- Kilo Code + Gonka AI — AI-Agent in VS Code
- ZCode: GLM Coding Plan tiers, prices and limits
- Hermes Agent + DeepSeek on the Gonka network — an autonomous agent for pennies
- OpenClaw + Gonka AI - affordable AI agents
- Continue.dev + Gonka AI - AI for VS Code/JetBrains
- Cline + Gonka AI - AI agent in VS Code
- Aider + Gonka AI - pair programming with AI
- LangChain + Gonka AI - AI applications for pennies
- n8n + Gonka AI - automation with cheap AI
- Open WebUI + Gonka AI - your own ChatGPT
- LibreChat + Gonka AI — open-source ChatGPT
- Roo Code + Gonka AI — Autonomous AI Agent in VS Code
- LlamaIndex + Gonka AI — RAG applications for pennies
- PydanticAI + Gonka — typed AI agents for pennies
- Vercel AI SDK + Gonka AI — AI applications in TypeScript for pennies
- TanStack AI + Gonka — AI applications in TypeScript for pennies
- API quick start — curl, Python, TypeScript
- JoinGonka Gateway — a full overview
- Management Keys — SaaS on Gonka
- Cheapest AI API: Provider Comparison 2026
- How to buy AI tokens and an API key: 3 methods in 2026
- Free AI API: tokens on sign-up and for referrals
- Cursor Pro request limit reached — breakdown and cheaper alternative
- Cheaper Claude Code: GLM and DeepSeek instead of Claude
- Claude Code + DeepSeek V4 Flash: How to Connect It and What a Task Costs
- Cline is burning money — why the agent spends so much
- OpenClaw is expensive — why the agent burns through tokens and how to save
- OpenRouter alternative: the same models, many times cheaper
- Best AI model for coding in 2026: comparison and prices
- Cheap alternative to GitHub Copilot without limits
- A cheap Windsurf alternative without credits or limits
- The cheapest API for AI agents in 2026
- JetBrains IDE + JoinGonka Gateway — your own endpoint instead of credits
- GitHub Copilot BYOK — own models instead of quotas
- Zed + JoinGonka Gateway — cheap inference in your editor
- MiniMax Code: MiniMax agent with your own key via Gonka
- Warp + JoinGonka Gateway — terminal agent on your own endpoint
- Trae + JoinGonka Gateway — Gonka network models in AI-IDE
- Cherry Studio + JoinGonka Gateway — desktop AI client
- OpenHands + JoinGonka Gateway: agent on your own endpoint
- Qwen Code after the closure of qwen-oauth: working via JoinGonka Gateway
- Goose + JoinGonka Gateway: your own provider and key in the keyring
- Crush + JoinGonka Gateway: Charm agent on Gonka network models
- Kimi Code CLI: Moonshot AI agent on your key via Gonka
- Factory Droid + JoinGonka Gateway: BYOK on Gonka network models
- MiMo Code + JoinGonka Gateway: Xiaomi agent on Gonka network models
Tools
Pi + JoinGonka Gateway — terminal agent on cheap inference
Pi (pi.dev) is a minimalist terminal coding agent, one of the fastest-growing open harnesses of 2026. It describes providers declaratively in ~/.pi/agent/models.json, and any endpoint that speaks OpenAI Completions or Anthropic Messages will do — which means JoinGonka Gateway connects either way. Models on the decentralized Gonka network cost many times cheaper than vendors' list prices, and the starting 3M tokens are free.
Pi itself installs from npm: npm install -g --ignore-scripts @earendil-works/pi-coding-agent. The package name is new: the project moved to the earendil-works/pi repository, and the former package @mariozechner/pi-coding-agent is declared deprecated and no longer updated. If you have Pi installed under the old name, reinstall it; the settings directory ~/.pi/agent stayed the same through the move.
Fast path: installer
The shortest option is our installer:
npx @joingonka/setup --tool piIt will configure the provider with current network models in ~/.pi/agent/models.json, set the default model in ~/.pi/agent/settings.json (it does not override the model you have selected yourself — that can only be changed by the explicit --model minimax|deepseek|glm flag), and perform a live request to verify that the gateway accepts the key and model. If the configuration directory is migrated using the PI_CODING_AGENT_DIR variable, the installer writes to the same location. The key is stored as a literal in the config with 0600 permissions — there is no need to export an environment variable.
Manual configuration: provider in models.json
Get a jg-… key when you register and add the provider to ~/.pi/agent/models.json:
baseUrl | https://gate.joingonka.ai/v1 |
api | openai-completions |
apiKey | your jg-… key as a literal. Pi also understands $VAR/${VAR} references and !command, but a literal works without an exported variable — keep the file at 0600 permissions |
models | array: id, name, contextWindow, maxTokens |
Correct values for the network's models: deepseek-ai/DeepSeek-V4-Flash-0731 — contextWindow 380000, maxTokens 32768; MiniMaxAI/MiniMax-M2.7 — contextWindow 180000, maxTokens 8192; zai-org/GLM-5.3-Flash — contextWindow 390000, maxTokens 8192. Pi's defaults (128000/16384) don't match the network's actual limits, so set both fields explicitly. The default model lives in a DIFFERENT file — ~/.pi/agent/settings.json, in the defaultProvider and defaultModel fields. To verify: pi --list-models should show the models you added.
Anthropic path as an alternative
The gateway also provides Anthropic Messages: a provider with api: "anthropic-messages" and baseUrl: "https://gate.joingonka.ai" — without the /v1/messages path, the client will append it itself. For daily work, the OpenAI path is sufficient; the Anthropic option is useful if your Pi extensions are tuned for the Messages format.
Safety disclaimer
Pi does not have a full permission layer by default: the agent executes commands in the terminal without the step-by-step confirmation found in heavier harnesses. Run it in a sandbox — a container or a separate user account — especially for autonomous multi-step tasks. This is a property of Pi itself, not the gateway.
Which model to choose and pricing
All three network models support tool calling and streaming. For long sessions and large repositories, use DeepSeek V4 Flash (one of the longest context windows in the network and output up to 32768). MiniMax M2.7 is a universal option, while GLM-5.3 Flash is a reasoning model with the longest network context (390K): it reasons before answering, so do not lower its maxTokens. The tariff is unified, and real-time prices are available in the gateway pricing list.
If Pi's minimalism isn't enough, take a look at its fork omp (Oh My Pi): it follows the same idea of declarative providers but adds model roles, language servers, and subagents. Their configs are different, so omp is set up separately.