{"id":51621184,"url":"https://github.com/gonkagate/qwen-code-setup","last_synced_at":"2026-07-12T20:01:00.200Z","repository":{"id":364358396,"uuid":"1267346512","full_name":"GonkaGate/qwen-code-setup","owner":"GonkaGate","description":"Install GonkaGate for Qwen Code with one npx command. Secure setup CLI for @qwen-code/qwen-code OpenAI-compatible provider config, live model discovery, and safe API key storage.","archived":false,"fork":false,"pushed_at":"2026-07-06T23:44:06.000Z","size":378,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-07-07T01:10:59.369Z","etag":null,"topics":["ai-cli","ai-coding","ai-models","api-key","cli","coding-agent","custom-provider","developer-tools","gonkagate","llm","model-discovery","npx","openai-api","openai-compatible","qwen","qwen-code","qwen-code-cli","secure-setup","typescript"],"latest_commit_sha":null,"homepage":"https://gonkagate.com","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/GonkaGate.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"docs/security.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-06-12T13:05:36.000Z","updated_at":"2026-07-06T23:44:09.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/GonkaGate/qwen-code-setup","commit_stats":null,"previous_names":["gonkagate/qwen-code-setup"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/GonkaGate/qwen-code-setup","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GonkaGate%2Fqwen-code-setup","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GonkaGate%2Fqwen-code-setup/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GonkaGate%2Fqwen-code-setup/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GonkaGate%2Fqwen-code-setup/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GonkaGate","download_url":"https://codeload.github.com/GonkaGate/qwen-code-setup/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GonkaGate%2Fqwen-code-setup/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35401732,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-12T02:00:06.386Z","response_time":87,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai-cli","ai-coding","ai-models","api-key","cli","coding-agent","custom-provider","developer-tools","gonkagate","llm","model-discovery","npx","openai-api","openai-compatible","qwen","qwen-code","qwen-code-cli","secure-setup","typescript"],"created_at":"2026-07-12T20:00:58.973Z","updated_at":"2026-07-12T20:01:00.187Z","avatar_url":"https://github.com/GonkaGate.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Qwen Code Setup for GonkaGate\n\nConfigure Qwen Code to use GonkaGate as an OpenAI-compatible provider with one\ndeveloper-friendly `npx` command.\n\n```bash\nnpx @gonkagate/qwen-code-setup\n```\n\n![Package](https://img.shields.io/badge/package-%40gonkagate%2Fqwen--code--setup-6E63FF?style=flat-square)\n![Node](https://img.shields.io/badge/node-%3E%3D22.14.0-4DA2FF?style=flat-square)\n![Qwen%20Code](https://img.shields.io/badge/Qwen%20Code-audited%200.18.0-35D6FF?style=flat-square)\n![License](https://img.shields.io/badge/license-Apache--2.0-2A2A2A?style=flat-square)\n\n[![Website](https://img.shields.io/badge/Website-gonkagate.com-111827?style=flat-square)](https://gonkagate.com/en?utm_source=github\u0026utm_medium=referral\u0026utm_campaign=qwen_code_setup\u0026utm_content=readme_badge_website)\n[![Docs](https://img.shields.io/badge/Docs-API%20Guides-2563EB?style=flat-square)](https://gonkagate.com/en/docs?utm_source=github\u0026utm_medium=referral\u0026utm_campaign=qwen_code_setup\u0026utm_content=readme_badge_docs)\n[![API%20Key](https://img.shields.io/badge/API%20Key-Dashboard-F97316?style=flat-square)](https://gonkagate.com/en/register?utm_source=github\u0026utm_medium=referral\u0026utm_campaign=qwen_code_setup\u0026utm_content=readme_badge_api_key)\n\n`@gonkagate/qwen-code-setup` is a public CLI installer for developers who want\nQwen Code to route chat completions through the GonkaGate API without manually\nediting Qwen settings JSON.\n\n## Quick Start\n\n```bash\nnpx @gonkagate/qwen-code-setup\n```\n\nYou need:\n\n- Node.js `\u003e=22.14.0`\n- Qwen Code installed as `qwen`\n- a GonkaGate API key from the dashboard\n\nThe runtime is implemented. It writes managed Qwen Code settings after\nvalidating Qwen Code, collecting the key through safe inputs, checking the\nGonkaGate model catalog, verifying the local result, and keeping output\nredacted.\n\n## What It Does\n\nThe happy path is:\n\n1. Detects the local `qwen` binary and records its version.\n2. Collects or reuses `GONKAGATE_API_KEY` without printing the secret.\n3. Calls authenticated `GET https://api.gonkagate.com/v1/models`.\n4. Uses that live model response for defaulting, selection, and validation.\n5. Writes the GonkaGate provider into `modelProviders.openai[]`.\n6. Sets `security.auth.selectedType = \"openai\"` and `model.name`.\n7. Stores the durable key reference at `settings.env.GONKAGATE_API_KEY`.\n8. Creates backups, rolls back on failure, and reports current-session\n   environment shadowing when relevant.\n\nUse `--dry-run` to inspect planned writes before changing local Qwen Code\nsettings. Use `--json` for machine-readable, redacted output.\n\n## Supported Models\n\nThe installer has no checked-in user-facing model catalog. After collecting the\nGonkaGate API key, it calls authenticated\n`GET https://api.gonkagate.com/v1/models` and uses the returned model ids and\nnames as the source of truth for the picker, `--model` validation, default\nselection, and Qwen Code provider writes.\n\n## Known Qwen Code Baseline\n\nThe compatibility baseline is `@qwen-code/qwen-code` `0.18.0`, audited\non June 12, 2026.\n\nNewer Qwen Code versions are not blocked solely because they are newer; the\nsetup and verification checks surface actual incompatibilities.\n\nThe current Qwen Code integration points are:\n\n- binary: `qwen`\n- package: `@qwen-code/qwen-code`\n- package engine: `\u003e=22.0.0`\n- user settings: `~/.qwen/settings.json`\n- `QWEN_HOME` user settings: `\u003cQWEN_HOME\u003e/settings.json`\n- provider family: `modelProviders.openai[]`\n- auth selection: `security.auth.selectedType = \"openai\"`\n- active model selection: `model.name`\n- provider key lookup: `envKey`, resolved from Qwen Code environment loading\n- model discovery: authenticated `GET https://api.gonkagate.com/v1/models`\n  after API-key collection\n\nThe audited `0.18.0` source marks `modelProviders` with `replace` merge\nsemantics. User-scope provider catalog writes are managed in user settings.\nProject scope writes only activation settings and blocks if project\n`modelProviders` would hide user-managed providers.\n\n## Security\n\nThe installer is designed for local developer machines and keeps secrets out of\nplain command history.\n\nAllowed secret inputs:\n\n- hidden interactive prompt\n- `GONKAGATE_API_KEY`\n- `--api-key-stdin`\n\nNot allowed:\n\n- plain `--api-key`\n- shell profile mutation\n- repository-local secret storage\n\nThe v1 durable secret target is user-level\n`settings.env.GONKAGATE_API_KEY` inside the active Qwen settings file. Unlike\nOpenCode, the audited Qwen Code docs describe `envKey` and environment loading\nrather than an OpenCode-style `{file:...}` provider secret binding.\n\n## Verification And Safety\n\nDefault setup success is based on bounded local verification, not a live model\ncall. `--verify-live` is available only as an explicit opt-in and may spend\nquota or depend on provider/network availability.\n\n## Local Development\n\nInstall and run the full contract suite:\n\n```bash\nnpm ci\nnpm run ci\n```\n\nUseful focused checks:\n\n```bash\nnpm run build\nnpm run typecheck\nnpm run test\nnpm run format:check\nnpm run package:check\nnpm pack --dry-run\n```\n\nRun the CLI from source:\n\n```bash\nnpm run dev -- --dry-run\n```\n\n## Release Flow\n\nThis repository uses Release Please and npm trusted publishing.\n\nFor changes that should create a release, use a releasable Conventional Commit:\n\n```bash\nfeat: improve qwen code developer onboarding\n```\n\nAfter that commit lands on `main`, Release Please opens a release PR that bumps\n`package.json`, `.release-please-manifest.json`, `CHANGELOG.md`, and\n`src/constants/contract.ts`. When that release PR is merged, GitHub Actions\npublishes to npm with provenance.\n\nUse `fix:` for patch releases and `feat:` for minor releases. Non-releasable\ncommits such as `docs:` are useful for internal cleanup, but they should not be\nused when the change is intentionally testing the release pipeline.\n\n## Docs\n\n- [Product spec](docs/specs/qwen-code-setup-prd/spec.md)\n- [How it works](docs/how-it-works.md)\n- [Security](docs/security.md)\n- [Model validation](docs/model-validation.md)\n- [Architecture decisions](docs/architecture-decisions.md)\n- [Troubleshooting](docs/troubleshooting.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgonkagate%2Fqwen-code-setup","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgonkagate%2Fqwen-code-setup","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgonkagate%2Fqwen-code-setup/lists"}