VanaAPI

← Writing

One key in two terminal coding sessions

Agents at the terminalEN2026-10-29

Keeping Claude Code and Codex available does not have to mean maintaining two separate provider balances. Vana API can supply both tools through one account and one API key. The useful distinction is that the credential can be shared while the clients, protocols, and working habits remain separate.

This is a comparison of that arrangement: what changes in each tool, what stays common, and where a shared key should not be mistaken for a shared session.

§ The same credential, different connections

Claude Code: The relevant connection is the Anthropic Messages protocol. Vana API supports that protocol, so Claude Code can connect through the gateway rather than requiring an OpenAI-shaped translation in your own code. Configure the client’s supported custom-provider settings with the Vana endpoint and credential.

Codex: The relevant connection is its configurable model-provider interface. Point the provider configuration at Vana API and supply the same credential through the authentication mechanism supported by your installed version. Check the required wire protocol as well as the base URL; OpenAI compatibility alone does not establish support for every endpoint a client might request.

Shared detail: The gateway is https://api.vanaapi.com. Follow the current Vana API and client instructions for the complete base path, authentication fields, and supported protocol. Do not assume that copying one tool’s configuration into the other will work unchanged.

§ Separate model choices

Claude Code: A model such as Claude Sonnet 5.5 is a natural choice to investigate for a Claude-oriented workflow. Use the exact model identifier documented by Vana API, rather than assuming the display name is a valid configuration value.

Codex: A model such as GPT-6.1 Sol is a separate selection, not something implied by reusing the key. Confirm that the selected model and route support the features your Codex version needs, particularly tool calls and streaming.

The common account does not make models interchangeable. Context limits, response behavior, supported parameters, and tool handling can differ. Start with a small repository task in each client before trusting either configuration with a long, unattended run.

§ One balance, two sources of usage

Claude Code: Repository inspection, repeated edits, and follow-up checks can generate multiple requests during what looks like a single task.

Codex: Planning, command execution, and revision loops can likewise produce more usage than the initial prompt suggests. A short instruction is not necessarily a short session.

Vana API bills per real token with no monthly fee. Both clients therefore draw on the same account’s usage budget when they use that credential. This simplifies funding, but it does not guarantee identical costs: model rates and the amount of context sent still matter. Compare completed tasks and recorded usage, not just prompt length.

§ Shared access, separate safety boundaries

Claude Code: Keep its repository permissions, command approvals, and local instructions configured deliberately.

Codex: Review its sandbox and approval settings independently. Settings in one client do not protect the other.

The API key authorizes API access; it does not synchronize conversations, repository state, permissions, or task history. Store it outside committed files, avoid printing it in diagnostic output, and remember that rotating a shared credential requires updating both clients. For teammates or automated jobs, separate credentials are preferable where available, because they make revocation and attribution easier.

§ A small first check

Create a Vana API account, then connect one client at a time. Ask each to inspect a small file and propose a limited change. Confirm authentication, model selection, streaming, and tool behavior before expanding the task.

The practical benefit is modest but clear: one place to fund access, with two independently configured coding tools. Keep that boundary visible, and sharing the key can reduce account administration without obscuring how each session actually works.