Skip to main content
PATCH
/
users
/
{userId}
Update user
curl --request PATCH \
  --url https://api.authsignal.com/v1/users/{userId} \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "email": "[email protected]",
  "emailVerified": true,
  "phoneNumber": "+12345678901",
  "phoneNumberVerified": true,
  "username": "[email protected]",
  "displayName": "Jane Smith"
}
'
{
  "userId": "<string>",
  "email": "<string>",
  "phoneNumber": "<string>",
  "username": "<string>",
  "displayName": "<string>",
  "custom": {}
}

Authorizations

Authorization
string
header
required

Use your Authsignal secret key as the username and leave the password empty. The secret key can be found in the API Keys section of the Authsignal Portal settings page.

Path Parameters

userId
string
required

The ID of the user.

Body

application/json
custom
object

A JSON object which can include any key/value pairs. Should be provided when using rules based on your own data points.

username
string

The username used as the primary identifier for passkeys, e.g. an email address.

displayName
string

The display name used as an optional secondary identifier for passkeys, e.g. the user's full name.

email
string

The user's email address.

emailVerified
boolean
default:false

Set this to true if the user's email address has already been verified in your own system. This will result in any email OTP or magic link authenticators being updated to reflect the new email address, and the next email challenge will be sent to the new email address.

phoneNumber
string

The user's phone number in E.164 format.

phoneNumberVerified
boolean
default:false

Set this to true if the user's phone number has already been verified in your own system. This will result in any SMS authenticators being updated to reflect the new number and the next SMS challenge will be sent to the new phone number.

locale
string

The locale of the user in BCP 47 format. Used to localize email and SMS messages.

Example:

"en"

defaultVerificationMethod
enum<string>

The default verification method to use for the user. If not provided, the default verification method will be the first verification method which the user has enrolled.

Available options:
SMS,
AUTHENTICATOR_APP,
EMAIL_MAGIC_LINK,
EMAIL_OTP,
PUSH,
DEVICE,
SECURITY_KEY,
PASSKEY,
VERIFF,
IPROOV,
PALM_BIOMETRICS_RR,
IDVERSE

Response

OK

userId
string

The user's ID.

email
string

The user's email address.

phoneNumber
string

The user's phone number in E.164 format.

username
string

The username used as the primary identifier for passkeys, e.g. an email address.

displayName
string

The display name used as an optional secondary identifier for passkeys, e.g. the user's full name.

custom
object

A JSON object which can include any key/value pairs. Should be provided when using rules based on your own data points.