# `jadpo trace`

Show what one request did.

Shows one request's timeline from what `jadpo dev` keeps on this machine (area 17): the route and the caller, each action, query and write with its time, its rows and its SQL with placeholders, each provider call with what was sent and what came back, each step's state, the failure and where it was raised, and the outcome: committed or rolled back, the events emitted and the subscribers they ran. It takes any start of a request's id or its trace's id, or the id of a failed test's trace `jadpo test --keep-failed` kept. A parameter is shown as a value, or text as its keyed hash; `--full` shows each statement and value whole.

```text
jadpo trace <id>
```

## Arguments

- `id`: The request's id, its trace's, or a kept test trace's

## Flags

- `--full`: Show each statement and value whole

## On every command

- `--json`: Print data for tools instead of text
- `--full`: Show everything a report shortens
- `--help`: Show every flag, with examples
- `--color <when>`: Choose when to use colour

`jadpo trace --json` writes one JSON document to standard output instead of text, with the same exit code. The document has `schemaVersion`, `command` (`"trace"`), `ok`, `data` (what the command produced, `null` when it failed) and `diagnostics` (each error with its `rule`, `reason`, `next` and `help`). A command that needs a terminal refuses `--json` and names the flags that do the same job.

## Examples

```text
# See what a request did
jadpo trace req_0b1e
# See a failed test's kept trace
jadpo trace t-7f3a9c1e
```

## Errors

- [`cli.trace_arguments`](/docs/errors/cli.trace_arguments.md): A `jadpo trace` command is given no id, or one no kept timeline has, or the start of several requests' ids
- [`toolchain.project_not_found`](/docs/errors/toolchain.project_not_found.md): You ran a command that works on a project in a folder with no `app.jadpo`, in it or in any folder above it
