Client Integrations
Point AI coding clients at a Nexus gateway for model traffic using gateway API keys
Point AI coding clients at a Nexus gateway for model traffic.
These guides cover gateway API keys (nxs_…) and base-URL swaps only.
They do not cover personal developer keys (nxd_…) or Query HTTP; those are separate observability credentials — see Personal Developer Keys.
Guides
Section titled “Guides”| Client | Edge | Guide |
|---|---|---|
| OpenCode | OpenAI-compatible /v1 |
OpenCode → Nexus |
| Cline (VS Code) | OpenAI-compatible /v1 |
Cline (VS Code) → Nexus |
| Continue (VS Code) | OpenAI-compatible /v1 |
Continue (VS Code) → Nexus |
| Codex CLI | OpenAI Responses /v1 |
Codex CLI → Nexus |
| Claude Code | Anthropic Messages /anthropic |
Claude Code → Nexus |
Shared prerequisites
Section titled “Shared prerequisites”Every guide assumes:
- A reachable gateway hostname (deployed
NEXUS_HOSTNAME, or localhttp://127.0.0.1:14450— see Ports). - A gateway API key (
nxs_…) scoped to an organization and project. - A registry that already contains the model id you will select.
- Upstream credentials for that org/project (BYOK provider key and/or platform PTB lane), so the gateway can dispatch.
Mint a gateway API key
Section titled “Mint a gateway API key”Console (preferred on a deployed app): sign in → open the org/project Keys surface → issue a key → copy the nxs_… secret once.
CLI (local / operator):
TOKEN=$(just cli credentials api-keys create \ --org "$ORG_SLUG" \ --project "$PROJECT_SLUG" \ --name coding-client \ --issued-by "$(whoami)")echo "$TOKEN"Full bootstrap (user, workspace, BYOK, first chat) is in End-to-End Walkthrough.
Confirm the gateway and model catalog
Section titled “Confirm the gateway and model catalog”GATEWAY_URL="${GATEWAY_URL:-http://127.0.0.1:14450}"NEXUS_API_KEY="nxs_…"
curl -fsS "$GATEWAY_URL/healthz"curl -sS "$GATEWAY_URL/v1/models" \ -H "Authorization: Bearer $NEXUS_API_KEY" | jq .Use a model id from that list in the client.
Ids may be bare registry names (gpt-5.4-mini, claude-sonnet-4-6) or routed specs (openai/gpt-5.4-mini, anthropic/claude-sonnet-4-6), depending on how the catalog was imported.
Credential families (do not mix)
Section titled “Credential families (do not mix)”| Prefix | Use with |
|---|---|
nxs_… |
Gateway model traffic (these guides) |
nxd_… |
Query / Trace HTTP only |
Upstream provider keys (sk-…, Anthropic keys, …) |
Never send these to the Nexus edge; Nexus unwraps the stored BYOK/PTB secret itself |
Which base URL?
Section titled “Which base URL?”| Client dialect | Base URL |
|---|---|
OpenAI-compatible (/v1/chat/completions, /v1/responses, /v1/models, …) |
$GATEWAY_URL/v1 |
| Anthropic Messages (Claude Code / Anthropic SDK) | $GATEWAY_URL/anthropic |
Do not put Query, console, or auth hostnames in these fields.
Do not append /chat/completions or /messages to the base URL; clients add those paths.
Related docs
Section titled “Related docs”- Compatibility Matrix — supported routes and client status
- User Glossary — drop-in compatibility terms
- Wire Contracts — OpenAI and Anthropic edge contracts
