Skip to content

Using Ghost Accounts & Invoice Cleaner

The extension adds a Client Ops group to the admin sidebar with three pages. Nothing runs automatically: there is no cron job, no event listener that deletes data, and no e-mail. Every deletion is started by an admin on one of these pages.

Your customers see nothing of the extension.

Ghost Accounts

Open Client Ops, then Ghost Accounts. The page is titled Ghost Accounts Dashboard and lists every user without an admin role, newest registration first.

Counters

Four counters sit above the table and refresh every 90 seconds.

Counter What it counts
Client Accounts All users without an admin role.
Inactive 30+ Days Clients whose last login, or registration if they never logged in, is 30 or more days ago.
Inactive 90+ Days The same with 90 days.
Likely Bot/Dead Clients matched by the Likely bot/dead account filter described below.

Columns

Column Content
Client Name, with the e-mail address below it. The search box searches first name, last name and e-mail.
Registered Registration date.
Last Login Most recent entry in Paymenter's authentication log for this user, or Never.
Inactive Days since the last login. For users without a login it is days since registration.
Paid Invoices Number of invoices in status paid.
Active Services Number of services in status active or suspended.
Risk Score Score from 0 to 100, see below. The badge changes colour at 60 and again at 80.
Likely Bot Check mark if the risk score is at least Minimum bot score.
Signals The reasons behind the score. Hidden by default; turn it on with the table's column toggle.

Risk score

The score is the sum of these points, capped at 100.

Signal Points
No paid invoice 30
No login recorded 20
No orders 15
No services 10
No tickets 10
Inactive for 90 days or more 15
Inactive for 60 to 89 days 10
Inactive for 30 to 59 days 5
E-mail domain is one of mailinator.com, 10minutemail.com, guerrillamail.com, tempmail.com, trashmail.com, yopmail.com 10

The list of disposable domains is fixed in the code and cannot be changed in the settings.

Filters

Filter Shows
No login for 30+ days Clients whose last login, or registration if there is none, is at least 30 days ago.
No login for 60+ days The same with 60 days.
No login for 90+ days The same with 90 days.
Never paid Clients without an invoice in status paid.
Never logged in Clients without any authentication log entry.
Likely bot/dead account Clients that are inactive for at least Default inactivity days and have no paid invoice, no orders, no services and no tickets.

Note

The Likely bot/dead account filter and the Likely Bot column use different rules. The filter uses the fixed conditions above. The column compares the risk score with Minimum bot score. An account can have the check mark without matching the filter.

Deleting accounts

Delete actions are only visible to admins with the Delete ghost account candidates permission.

  • Open User opens the user in Paymenter's own user editor.
  • Delete (Safe) asks for confirmation and then deletes that one account.
  • Delete Selected (Safe) deletes all accounts you ticked, after confirmation.

Before each deletion the extension checks the account against the protection settings. An account is skipped if it has an admin role, or if a protection that is switched on applies to it: paid invoices, active or suspended services, open tickets.

  • For a single account that is skipped, you get the notice Deletion blocked by safety rules.
  • A bulk run ends with Bulk action finished and the numbers, for example Deleted: 12, Skipped: 3.

Warning

Deletion is permanent and has no dry run. The protections do not cover everything: an account with only unpaid invoices, only pending or cancelled services, or only closed tickets is deleted, and those records are deleted with it. Filter first, check the list, then delete.

Invoice Cleaner

Open Client Ops, then Invoice Cleaner. The table lists invoices that match the statuses and age you set in the configuration, oldest first.

Three counters above the table show Eligible for Deletion (with the current mode), Age Threshold and Included Statuses. The columns are ID, Client, Status, Amount, Created and Age.

The actions depend on Invoice cleanup: dry run mode and are only visible with the Delete old unpaid invoices permission.

Dry run mode Row action Bulk action Result
On (default) Preview Preview Selected (Dry Run) A notice tells you which invoice, or how many invoices, would be deleted. Nothing is deleted.
Off Delete Delete Selected After confirmation the invoices are deleted and a notice reports the count.

To clean up invoices:

  1. Set the age threshold and statuses on the extension's settings page.
  2. Open the Invoice Cleaner and check the list with dry run mode still on.
  3. Switch off Invoice cleanup: dry run mode, save, and reload the Invoice Cleaner.
  4. Select the invoices and click Delete Selected.
  5. Switch dry run mode back on if you want to guard against accidental deletion.

Warning

The list is built from status and creation date only. It does not check whether an invoice belongs to a running service or to an active customer. Deleting an invoice also deletes its items and transactions in Paymenter's database. It cannot be undone.

Log Cleaner

Open Client Ops, then Log Cleaner. The page shows one row for each log table that exists in your database.

Source Table Age is taken from
Authentication Logs user_authentication_logs last_used_at
Activity Logs activity_log created_at
Failed Jobs failed_jobs failed_at

For each source you see Total rows, Eligible rows (older than the retention) and the Retention in days. A source whose retention is 0 shows Disabled and has no button.

The buttons depend on Log cleanup: dry run mode and are only visible with the Run log cleanup permission. While dry run mode is on, a banner Dry Run Mode Active is shown at the top.

Dry run mode Per source Page header Result
On (default) Preview Preview All (Dry Run) Counts the rows that would be deleted. Nothing is deleted.
Off Clean Clean All Logs Deletes the eligible rows. Clean All Logs asks for confirmation first.

After a run, a Dry Run Results or Cleanup Results section lists the number of rows per source and the cutoff date that was used.

Warning

With dry run mode off, the per-source Clean button deletes immediately, without a confirmation dialog.