---
title: "Options and exit codes"
description: "Every flag the CLI accepts and what its exit codes mean for scripts."
url: https://docs.spinrun.ai/cli/options
markdown_url: https://docs.spinrun.ai/cli/options.md
---

# Options and exit codes

{/* GENERATED from @spinrun/cli/commands.ts — do not edit by hand. */}

* `-d, --data <json>` — arguments for execute; use "-" to read stdin
* `--data-file <p>` — arguments from a file
* `--file <p>` — a document for validate/put (default: stdin)
* `--prompt <text>` — the prompt for agent test
* `--force` — put/delete: allow webhook triggers to be removed
* `--json` — print \{"data": …} or \{"error": …} instead of text
* `-n, --limit <n>` — how many rows (logs, search)
* `-f, --follow` — keep polling for new activity
* `--config-path <p>` — override where install writes
* `--with-key <key>` — install with an API key instead of browser auth
* `--build` — install/gateway: the Build endpoint (OAuth only)
* `--refresh` — ignore the cached tool list
* `-h, --help` — this text
* `-v, --version` — version

## Exit codes [#exit-codes]

* `0` — ok.
* `1` — this program or the network: a bad flag, an unreadable file, a document over 64 KiB (checked before anything is sent), or `agent test` giving up after five minutes while the run continues on the server.
* `2` — the server refused, including a 409; with `--json` the body is `{"error", "current", "applied"}`.

## Related [#related]

* [CLI](https://docs.spinrun.ai/cli.md)
