---
title: "codespar agent"
description: "Run an agent directory built on @codespar/agent-core"
---

Run an agent directory built on @codespar/agent-core

1 command in `@codespar/cli 0.13.0`.

Each one prints what its operation answered. [What a command prints](/docs/cli/reference#what-a-command-prints) has the rule, and [Configuration](/docs/cli/config#what-a-script-gets-when-a-command-fails) has the exit codes and the shape of a failure.

### `codespar agent run`

Run one turn of the agent (or its interactive terminal, without --input) via its own `npm start`

```bash
codespar agent run [options] <dir>
```

| option | what it does |
|---|---|
| `--input <text>` | One turn, no prompt — the same --input the agent's `npm start` takes |
| `--approve` | Decide the turn's execution: approve |
| `--deny` | Decide the turn's execution: deny |
