01Run it
Replace the <placeholders> with your own values, or use the builder below.
p202 forecast-event list02What you get
Captured from the real binary, run against a demo store with 30 days of traffic. Switch tabs to see the same run as JSON, the shape scripts and agents parse.
$ p202 forecast-event list end_date etag event_date event_id event_name expected_impact_pct impact_type lag_days lead_days notes recurrence tags user_id version -------- ------------------------------------------ ---------- -------- -------------------- ------------------- ----------- -------- --------- ----- ---------- -------------- ------- ---------------------------------------- "f1dad47a8133a438c049115eaf2fefe8295d4dd3" 2026-11-27 1 Black Friday Weekend 180 boost 0 0 none retail,holiday 1 f1dad47a8133a438c049115eaf2fefe8295d4dd3 Total: 1 | Limit: 50 | Offset: 0
$ p202 forecast-event list --json { "data": [ { "end_date": null, "etag": "\"f1dad47a8133a438c049115eaf2fefe8295d4dd3\"", "event_date": "2026-11-27", "event_id": 1, "event_name": "Black Friday Weekend", "expected_impact_pct": 180, "impact_type": "boost", "lag_days": 0, "lead_days": 0, "notes": null, "recurrence": "none", "tags": "retail,holiday", "user_id": 1, "version": "f1dad47a8133a438c049115eaf2fefe8295d4dd3" } ], "pagination": { "cursor": null, "cursor_expires_at": null, "limit": 50, "offset": 0, "total": 1 } }
03Build your command
Pick values and the command line writes itself, quoted and ready to paste.
p202 forecast-event listSet flags below; the command updates as you type.
04Flags
8 flags, plus the global flags every command takes.
| Flag | What it does |
|---|---|
| --allbool | Fetch all rows across pages |
| --event-namestring | Filter by event name |
| --limit, -lstring | Max results |
| --offset, -ostring | Pagination offset |
| --pagestring | Page number |
| --recurrencestring | Filter by recurrence type: none, monthly, yearly, customnonemonthlyyearlycustom |
| --resolve-namesbool | Resolve foreign key IDs to names |
| --tagsstring | Filter by tag |
05For agents
Running this from an agent
- Read the same facts as JSON:
p202 commands forecast-event list --json. - With
AI_AGENT,CLAUDECODEor another agent variable set, output is compact JSON and errors arrive on stderr as a JSON envelope with ahint. - Exit codes: 0 ok, 1 bad input, 2 auth, 3 network, 4 server error, 5 partial failure.
{
"path": "p202 forecast-event list",
"use": "list",
"short": "List forecast events (holidays, promotions, anomalies that affect forecasting)",
"runnable": true,
"flags": [
{
"name": "all",
"type": "bool",
"default": "false",
"usage": "Fetch all rows across pages",
"required": false
},
{
"name": "event-name",
"type": "string",
"default": "",
"usage": "Filter by event name",
"required": false
},
{
"name": "limit",
"shorthand": "l",
"type": "string",
"default": "",
"usage": "Max results",
"required": false
},
{
"name": "offset",
"shorthand": "o",
"type": "string",
"default": "",
"usage": "Pagination offset",
"required": false
},
{
"name": "page",
"type": "string",
"default": "",
"usage": "Page number",
"required": false
},
{
"name": "recurrence",
"type": "string",
"default": "",
"usage": "Filter by recurrence type: none, monthly, yearly, custom",
"allowed_values": [
"none",
"monthly",
"yearly",
"custom"
],
"required": false
},
{
"name": "resolve-names",
"type": "bool",
"default": "false",
"usage": "Resolve foreign key IDs to names",
"required": false
},
{
"name": "tags",
"type": "string",
"default": "",
"usage": "Filter by tag",
"required": false
}
]
}