cURL
curl --request POST \ --url https://api.usezombie.com/v1/workspaces/{workspace_id}/billing/events \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "event_type": "PAYMENT_FAILED", "reason": "<string>" } '
{ "workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a", "billing_status": "<string>", "request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a" }
Records a billing lifecycle event such as a payment failure or downgrade. The workspace’s billing status is updated accordingly.
Obtain a token via the CLI auth flow (POST /v1/auth/sessions) or GitHub OAuth
Workspace identifier
Type of billing event
PAYMENT_FAILED
DOWNGRADE_TO_FREE
Human-readable reason for the event
Billing event recorded
Updated billing status