Set a tenant as the default tenant.
POST
/api/admin/tenants/{id}/set-default
Code sample: Shell / cURL
curl --request POST \ --url https://auth.example.com/api/admin/tenants/example/set-default \ --header 'Authorization: Bearer <token>'Set the path tenant as the default tenant. The path parameter identifies the target tenant, so X-Tenant-Id is not required.
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” id
required
string
Responses
Section titled “ Responses ”Tenant mutation response. Timestamps and lifecycle fields are assigned by the server and are not accepted in the create request body.
Media type application/json
Tenant row returned by create, update, set-default, and other tenant mutation operations.
object
id
required
string
tenant_code
required
string
name
required
string
description
required
string | null
lifecycle_state
required
string
is_default
required
boolean
created_at
required
Unix timestamp in seconds.
integer format: int64
updated_at
required
Unix timestamp in seconds.
integer format: int64
provisioning
Present on tenant D1 pool create and provisioning retry responses.
object
mode
string
slot_id
string
smoke_test
string
retry
string
key
additional properties
key
additional properties
Examples
Tenant created in the shared control-plane database.
{ "id": "acme", "tenant_code": "acme", "name": "Acme Corp", "description": "Production tenant for Acme Corp.", "lifecycle_state": "active", "is_default": false, "created_at": 1770000000, "updated_at": 1770000000}Tenant created with a preallocated tenant D1 slot.
{ "id": "acme", "tenant_code": "acme", "name": "Acme Corp", "description": "Production tenant for Acme Corp.", "lifecycle_state": "active", "is_default": false, "created_at": 1770000000, "updated_at": 1770000000, "provisioning": { "mode": "tenant-d1-preallocated-pool", "slot_id": "slot_01HQ0X9Q7Y2T6J4ZC8M3N2P1A0", "smoke_test": "passed" }}