Skip to content

Handle Customer Offboarding

A customer is leaving. This recipe covers cancelling entitlements, handling data retention, archiving the Organization, what is preserved versus deleted, and the Cancellation Policy grace period.

Prerequisites

  • WordPress admin access.
  • The customer has communicated their intent to leave, or a payment failure has exhausted the recovery period.
  • You know which entitlements and resources are affected.

Steps

Part A: Review active entitlements

Step 1. Go to MIDDAG Account > Organizations and open the customer's Organization.

Step 2. Navigate to the Entitlements tab. List all entitlements with status active or suspended.

Step 3. For each entitlement, note:

  • The class (PLG, ENV, SVC, ORD, AFL, EDU).
  • Downstream resources attached (licenses, environments, services, contracts, credit balances).
  • Whether there is remaining credit balance or prepaid time.

Part B: Cancel entitlements

Step 4. For voluntary cancellation (customer requested):

  1. Open each entitlement.
  2. Click Cancel Entitlement.
  3. Select the cancellation reason (dropdown: customer request, business closure, switching provider, etc.).
  4. Add optional notes.
  5. Click Confirm Cancellation.

Step 5. The Cancellation Policy determines what happens next. Check the policy values:

SettingDefaultWhat it means
portal_visibility_days90How long the cancelled entitlement remains visible in the portal.
data_retention_days365How long data is retained before purging.
allow_reactivationtrueWhether the entitlement can be reactivated after cancellation.
reactivation_window_days90How many days after cancellation reactivation is allowed.
refund_eligiblefalseWhether the customer is eligible for a prorated refund.

Step 6. For cancellation due to payment failure: the system auto-cancels after the grace period expires (default: 30 days). See Suspend for Non-Payment. No manual action needed unless you want to intervene.

Part C: Downstream resource cleanup

Step 7. When an entitlement is cancelled, the ProvisioningPolicy's deprovision_on_cancel setting governs what happens to downstream resources:

PLG entitlements:

  • License status transitions to cancelled.
  • Existing site activations stop receiving updates but continue functioning on the currently installed version.
  • Download access is revoked.

ENV entitlements:

  • Environment record is marked deprovisioned.
  • The admin should export customer data from the environment before shutting down the server.
  • Schedule infrastructure teardown according to your data retention policy.

SVC entitlements:

  • Service record transitions to cancelled.
  • Open service requests are completed or cancelled (admin review required).
  • Contract transitions to cancelled.
  • Remaining credit balance is frozen (no new consumption).

Step 8. For environments, export customer data before teardown:

  1. Go to the Environment record.
  2. Click Export Data (if the platform supports automated export) or manually create a backup.
  3. Provide the export to the customer.

Part D: Data retention period

Step 9. After cancellation, data enters the retention period (default: 365 days). During this time:

  • All Organization data (entitlements, orders, invoices, contracts, documents) is preserved in the database but no longer visible in the customer portal after portal_visibility_days expires.
  • The admin can still access all data from the WordPress admin panel.
  • The customer can request a data export at any time during the retention period.

Step 10. Offer the customer a data export:

  1. Go to the Organization detail page.
  2. Click Generate Data Export.
  3. The system creates a ZIP file containing the Organization's entitlements, orders, invoices, contracts, and documents.
  4. Send the download link to the customer.

Part E: Archive the Organization

Step 11. Once all entitlements are cancelled and the customer has been notified:

  1. Go to the Organization detail page.
  2. Click Archive Organization.
  3. Confirm the action.

Step 12. An archived Organization:

  • Is no longer visible in the default Organization list (use the "Show Archived" filter to find it).
  • Cannot accept new quotes or orders.
  • Collaborator portal access is disabled.
  • All data remains in the database per the retention policy.

Part F: Reactivation (win-back)

Step 13. If the customer comes back within the reactivation window:

  1. Open the archived Organization (use the "Show Archived" filter).
  2. Click Unarchive Organization.
  3. Open the cancelled entitlement(s) and click Reactivate.
  4. Process a new payment or link a new order.
  5. Downstream resources are re-provisioned.

Part G: Final data purge

Step 14. After the data_retention_days period expires, the system flags the Organization's data for purging. A cron job handles the purge:

  • Entitlements, orders, invoices, and related records are permanently deleted.
  • The Organization record itself is kept as a tombstone (name, tax ID, dates) for legal compliance.

Step 15. Review the purge queue under MIDDAG Account > Settings > Data Retention before the cron runs. You can extend retention for specific Organizations if needed.

Expected result

  • All active entitlements are cancelled with a recorded reason.
  • Downstream resources are cleaned up per the ProvisioningPolicy.
  • The customer received a data export if requested.
  • The Organization is archived -- no new transactions can occur.
  • Data is retained for the configured period (default: 365 days) and purged afterward.

Further reading