Delete organisation
DELETE
https://app.speybooks.com/api/v1/admin/orgs/{id}Permanently delete an organisation and all associated accounting data. Implements GDPR Article 17. This operation is irreversible.
Confirmation
Requires confirm: "DELETE" and reason (minimum 5 characters).
Stripe Cleanup
If the organisation has a Stripe subscription, it is cancelled via stripe.subscriptions.cancel(). Stripe errors are logged but do not block deletion (subscription may already be cancelled).
Cascade Delete (Transaction)
Deletes in dependency order within a single transaction:
journal_entry_linesjournal_entriesinvoice_linesinvoicestransactionscontactsaccountsaudit_loguser_organisationsorganisations
Side Effects
- Writes
ORG_DELETED_GDPRtoadmin_audit_logwith the deleted organisation name
Note: linked users are not deleted, only their organisation membership. Users become orphaned and can be deleted separately or re-assigned.
Path parameters
id string requiredOrganisation ID to permanently delete.
Response
200 Organisation permanently deleted (GDPR). Stripe subscription cancelled, all data cascade-deleted.
Show response fields
message stringError codes
404 Organisation not found.