Skip to main content
Every command reports success or failure through its exit code. Scripts and CI jobs should branch on the exit code, not on the text a command prints.

Exit codes

A tool that reports an error during graph tool test --json still exits 0: the call completed, and the result’s isError field says the tool failed.

Output streams

stdout carries only the command’s result: an answer, a plan’s output, a listing, or a --json envelope. Progress, warnings and error messages go to stderr. When graph refuses a request, such as an invalid plan or a rejected edit, --json still prints the envelope describing why to stdout before exiting 1. Other failures are reported on stderr only.

Machine-readable output and logs

enum<string>
How graph reports progress and failures on stderr. Unset, stderr is for people.
string
A log filter for stderr, such as info or graph=debug. -v, -vv and -vvv set info, debug and trace.
Go to full reference