Skip to main content

Tenant Management

Manage tenant lifecycle operations. Tenants are isolated environments within the multi-tenant AuthSec platform, each with their own database, users, and configuration.

Delete Tenant​

Permanently delete a tenant and all associated data. This operation is irreversible.

Endpoint: DELETE /uflow/admin/tenants/{tenant_id}

Headers​

HeaderTypeRequiredDescription
AuthorizationstringYesAdmin Bearer JWT token

Path Parameters​

ParameterTypeRequiredDescription
tenant_idstringYesTenant identifier

Response​

Success (200):

{
"message": "Tenant deleted successfully",
"tenant_id": "string"
}

Error Responses:

  • 401 - Unauthorized
  • 403 - Forbidden - insufficient permissions
  • 404 - Tenant not found

⚠️ Warning​

This operation:

  • Deletes the tenant database and all user data
  • Removes all roles, permissions, and client configurations
  • Cannot be undone

Required Permissions​

  • Must be a super admin or have tenant deletion privileges
  • Operation is logged in the audit trail