Save the team's Claude token
The team’s Claude token is a token from a Claude subscription. On a team with no model provider key, a person’s computer answers on it until that person signs in to Claude on Your computer, and from then on their agents run on their own account. On gomoe.dev the token serves only one team, so every other team reaches Claude another way.
How teams on gomoe.dev reach Claude
Section titled “How teams on gomoe.dev reach Claude”On a server with native sign-in, the setup checklist asks each team’s admin to Connect a model provider, not to set a Claude token, unless the team requires each person’s own subscription. An admin pastes a provider’s key in the Models section of the People page, after Usage and Billing, and the team’s agents reach models through the model gateway on that key. A person can also sign in to their own Claude subscription on Your computer, and a team can require that of every person.
The server-wide token is one file, so one team owns it. That team is the oldest on the server, or the team AGENTS_CLAUDE_TOKEN_TEAM names. host.ts does not set AGENTS_CLAUDE_TOKEN_TEAM, so on gomoe.dev the owner is the oldest team. Only the owner team’s computers are given the token, and not while that team requires each person’s own subscription. A session on a team with a model provider key runs through the model gateway, or on its person’s own subscription when they chose that, so it does not use the token. Every other team runs on its model keys or its people’s own sign-ins.
The built-in pipelines bug-fix, app-change and research-plan-implement run on a computer. Until the token is saved, a run of any pipeline that runs on a computer fails at once with Boxes have no Claude login yet, on every team.
Make the token
Section titled “Make the token”-
On any machine where Claude Code is installed, run this.
Terminal window claude setup-token -
Sign in when it asks, and copy the line it prints that starts with
sk-ant-oat01-. The token lasts a year.
An API key, which starts with sk-ant-api, is refused, because it bills by use.
Save the token in the app
Section titled “Save the token in the app”- Sign in as an admin of the owner team.
- Open Settings and choose Connections.
- Under Team Claude token, paste the token into the field and choose Save.
The app accepts the token alone or the whole output of claude setup-token, and it removes line breaks a terminal added. Admins of other teams see that a token is set and when it ends, but not who saved it, and the server refuses their save with a message that names the owner team.
The server checks the token before it keeps it, by running claude once on the smallest model, from an empty folder and an empty home, with the token as the only login. These are the possible answers.
- Claude refuses the token. The save stops with a message to make a new token.
- Claude works. The token is saved as checked.
- The check cannot say, because the
claudecommand is missing, Claude timed out, or Claude answered with an error unrelated to sign-in. The token is saved, and the app shows a note that it was never checked.
The server host’s first boot, ops/terraform/agents/user-data.sh, installs no claude command, so on gomoe.dev a save is expected to end in the third case. That was read from the files, not seen.
What the app shows
Section titled “What the app shows”The Team Claude token section shows the last four characters, who saved the token, and when it runs out. From 30 days before it runs out, the owner team’s admins see a warning on Home with a Set a new team token button. After it runs out, the owner team’s computers whose person has not signed in cannot answer until an admin saves a new token.
Replace or remove the token
Section titled “Replace or remove the token”- Replace the token saves a new one over the old one.
- Remove the team token deletes it. When people’s computers answer on it, the app first names up to three of them and asks you to confirm, because their agents stop answering.
Where the token is kept
Section titled “Where the token is kept”The API keeps the token in ~/.agents-app/box-claude-token of its user, which on gomoe.dev is /data/agents-app/box-claude-token on the data volume, or in the file AGENTS_BOX_TOKEN_FILE names. A second file beside it, with .meta.json added to the name, holds who saved it and when it runs out. It holds no token. The token is never in Postgres, a log or a response to a person.
How computers pick up a change
Section titled “How computers pick up a change”A computer on Fargate starts with no secret in its environment but a one-time enrollment code, since anyone who may read its task reads that environment. Once its keeper has enrolled, its daemon asks the machine port for the token. A running computer asks the server before each message that starts or reaches a Claude session, and takes the new token when the team’s has changed. A turn in progress keeps the token it started with. A person’s Mac is never given the token, since it signs in to Claude on its own.