Run multi-tenant operations from the RootAdmin console
This page is for the platform owner — the FleetCommando system administrator. Tenant lifecycle, force activation, SLA contracts, impersonation, payment requests, and renewal extensions all live in Admin → Platform.
Who is "RootAdmin"?
A RootAdmin is a user whose email is in the ROOT_ADMIN_EMAILS
environment variable. They sit OUTSIDE every tenant and can act-as any tenant
admin via short-lived impersonation. Every RootAdmin action is audit-logged.
Tenants list
Open Admin → Platform. The left column lists every tenant with status chip (Trial / Active / PastDue / Cancelled), user count, and vehicle count. The right pane shows the selected tenant's detail.
Activate / deactivate
The toggle on the detail panel flips Tenant.IsActive. A deactivated
tenant's users can't sign in; their data is preserved. Reactivation restores
access without resending invites.
Force activation
Use this when a tenant has paid out-of-band (bank transfer, cheque, manual invoice) and you want them on a paid plan immediately, without going through Paystack.
- Open the tenant in Admin → Platform.
- Tap Send Payment Request to open the modal, pick the plan, and set the asset count.
- Tap Force (the green button). The subscription flips to Active immediately, the period end is set 30 days out, and a system audit row is written.
SLA contracts (enterprise)
Enterprise tenants run on an SLA — quarterly or annual installments tracked outside the per-asset Paystack flow. The platform admin records each payment as it lands so the renewal panel always shows the right "next due" date.
Setting up an SLA
- Open the tenant detail.
- Pick Convert to SLA and fill in: provider name, contract reference, billing cadence (Quarterly / Annual), installment amount, total installments, start date.
- Save. The tenant moves off Paystack automatic-renewal and onto the SLA cadence.
Recording a payment
- Open the tenant. The SLA section shows installment progress (e.g. 2 / 8).
- Tap Record installment, fill in the date + amount + payment method (bank, cheque, MoMo).
- The platform advances
SlaInstallmentsPaidand computes the next due date based on the cadence.
Renewal extensions
Need to push a tenant's next charge out (wire transfer in flight, holiday delay, goodwill gesture)? Each non-SLA tenant in the renewals panel has a one-click Extend button.
- Open Admin → Subscription renewals. The list shows tenants whose CurrentPeriodEnd is within 30 days.
- Tap + Extend on the row. Enter days (1–365).
- Confirm. The new period end anchors at the EXISTING end (so a 7-day extension on tomorrow's renewal becomes 8 days from now, not 7), the dunning reminder dedup mark is reset, and any past-due / cancelled status flips back to Active automatically.
Tenant impersonation
For onboarding support — when a customer asks "can you set up the geofence for me?" — RootAdmins can act-as an existing tenant admin without their password.
- Open the tenant detail.
- Tap Impersonate. Provide a reason (audit-logged, required).
- The dashboard switches identity to the tenant admin. Every action you take is tagged with both your RootAdmin id (
act_user_id) and the tenant user. - Tap Stop impersonating in the top-bar to return to your RootAdmin session. Tokens for the tenant context are short-lived (15 min) so you can't accidentally stay impersonated.
Platform stats & audit
The top of Admin → Platform shows tenant / user / vehicle / driver counts plus subscription status totals (Trial / Active / Cancelled / PastDue) and training data + audit-log row counts. Audit log lives at Settings → Audit Log with mobile card list + tap-to-expand changes diff.