p202 attribution export

Attribution exports: a breakdown written to CSV by the export runner, downloadable and optionally sent to an https webhook

All commands

01How it works

An export is a job: the export runner (the minutely cron) builds the breakdown it names, writes every group to a CSV file, and, when the export has a webhook, POSTs the file there, signed with HMAC-SHA256 (X-P202-Signature: sha256=<hex> over "<X-P202-Timestamp>.<body>").

Webhooks go to https URLs on public addresses only: every address the host resolves to is checked, the connection is pinned to the checked address, and redirects are not followed.

02Commands

6 under p202 attribution export.

03For agents

Running this from an agent

  • Read the same facts as JSON: p202 commands attribution export --json.
  • With AI_AGENT, CLAUDECODE or another agent variable set, output is compact JSON and errors arrive on stderr as a JSON envelope with a hint.
  • Exit codes: 0 ok, 1 bad input, 2 auth, 3 network, 4 server error, 5 partial failure.
p202 commands attribution export --json
{
  "path": "p202 attribution export",
  "use": "export",
  "short": "Attribution exports: a breakdown written to CSV by the export runner, downloadable and optionally sent to an https webhook",
  "long": "An export is a job: the export runner (the minutely cron) builds the breakdown it names,\nwrites every group to a CSV file, and, when the export has a webhook, POSTs the file there,\nsigned with HMAC-SHA256 (X-P202-Signature: sha256=<hex> over \"<X-P202-Timestamp>.<body>\").\n\nWebhooks go to https URLs on public addresses only: every address the host resolves to is\nchecked, the connection is pinned to the checked address, and redirects are not followed.",
  "runnable": false
}