Billing
Overdue ladder
What happens, step by step, when an invoice is not paid — and how to keep it safe.
🪜 How the ladder works
Instead of switching a site off the moment a payment is late, Orchestrator climbs a graduated ladder: reminders first, then a banner on the site, then a restricted admin area, and only then a suspension page. Every step is counted from the due date of the oldest unpaid invoice of the subscription.
Three rules keep it safe:
- It is off by default. Nothing ever happens to a live site until an admin turns enforcement on.
- Nothing is ever deleted. Files and databases are never touched; every step only changes how nginx answers requests.
- Paying undoes everything. Recording a full payment restores the site immediately.
🪜 The default ladder
| Day | Step | What happens |
|---|---|---|
| −7 | Reminder | A "payment due soon" notification. |
| 0 | Due notice | A "payment due today" notification. |
| +4 | Banner | A red strip at the bottom of every page of the site: "Your hosting payment is overdue. Please settle it to avoid suspension." (in the client's language). The site keeps working. |
| +7 | Restrict | Requests to /admin… and /login… get the suspension page; the public site keeps working. |
| +10 | Suspend | Every request gets the suspension page, except Let's Encrypt challenges. |
| +30 | Stop workers | The site's queue workers and scheduler are stopped (supervisorctl stop <domain>:*). |
| +60 | Final warning | A last notification. |
| +90 | Archive | The site is marked Archived and stays suspended. Its files and database are kept. |
In other words, a client is warned several times and keeps a working public site for ten days after the due date.
Note. Because invoices are issued on their due date, the −7 reminder currently arrives together with the due notice rather than a week earlier.
Grace period
Each subscription has a grace period (3 days by default). While the invoice is fewer days overdue than the grace period, the ladder only sends notifications — banners, restrictions and suspensions are held back.
Simple timing
When adding a subscription you can choose Simple — suspend N days after the due date instead of the gradual ladder. The ladder then has only two steps: the due notice on day 0 and a suspension on day N, with no grace period.
VIP clients
A subscription with Auto-suspend: No never goes past the banner step — it is never restricted, suspended, archived, and its workers are never stopped. Use it for clients you trust or bill differently.
Custom ladders
Through the API a subscription — or a plan, for all its subscriptions — can have its own ladder: a list of { "offsetDays": …, "action": … } steps using the actions remind, invoice_due, banner, restrict, suspend, stop_workers, final_warning and archive. Invalid steps are dropped; an empty or invalid ladder falls back to the default — it never means "suspend immediately".
🎚️ The master switch
The Enforcement card at the top of the Billing page controls whether the ladder may change a live site:
| Mode | Effect |
|---|---|
| Off — never touch a site | The default. Invoices are issued and notifications are sent, but no banner, restriction or suspension is ever applied. What would have happened is recorded. |
| Dry run — record only | The daily run records what it would do and changes nothing. Use it for a short check — while it is on, the daily run also issues no invoices and sends no reminders. |
| On — enforce the ladder | Full enforcement. A warning banner reminds you that it is live. |
Any unknown value counts as Off, so the switch fails closed. Restoring a site is always allowed, whatever the mode.
🔮 What happens next
Preview on a subscription shows, for that site:
- the invoice that drives the ladder, its balance and how many days it is overdue;
- the current level and the level it should be at;
- whether it is still inside the grace period or capped at the banner (VIP);
- the next step, with its date — for example Next: suspend in 3 days, on 14 Dec;
- the full ladder for that subscription.
Preview today's run (dry) on the Enforcement card runs the whole daily billing without side effects and reports what it would issue, send, escalate and restore. Run billing now runs it for real (only when enforcement is On).
⏰ When it runs
The billing run happens once a day, after 03:00 (Asia/Tbilisi time). The panel checks every 30 minutes whether today's run has happened, so if the panel was down at 03:00 it catches up as soon as it is back.
The run is safe to repeat: each billing period is invoiced once, each notification is sent at most once per invoice, and the target level is absolute — running it twice gives the same result.
Enforcement is never applied while the site is deploying; it is retried on the next run.
👁️ What visitors see
Restricted and suspended requests get a branded page in the client's language (Georgian or English):
Site temporarily suspended This website has been temporarily suspended due to an outstanding hosting payment. It will be restored immediately once the payment is received.
The page shows the amount due and a contact line. Technically:
- the response is
503 Service UnavailablewithRetry-After: 86400andnoindex, so search engines treat the outage as temporary instead of dropping the site; - requests to
/.well-known/acme-challenge/always pass, so certificate renewals keep working during a suspension; - the panel uses an internal status code to trigger the page, so your application's own
503(for examplephp artisan down) is never replaced by the suspension page.
Important. The banner is injected with nginx's sub_filter, which requires nginx built with http_sub_module (the Ubuntu packages include it). Without it, the banner step silently does nothing; restrict and suspend still work.
🔧 How a step is applied
Each step is written to a small per-site nginx snippet (/etc/nginx/orchestrator-billing/<domain>.conf) that the site's vhost includes. Every change goes through the same guard as other nginx changes:
- the vhost is backed up before it is edited for the first time;
nginx -tchecks the new configuration;- on failure the previous configuration is restored and nothing changes;
- on success nginx is reloaded.
Every attempt — applied, deferred or failed — is written to the audit log.
⏰ Reminders
Reminder, due-notice and final-warning messages go to your notification channels (Slack, Discord, Telegram, email or webhook) and to the panel's notification bell, with the invoice number, amount and client. They are written in the client's language so you can forward them.
Orchestrator does not message the client directly yet.
♻️ Restoring a site
A site is restored — banner, restriction and suspension removed — when:
- you record a payment that settles its last unpaid invoice;
- you click Restore on the Subscriptions tab;
- you cancel billing for the site;
- the daily run finds no unpaid invoice for a site that is still restricted.
Warning. If the site reached the Stop workers step, start its queue workers again from the site's Workers tab after restoring it.