billing.subscribe
Subscribe to a plan.
Reference
POST/api/v1/billing/plan
- Auth
- API key in
X-API-Key - Content
- application/json
- Returns
- 200 · Response Subscribe To Plan Api V1 Billing Plan Post
Start the starter plan, and hand back the link where it is authorised. Nothing is collected here and no balance is granted here. The first cycle is collected by the customer's bank when it falls due, and the balance arrives with it — see ``services/billing/plans.py``. Idempotent for the same reason the rental mandate is: a customer who closes the authorisation page and comes back must not end up with two banks collecting for one plan.
Arguments
This method takes no arguments.
Example request
curl -X POST "https://api.decibyl.ai/api/v1/billing/plan" \
-H "X-API-Key: dcb_your_key" \
-H "Content-Type: application/json" \
-d '{"plan_code":"string","period":"monthly","promo_code":"string"}'Response
{}Errors
| Status | When |
|---|---|
404 | Not found |
422 | Validation Error |