Docs
Billing ›

Create billing portal

POST/v1/billing/portal

Create billing portal.

Requestcurl
  1. curl -X POST https://agental.io/v1/billing/portal \
  2. -H "Authorization: Bearer $AGENTAL_API_KEY"
Answer200 OK
  1. {
  2. "url": string,
  3. }

Where the account sees its invoices, changes its card, and cancels its plan.

Headers

Authorizationrequired
Bearer key
An API key that may make this call.

Returns

200 Where the account sees its invoices, changes its card, and cancels its plan.

JSON1 field
url
string

Errors and other answers

409 billing_not_configured, or
409nothing_bought the account has not bought anything yet.

Every error answers { "error": { "code", "message" } }; a key without the action a call needs answers 403 key_action_forbidden, naming it.