Read the workspace subscription and entitlements
Returns the workspace's current subscription record together with the entitlements derived from it. Requires a Clerk session and the `billing:read` workspace permission; API keys cannot call it.
apiKeyAuthorizationBearer <snoze_sk_…>Workspace API key created in Workspace settings → API keys. Scopes on the key bound what it can read and write.
workspaceId*stringSuccess
application/json- response
data*curl -X GET 'https://api.snoze.dev/v1/workspaces/string/billing/subscription'{ "data": { "subscription": { "workspaceId": "string", "plan": "free", "status": "none", "polarCustomerId": "string", "polarSubscriptionId": "string", "polarProductId": "string", "cancelAtPeriodEnd": true, "currentPeriodStart": "string", "recurringInterval": "month", "currentPeriodEnd": "string", "scheduledChange": { "plan": "free", "interval": "month", "effectiveAt": "string" } }, "entitlements": { "plan": "free", "status": "none", "maxEditorSeats": 0, "maxRecords": 0, "maxAutomationRunsPerMonth": 0, "maxAutomations": 0, "maxDashboards": 0, "maxForms": 0, "maxStorageBytes": 0, "historyRetentionDays": 0, "features": [ "string" ] } }}Prepare a workspace billing PDF
Returns a fresh receipt or invoice PDF URL, generating an invoice when needed. Requires billing:read; the order must belong to this exact workspace. Send an Idempotency-Key for retries.
Read the plan catalog with the workspace's current plan
Returns the purchasable plan catalog plus the workspace's effective plan and subscription status. Any workspace member with a Clerk session and a synced profile may call it, so members see only the effective plan rather than the full subscription record. If a pricing experiment is running the caller's deterministic variant selects the catalog and the exposure is recorded.