Kubb Studio
Kubb Studio is a browser workspace for generating and reviewing TypeScript code from an OpenAPI spec. It runs your Kubb plugins to produce types, clients, schemas, and hooks, shows file changes, and can publish installable snapshots from CI.
Choose where generation runs:
| Option | Use it for |
|---|---|
| Shared sandbox | Try Studio with a spec you provide in the browser, without installing anything. |
kubb studio | Work on a local project with its existing spec, config, and plugin versions. |
| Docker agent | Keep an agent connected on your infrastructure for a team. |
With a CLI or Docker agent, generation runs in your environment. Studio receives plugin settings, progress, and generated file paths. A local spec is not uploaded. Reading generated file contents or changing local files requires the agent's permission. The shared sandbox runs outside your environment, so use it with a spec you are comfortable providing there.
Kubb Studio
From spec to production.
Generate typed clients, review every change, and automate your OpenAPI workflow from local development to CI. Your code stays on your infrastructure.
Connect a local project
Run the command from a project with Kubb installed and a kubb.config.ts:
kubb studioThe first run opens Studio to approve the machine. After approval, keep the command running and select the connected agent in Studio. Generate from the browser to see progress and the file tree. Grant --allow-read to view file contents and diffs.
The CLI asks which permissions to grant for this project and remembers your answers. With no permissions granted, generation uses memory and Studio sees file paths and progress. It does not write generated files or edit your config. For example, to review generated files and write them to disk:
kubb studio --allow-read --allow-writeUse --allow-config-edit to save plugin option changes to kubb.config.ts. Use --allow-input to generate from a spec supplied in Studio instead of the project's spec. Use --allow-exec to run the configured formatter, linter, and output.postGenerate commands. See the kubb studio reference for all flags and actions.
Run an agent without a terminal session
For a long-running team connection, run the Docker agent. You can also run the CLI without a TTY using an existing agent token:
KUBB_AGENT_TOKEN=your-agent-token kubb studio --allow-readHeadless runs do not ask permission questions. Pass the permissions the run needs as flags. kubb studio status shows the current machine's pairing and saved project permissions. kubb studio logout forgets its token.
Snapshot from CI
kubb studio snapshot generates an installable package on a CI runner, publishes the tarball to Studio, and exits. It uses an organization CI API key in KUBB_TOKEN, not an agent token:
kubb studio snapshotThe command detects GitHub Actions, GitLab CI, Bitbucket Pipelines, and CircleCI. For another CI provider, pass a stable --id. Use --json when a later step needs the tarball URL:
kubb studio snapshot --json | jq -r '.url'Follow the GitHub Actions or GitLab CI guide for a complete workflow. Installing the tarball requires a separate registry API key.
See also
kubb studiocommand: actions, flags, and environment variables- Configuration: the config a connected project uses