Skip to main content
PATCH
/
api
/
user
/
{userId}
Update User
curl --request PATCH \
  --url https://app.replay.sale/api/user/{userId} \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "firstName": "<string>",
  "lastName": "<string>",
  "role": "User",
  "childCompanyId": "22222222-2222-4222-8222-222222222222"
}
'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "email": "jsmith@example.com",
  "firstName": "<string>",
  "lastName": "<string>",
  "role": "<string>",
  "status": "invited",
  "externalId": "<string>",
  "createdAt": "2023-11-07T05:31:56Z",
  "invitationUrl": "<string>"
}

Documentation Index

Fetch the complete documentation index at: https://docs.replay.sale/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

x-api-key
string
header
required

API key for authentication. Get your API key from your company settings.

Path Parameters

userId
string<uuid>
required

The UUID of the user to update

Body

application/json
firstName
string

New first name.

Required string length: 1 - 255
lastName
string

New last name.

Required string length: 1 - 255
role
enum<string>

New role. Same User|Manager allow-list as create.

Available options:
User,
Manager
childCompanyId
string<uuid>

Optional. When provided, update a user under this child company instead of the caller's own company. The child must be a direct child of the caller — otherwise the request is rejected with 403.

Example:

"22222222-2222-4222-8222-222222222222"

Response

Updated user record.

id
string<uuid>
required

Identifier for this record. For users this is the user.id; for pending invitations it's the invitation.id.

email
string<email>
required
firstName
string | null
required
lastName
string | null
required
role
string
required

Current role. Always User, Manager, or Disabled. Disabled means the user was deactivated and can no longer log in.

status
enum<string>
required

invited = invitation outstanding (no user.id yet); active = real user, can log in; disabled = deactivated.

Available options:
invited,
active,
disabled
externalId
string | null
required

Caller-supplied identifier echoed back. null when the record was created without one.

createdAt
string<date-time>
required
invitationUrl
string<uri> | null

For status: invited records, a link the user can follow to complete signup. Null for active/disabled.