Skip to content
Last updated

Update a user profile

Prerequisites

  • A valid API key — see Obtain API credentials
  • The id of the user to update (for example, USER-3MtwBwLkdIwHu7ix28a3tqPa)

Updatable fields

FieldDescription
first_nameUser's first name
last_nameUser's last name
emailEmail address (also the login username)
phonePhone number in E.164 format
time_zoneIANA time zone
Partial updates

Include only the fields you want to change. Fields you omit are left unchanged.

Step 1: Send the update request

Send POST /v1/users/{id} with the fields to change.

curl -X POST \
  https://api.dev.paradisegateway.net/v1/users/USER-3MtwBwLkdIwHu7ix28a3tqPa \
  -H "Content-Type: application/json" \
  -H "APIKEY: YOUR-API-KEY" \
  -d '{
    "first_name": "Jonathan",
    "phone": "+15559999999",
    "time_zone": "America/Los_Angeles"
  }'

Step 2: Verify the response

A 200 response returns the full, updated user object.

{
  "id": "USER-3MtwBwLkdIwHu7ix28a3tqPa",
  "object": "user",
  "first_name": "Jonathan",
  "last_name": "Doe",
  "email": "john.doe@example.com",
  "phone": "+15559999999",
  "time_zone": "America/Los_Angeles",
  "is_mfa_active": false,
  "is_active": true,
  "is_locked": false,
  "correlation_id": "d4e5f6a7-b8c9-0123-def0-1234567890ab"
}

Changing a user's email

Updating email also changes the user's login username. Coordinate with the user before making this change so they know to use the new email at next login.

Email uniqueness

Each email address must be unique across all users. The API returns a 400 error if the email is already in use.

Next steps