> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dagraph.app/llms.txt
> Use this file to discover all available pages before exploring further.

# agentgraph CLI reference: all 11 commands explained

> Full reference for all agentgraph CLI commands: run, validate, inspect, approve, respond, list, resume, graph, diff, serve, and schedule.

The `agentgraph` CLI is the primary way to execute, inspect, and manage dagraph workflows from your terminal. Every command operates on plain YAML files and local run directories — no hosted platform required. Install the engine package and you have the full CLI immediately.

```bash theme={null}
pip install dagraph
```

For `serve` and `schedule` commands, install the optional extras:

```bash theme={null}
pip install 'dagraph[serve]'
```

## Commands

| Command                           | What it does                                                              |
| --------------------------------- | ------------------------------------------------------------------------- |
| [`run`](/cli/run)                 | Execute a DAG from start to finish, or resume a previous run              |
| [`validate`](/cli/validate)       | Parse a DAG YAML, check graph structure, and show the execution wave plan |
| [`inspect`](/cli/inspect)         | View node statuses and artifact contents for a completed or partial run   |
| [`approve`](/cli/approve-respond) | Approve or reject a paused `approval_gate` node                           |
| [`respond`](/cli/approve-respond) | Provide a value to a paused `user_input` node                             |
| [`list`](/cli/list-resume)        | Show all past runs with status, DAG name, and node summary                |
| [`resume`](/cli/list-resume)      | Resume a paused or partial run from where it left off                     |
| [`graph`](/cli/graph-diff)        | Render a DAG as Mermaid or Graphviz output                                |
| [`diff`](/cli/graph-diff)         | Compare node artifacts between two runs of the same DAG                   |
| [`serve`](/cli/serve-schedule)    | Start a long-running webhook server that triggers runs on POST requests   |
| [`schedule`](/cli/serve-schedule) | Run a DAG on a repeating cron schedule                                    |

## Global conventions

All commands accept a `--runs-dir` flag to point at a custom runs directory (default: `runs/` relative to your working directory). Run IDs are 12-character hex strings generated automatically; pass `--run-id` to `run` or `resume` to use a specific value.

<CardGroup cols={2}>
  <Card title="run" icon="play" href="/cli/run">
    Execute a DAG end-to-end with full backend and sandbox control.
  </Card>

  <Card title="validate" icon="circle-check" href="/cli/validate">
    Catch YAML errors and undefined template variables before you run.
  </Card>

  <Card title="inspect" icon="magnifying-glass" href="/cli/inspect">
    Browse node statuses, artifact digests, and full output content.
  </Card>

  <Card title="approve & respond" icon="user-check" href="/cli/approve-respond">
    Unblock paused HITL gates and user-input nodes.
  </Card>

  <Card title="list & resume" icon="list" href="/cli/list-resume">
    Audit all past runs and resume interrupted ones.
  </Card>

  <Card title="graph & diff" icon="diagram-project" href="/cli/graph-diff">
    Visualize DAG structure and compare run outputs.
  </Card>

  <Card title="serve & schedule" icon="clock" href="/cli/serve-schedule">
    Trigger workflows via webhook or cron schedule.
  </Card>
</CardGroup>
