Перейти к основному содержимому

Licence server: billing engine error codes (LIC-BILLING-*)

Answered by the billing engine of the licence server (subscriptions and renewals held by the licence server, Stripe only charges; plan: billing-engine.md, guide: billing-engine.md) as application/problem+json (type, title, status, code). The routes that use the engine (purchases, plan changes, cancel, pay now, update card) add their own refusals (session, CSRF, rate limits).

CodeStatusWhereMeaningWhat to do
LIC-BILLING-OFF503every engine call[billing] enabled = false, or Stripe is not configured.Turn the engine on (operator).
LIC-BILLING-NOT-FOUND404change, cancel, resume, pay nowNo such subscription (or not the caller's).Reload the list.
LIC-BILLING-STATE409change, cancel, resume, pay nowNot possible in the current status (for example an increase while past due, resume after the period ended, pay now with nothing owed).Pay what is owed first, or start a new purchase.
LIC-BILLING-EXISTS409purchaseThe item already has a running subscription.Change that subscription instead.
LIC-BILLING-DECLINED402purchase with the saved card, increaseThe card was declined; nothing changed.Update the card and try again.
LIC-PRECONDITION-FAILED412change, cancel, resumeThe subscription changed since it was read (version / If-Match).Reload it and try again.
LIC-PAYMENT-CURRENCY422purchaseOXXO or SPEI in a currency other than Mexican pesos.Pay by card, or buy in MXN.
LIC-STRIPE-UNAVAILABLE502every call that reaches StripeStripe did not answer; nothing was charged twice (each charge has its own idempotency key).Try again later.
LIC-BILLING-NO-CARD409phone-number order (POST /v1/voice/accounts/{company}/dids/orders)The engine charges each number's fee to the card on file, and the account has none.Add a card on the account page, then order again.
LIC-BILLING-ACTION-REQUIRED402voice bundle and Global eSIM bundle purchase or change (problem with manage_url)The bank asks the customer to confirm the payment; manage_url is the hosted page. The product starts (or the change applies) when it is paid.Open the page and confirm the payment.

The licence checkout (POST /v1/checkout, POST /v1/portal/checkout) answers with the engine as before (url of the page to pay on, the OXXO voucher or the SPEI instructions), plus subscription, paid and trial_days. A coupon that is not usable is LIC-COUPON-INVALID (422) as before; the engine computes the discount itself (no Stripe coupon).