Skip to content

Create an end user.

POST
/api/admin/users
Code sample: Shell / cURL
curl --request POST \
--url https://auth.example.com/api/admin/users \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "email": "[email protected]", "name": "example", "given_name": "example", "family_name": "example", "nickname": "example", "preferred_username": "example", "picture": "https://example.com", "email_verified": true, "phone_number": "example", "phone_number_verified": true, "user_type": "example" }'

Create User in the Users area. The request body is JSON unless the detailed schema for this operation states otherwise.

X-Tenant-Id
string

Tenant selector for multi-tenant admin requests.

Idempotency-Key
string

Idempotency key for state-changing operations that support replay protection.

Media type application/json
object
email
required
string format: email
name
string
given_name
string
family_name
string
nickname
string
preferred_username
string
picture
string format: uri
email_verified
boolean
phone_number
string
phone_number_verified
boolean
user_type
string
key
additional properties
One of:
string
Example generated
{
"email": "[email protected]",
"name": "example",
"given_name": "example",
"family_name": "example",
"nickname": "example",
"preferred_username": "example",
"picture": "https://example.com",
"email_verified": true,
"phone_number": "example",
"phone_number_verified": true,
"user_type": "example"
}

Admin end-user response.

Media type application/json
object
user
required
One of:
object
id
required
string
tenant_id
required
string
email
required
string | null format: email
name
required
string | null
given_name
required
string | null
family_name
required
string | null
nickname
required
string | null
preferred_username
required
string | null
picture
required
string | null format: uri
email_verified
required
boolean
phone_number
required
string | null
website
required
string | null
gender
required
string | null
birthdate
required
string | null
locale
required
string | null
zoneinfo
required
string | null
address_formatted
required
string | null
address_street_address
required
string | null
address_locality
required
string | null
address_region
required
string | null
address_postal_code
required
string | null
address_country
required
string | null
declared_residence
required
string | null
pii_class
required
string
Allowed values: PROFILE
phone_number_verified
required
boolean
user_type
required
string
is_active
required
boolean
pii_partition
required
string
pii_status
required
string
Allowed values: active deleted
lifecycle_state
required
string
created_at
required

Unix timestamp in milliseconds.

integer | null format: int64
updated_at
required

Unix timestamp in milliseconds.

integer | null format: int64
last_login_at
required
integer | null format: int64
status
required
string
Allowed values: active inactive
suspended_at
required
integer | null format: int64
suspended_until
required
integer | null format: int64
locked_at
required
integer | null format: int64
locked_until
required
integer | null format: int64
key
additional properties
Example
{
"user": {
"id": "user_123",
"tenant_id": "default",
"email": "[email protected]",
"name": "Example User",
"given_name": "Example",
"family_name": "User",
"nickname": null,
"preferred_username": "example",
"picture": "https://auth.example.com/avatars/user_123.png",
"phone_number": null,
"website": null,
"gender": null,
"birthdate": null,
"locale": "en-US",
"zoneinfo": "UTC",
"address_formatted": null,
"address_street_address": null,
"address_locality": null,
"address_region": null,
"address_postal_code": null,
"address_country": null,
"declared_residence": null,
"pii_class": "PROFILE",
"email_verified": true,
"phone_number_verified": false,
"user_type": "end_user",
"is_active": true,
"pii_partition": "default",
"pii_status": "active",
"created_at": 1770000000000,
"updated_at": 1770003600000,
"last_login_at": null,
"status": "active",
"suspended_at": null,
"suspended_until": null,
"locked_at": null,
"locked_until": null,
"lifecycle_state": "active"
}
}

Error response.

Media type application/json
object
error
string
message
string
error_description
string
key
additional properties
Example generated
{
"error": "example",
"message": "example",
"error_description": "example"
}