Access
Preview

Close the organization

Closes the organization now and deletes it after thirty days unless the closing is cancelled. The Owner confirms by

POST
/organization/close
cookiebetter-auth.session_token<token>

Better Auth session cookie. Production uses the __Secure- prefixed name.

application/json
  1. body
confirmName*string

The organization's name, typed exactly.

Response Body

The organization is closing.

application/json
  1. response
closedAt*string
Formatdate-time
deleteAt*string

When the organization's data is deleted if the closing is not cancelled first.

Formatdate-time
cancelledAt?string
Formatdate-time
state*OrganizationClosureState
Value in"closing""cancelled""deleted"
Example Request
curl -X POST 'https://wardn.example.com/api/v1/organization/close' \  -H 'Content-Type: application/json' \  -d '{  "confirmName": "string"}'
Example Response
{  "closedAt": "2019-08-24T14:15:22Z",  "deleteAt": "2019-08-24T14:15:22Z",  "cancelledAt": "2019-08-24T14:15:22Z",  "state": "closing"}