@andreasink/reportkit
v0.1.3
Published
CLI for login, simple Live Activity sends, and workflow-triggered sending.
Readme
ReportKit CLI
ReportKit Beta puts important app and ops signals into an iPhone Live Activity from the command line.
Minimal ReportKit CLI for:
- signing the CLI into Supabase
- sharing the same account as the iPhone app
- sending Live Activity updates from the terminal or external workflows
- inspecting and updating saved widget builder config
- minting cloud-agent publish tokens for Cursor/Codex/ChatGPT-hosted agents
- sending alarm-only pushes through the same authenticated backend
Install
npm install -g @andreasink/reportkitThe published CLI includes the hosted ReportKit beta Supabase URL and publishable key. To point it at another ReportKit-compatible Supabase project, override them with env vars or ~/.reportkit/.env:
export REPORTKIT_SUPABASE_URL=https://YOUR_PROJECT.supabase.co
export REPORTKIT_SUPABASE_ANON_KEY=YOUR_PUBLISHABLE_KEYREPORTKIT_SUPABASE_URL must start with https://.
Commands
reportkit auth --email [email protected]
reportkit status
reportkit agent-token create --name "Cursor Cloud" --json
reportkit agent-token list
reportkit agent-token revoke --id TOKEN_ID
reportkit widget list
reportkit widget update --id WIDGET_ID --accent-hex '#3366CC' --glass-opacity 0.62
reportkit widget update --id WIDGET_ID --template builder --builder-spec-file builder-spec.json
reportkit send --event update --activity-id daily-report --title "Revenue watch" --summary "Down 8% vs yesterday" --status warning
reportkit send --file agent-progress.json
reportkit send --file builder-live-activity.json
reportkit send --agent-token "$REPORTKIT_AGENT_TOKEN" --file agent-progress.json
reportkit alarm --title "Review log watch" --in-seconds 60
reportkit logout
reportkit skill print --target codex
reportkit skill print --target claude
reportkit skill print --target cursorFor cloud agents, create a token locally and store it in the provider's secret environment:
reportkit agent-token create --name "Codex Cloud" --json
export REPORTKIT_AGENT_TOKEN=rk_agent_...Cloud agent tokens are publish-only credentials. They let hosted agents run reportkit send without copying your local session store or Supabase password. They cannot upload iOS tokens, manage tokens, or send alarm pushes.
Widgets
reportkit widget list shows saved widget config plus the server-side widget quota:
Plan: Free (1/1 widgets)
de7f29d5-e499-42a9-99ba-b31f8c69e261 Test builder #DB3D29 glass 0.82Widget creation and limits are enforced by the hosted endpoint. Missing entitlement rows are treated as Free with one widget. Pro access is stored in reportkit_user_entitlements and can raise widget_limit.
Use reportkit widget update to change appearance and builder layout config. Do not provide endpoint_url; the endpoint is derived internally from the configured Supabase project.
Live Activity sends are also quota-gated server-side. Free accounts get two sends per UTC day. Pro entitlement bypasses the daily send limit. When the limit is reached, the send endpoint returns HTTP 402 with live_activity_daily_limit_reached, and the CLI prints an upgrade-oriented error.
Example agent-progress.json:
{
"event": "update",
"activityId": "codex-agent",
"payload": {
"generatedAt": 1774000000,
"title": "Ship Agent Progress Template",
"summary": "Updated the widget payload schema and now wiring the Dynamic Island progress bar.",
"status": "warning",
"template": "agent",
"sourceName": "Codex",
"sourceIcon": "terminal.fill",
"primaryLabel": "Implementation",
"primaryValue": "68%",
"primaryDelta": "active",
"secondaryLabel": "Steps",
"secondaryValue": "17/25",
"footer": "Wiring the Dynamic Island progress bar.",
"progressPercent": 68,
"completedSteps": 17,
"totalSteps": 25
}
}Example builder sends should use file mode because builder payloads include a nested JSON-to-SwiftUI layout DSL:
{
"event": "start",
"activityId": "builder-demo",
"payload": {
"generatedAt": 1778540400,
"title": "Revenue Console",
"summary": "MRR and conversion need attention.",
"status": "warning",
"template": "builder",
"builderSpec": {
"version": 1,
"surfaces": {
"lockScreen": {
"type": "vstack",
"children": [
{ "type": "text", "text": { "path": "headline" }, "role": "title" },
{ "type": "metric", "label": "MRR", "value": { "path": "mrr" }, "delta": { "path": "mrrDelta" } }
]
},
"compact": {
"type": "hstack",
"children": [
{ "type": "text", "text": { "path": "mrr" }, "role": "value" },
{ "type": "statusDot" }
]
},
"minimal": { "type": "statusDot" }
}
},
"data": {
"headline": "Revenue dipped after paywall change",
"mrr": "$18.2k",
"mrrDelta": "-8%"
}
}
}For local development, see the repo root README.
