Agents

The agents a cloud workspace can run, how they get your model credentials, and how to give them saved configuration.

View as markdown

A cloud workspace runs one agent: OpenCode, or T3 Code (which drives Codex and Claude Code). Read this page to pick an agent, give it model credentials, and set config that every new workspace gets.

Pick an agent

AgentKeyWhat you getConnect with
OpenCodeopencodeA remote OpenCode serverLocal TUI, OpenCode desktop app, or the OpenCode web app in your browser
OpenCode (TTYD)opencode-ttydThe OpenCode TUI in a browser terminalYour browser, no local client
T3 Codet3codeA T3 Code server that runs Claude Code, Codex, and OpenCodeThe T3 Code web or desktop app, through a one-time pairing link

In the dashboard, pick the agent under Agent when you create a workspace. In the SDK, pass the key as agent to client.workspaces.create(); the default is opencode.

Every workspace runs OpenCode 2 (the @opencode/cli package), including inside T3 Code.

What each agent supports

FeatureOpenCodeT3 Code
SDK runs (client.runs.*)YesNo
Slack and Discord botsYesNo
MCP connections from GittermYesNo
/cloud and /cloud-returnYesNo
Saved agent configOpenCodeOpenCode, Claude Code, Codex

T3 Code sessions don't move to the cloud. To use Codex or Claude Code in the cloud, create a T3 Code workspace and start a new thread there. See Move a session to the cloud.

Model credentials

Workspaces run on your own model keys and subscriptions. Add them under Models in the dashboard.

  • API keys: Anthropic, OpenAI, Google AI, OpenRouter, xAI, OpenCode Zen, and many more.
  • Subscriptions: ChatGPT (shown as Codex), OpenCode Console, GitHub Copilot, and SuperGrok. Connect these in the dashboard; the SDK can't add them.

Each credential has a label, and each provider has one default credential. A workspace created without a models choice gets every saved credential, under its dashboard label, with each provider's default selected. Inside the workspace, opencode auth switch changes the active account.

Choose credentials from the SDK

Pass models to client.workspaces.create():

TypeScript
await client.workspaces.create({
  repo: "https://github.com/acme/product",
  models: {
    default: "anthropic/<model-id>",
    inherit: "none", // only the providers listed here get credentials
    providers: {
      anthropic: { source: "default" },
      openai: { source: "saved", label: "work" },
      google: { source: "apiKey", apiKey: process.env.GOOGLE_API_KEY! },
    },
  },
});

<model-id> is the model's id at that provider.

FieldRequiredDefaultWhat it does
defaultNoNoneThe workspace's default model, as provider/model
inheritNononenone: only listed providers get credentials. defaults: also every unlisted provider's saved credentials
providersNoNoneOne credential source per provider key, from the table below
SourceMeaning
{ source: "default" }The provider's default saved credential
{ source: "saved", label }A saved credential, by its dashboard label
{ source: "apiKey", apiKey }A key for this workspace only. It is not saved in Gitterm

Use the provider key openai for both OpenAI API keys and ChatGPT subscriptions.

How subscriptions are refreshed

Subscriptions that rotate refresh tokens (ChatGPT, OpenCode Console, SuperGrok) stay encrypted in Gitterm. A workspace gets a short-lived access token and asks Gitterm for a new one when it expires. Several workspaces can share one account without signing each other out.

In T3 Code, Claude Code and Codex use their own sign-in, and Gitterm does not refresh it. For long-lived or multi-workspace use, prefer API keys, or sign in separately in T3 Code's provider settings. If an older saved ChatGPT credential fails in T3 Code, reconnect it under Models.

Saved agent config

Save config once under Settings → Agent defaults and every new workspace of the matching agent gets it. Existing workspaces keep the config they were created with.

ConfigApplies toWritten to
OpenCodeOpenCode and T3 Code workspaces~/.config/opencode/opencode.json
Claude CodeT3 Code workspaces~/.claude/settings.json
CodexT3 Code workspaces~/.codex/config.toml

You write each config as JSON. Gitterm converts Codex config to TOML. Examples:

JSON
{
  "$schema": "https://opencode.ai/config.json",
  "theme": "opencode",
  "update": "notify"
}
JSON
{
  "permissions": {
    "allow": ["Bash(git *)", "Read", "Edit"]
  }
}

Commit attribution

The same page has the switch Attribute GitTerm for commits made in workspaces. It is on by default: you are the commit author and Gitterm is the committer. Turn it off to be both. It applies to new workspaces.

Per-workspace OpenCode settings from the SDK

TypeScript
await client.workspaces.create({
  repo: "https://github.com/acme/product",
  opencode: {
    config: { permission: { edit: "allow", bash: "allow" } }, // merged over your saved config
    plugins: ["@acme/[email protected]"],
    skills: [{ name: "release-demo", content: releaseDemoSkillMarkdown }], // a SKILL.md body
  },
  additionalAgentInstructions: "Keep answers short.",
});

additionalAgentInstructions is appended to the workspace's global AGENTS.md. Put project knowledge in an AGENTS.md in the repository instead; the agent reads it on its own.