curl --request PATCH \
--url https://{defaultHost}/v1/{app_id}/users/{id} \
--header 'Authorization: Bearer <token>' \
--header 'X-Authorization: <api-key>'{
"user": {
"id": "usr_1234567890",
"app_id": "<string>",
"user_id": "<string>",
"status": "active",
"email": "user@example.com",
"phone": "+1234567890",
"name": "John Doe",
"login_count": 123,
"last_login_at": "2023-11-07T05:31:56Z",
"email_verified": true,
"phone_verified": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"user_meta": {
"first_name": "John",
"last_name": "Doe",
"company": "Acme Corp",
"role": "Developer"
},
"sessions": [
{
"id": "<string>",
"device_name": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"last_used_at": "2023-11-07T05:31:56Z"
}
]
}
}Update user metadata using the user ID from the path
curl --request PATCH \
--url https://{defaultHost}/v1/{app_id}/users/{id} \
--header 'Authorization: Bearer <token>' \
--header 'X-Authorization: <api-key>'{
"user": {
"id": "usr_1234567890",
"app_id": "<string>",
"user_id": "<string>",
"status": "active",
"email": "user@example.com",
"phone": "+1234567890",
"name": "John Doe",
"login_count": 123,
"last_login_at": "2023-11-07T05:31:56Z",
"email_verified": true,
"phone_verified": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"user_meta": {
"first_name": "John",
"last_name": "Doe",
"company": "Acme Corp",
"role": "Developer"
},
"sessions": [
{
"id": "<string>",
"device_name": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"last_used_at": "2023-11-07T05:31:56Z"
}
]
}
}Was this page helpful?