https://github.com/gonkagate/claude-code-setup
One-command installer for using Claude Code with GonkaGate. No shell config, no .env files, no manual gateway setup.
https://github.com/gonkagate/claude-code-setup
ai ai-agents ai-gateway ai-tools claude-code gonka gonka-network gonkagate
Last synced: 12 days ago
JSON representation
One-command installer for using Claude Code with GonkaGate. No shell config, no .env files, no manual gateway setup.
- Host: GitHub
- URL: https://github.com/gonkagate/claude-code-setup
- Owner: GonkaGate
- License: apache-2.0
- Created: 2026-03-31T15:54:41.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2026-07-06T23:31:40.000Z (18 days ago)
- Last Synced: 2026-07-07T01:10:59.360Z (18 days ago)
- Topics: ai, ai-agents, ai-gateway, ai-tools, claude-code, gonka, gonka-network, gonkagate
- Language: TypeScript
- Homepage: https://gonkagate.com
- Size: 47.7 MB
- Stars: 3
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
- Security: docs/security.md
- Agents: AGENTS.md
Awesome Lists containing this project
README
# @gonkagate/claude-code
Set up Claude Code to use GonkaGate in one `npx` command.
```bash
npx @gonkagate/claude-code
```



[](https://gonkagate.com/en?utm_source=github&utm_medium=referral&utm_campaign=claude_code_setup&utm_content=readme_badge_website)
[](https://gonkagate.com/en/docs?utm_source=github&utm_medium=referral&utm_campaign=claude_code_setup&utm_content=readme_badge_docs)
[](https://gonkagate.com/en/register?utm_source=github&utm_medium=referral&utm_campaign=claude_code_setup&utm_content=readme_badge_api_key)
[](https://t.me/gonkagate)
[](https://x.com/gonkagate)
[](https://www.linkedin.com/company/gonkagate)
## See It In Action
From API key to a working Claude Code setup in one short walkthrough:
[](https://raw.githubusercontent.com/GonkaGate/claude-code-setup/main/.github/assets/gonkagate-claude-code-demo.mp4)
Need an API key first? [Create one on GonkaGate](https://gonkagate.com/en?utm_source=github&utm_medium=referral&utm_campaign=claude_code_setup&utm_content=readme_api_key_cta).
## Overview
`@gonkagate/claude-code` is for developers who already have local `Claude Code`
and want to use it with GonkaGate without editing shell profiles, exporting
long env var blocks, or writing `.env` files by hand.
Under the hood it configures Claude Code to use GonkaGate's Anthropic-
compatible endpoint at `https://api.gonkagate.com`.
It does not install `Claude Code` itself. It configures an existing local
Claude Code install.
For setup-style naming consistency, the alias
`npx @gonkagate/claude-code-setup` runs the same installer.
You will be asked for:
- your GonkaGate API key (`gp-...`) in a hidden interactive prompt
- a model fetched from GonkaGate's live `/v1/models` response for that key
- setup scope: `user` or `local`
If you choose `local` scope and `.claude/settings.local.json` is already tracked by git, the installer offers to stop tracking that file and continue, or switch to `user` scope instead.
You need:
- local `Claude Code`
- Node.js 18+
- a GonkaGate API key
## Model Source
The installer calls `GET https://api.gonkagate.com/v1/models` with your GonkaGate API key and uses that live response as the source of truth for model selection.
New or removed GonkaGate models do not require an installer update. You can skip the model prompt with `--model `, but the id must be present in the live `/v1/models` response for your key.
## What It Does
The tool writes Claude Code settings so you can keep running `claude` normally afterward.
By default it writes to:
- `~/.claude/settings.json`
If you choose local scope, it writes to:
- `.claude/settings.local.json`
It also:
- preserves unrelated Claude Code settings
- creates a backup before overwriting an existing settings file
- writes settings files with owner-only permissions
- writes backup files with owner-only permissions
- adds `.claude/settings.local.json` and local backup files to `.git/info/exclude` for local setup inside a git repo
- offers to stop tracking `.claude/settings.local.json` before local setup writes secrets into a file that was already tracked by git
- refuses local setup if the target path traverses a symlinked path component, or if `.claude` / the local settings file is a symlink
## Fixed GonkaGate Setup
These parts are intentionally fixed:
- Base URL: `https://api.gonkagate.com`
- Auth variable: `ANTHROPIC_AUTH_TOKEN`
- Model choice: only from `GET https://api.gonkagate.com/v1/models` using your API key
This tool does not ask for a custom base URL and does not accept model IDs outside the live GonkaGate response for your key.
The selected model is written into all Claude Code model env vars used by this setup flow.
## Verify
After setup:
1. If Claude Code was previously logged directly into Anthropic, run `claude auth logout`
2. Start Claude Code normally with `claude`
3. Run `/status`
4. Confirm the active gateway is `https://api.gonkagate.com`
## What This Tool Does Not Do
- It does not configure `claude.ai`
- It does not install `Claude Code` itself
- It does not edit `.zshrc`, `.bashrc`, PowerShell profiles, or other shell startup files
- It does not write `.env` files
- It does not support arbitrary custom model IDs
- It does not support custom base URL overrides
## Need Help?
- Troubleshooting: [docs/troubleshooting.md](https://github.com/GonkaGate/claude-code-setup/blob/main/docs/troubleshooting.md)
- Security notes: [docs/security.md](https://github.com/GonkaGate/claude-code-setup/blob/main/docs/security.md)
- Internal behavior: [docs/how-it-works.md](https://github.com/GonkaGate/claude-code-setup/blob/main/docs/how-it-works.md)
## Development
```bash
npm install
npm run dev
```
Useful commands:
- `npm run build`
- `npm test`
- `npm run ci`