API / Billing

POST

/billing/downgrade

Schedule a downgrade to a smaller plan

Schedules a move to a smaller tier, effective at the next renewal. Nothing changes today and nothing is refunded: the tenant keeps the tier they paid for until the current period ends. Moving to the free tier is a cancellation, not a downgrade.

Authentification : clé API Bearer requise.

Corps JSON

Target plan

NomTypeDescription
planstringPlan is the smaller tier to move to at the next renewal.

Exemple curl

curl -X POST https://api.sporee.fr/billing/downgrade \
  -H "Authorization: Bearer $SPORE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

Réponses

StatutDescriptionType
200OKdowngrade_subscription.Result
400Bad Requestecho.HTTPError
401Unauthorizedecho.HTTPError
404no subscriptionecho.HTTPError
422not a downgrade, or use cancellation for the free tierecho.HTTPError
503billing is not configuredecho.HTTPError

Source machine : openapi.json · opération downgradeBillingSubscription