# The kazocode-sdk command

> Use the kazocode-sdk command to scaffold extensions, plugins, mods and marketplaces, validate an add-on against the marketplace rules, and run the KazoCode agent from a terminal.

`kazocode-sdk` comes with [`@kazocode/sdk`](https://kazocode.app/docs/sdk/overview.md). Run it with `npx kazocode-sdk`, or install the package globally.

## Commands

```sh
npx kazocode-sdk new <extension|plugin|mod|marketplace> <name> [--publisher <id>] [--dir <folder>]
npx kazocode-sdk validate [folder]
npx kazocode-sdk run "fix the failing test" [--provider anthropic|openai|openrouter|groq|ollama] [--model <id>] [--mode acceptEdits]
```

### new

Starts an add-on from a template.

| Template | Creates |
| --- | --- |
| `extension` | A TypeScript [extension](https://kazocode.app/docs/sdk/extensions.md) with a command |
| `plugin` | A [plugin](https://kazocode.app/docs/sdk/plugins.md) with a skill, a command, a sub-agent and hooks |
| `mod` | A [mod](https://kazocode.app/docs/sdk/plugins.md#mods) file |
| `marketplace` | A repository layout with `.kazocode/marketplace.json` |

### validate

Checks an add-on with the marketplace's rules: `id` is `publisher.name` in lower case, `version` is semantic, the main script exists, and there are at most 300 text files, 512 KB each and 4 MB in total.

### run

Runs the agent in the current folder and streams its answer to the terminal. In the `default` permission mode it asks before each edit or command. The provider reads its usual API key variable, such as `ANTHROPIC_API_KEY` or `OPENAI_API_KEY`.

```sh
ANTHROPIC_API_KEY=sk-ant-… npx kazocode-sdk run "add input validation to the signup form" --mode acceptEdits
```
