POST
/v1/auth/otp/update/phone/im

Authorization

Descope Project ID:Refresh JWT
AuthorizationBearer <token>

Project ID:Refresh JWT as bearer token.

In: header

Request Body

application/json

loginId*string
Length1 <= length
phone*string
Length1 <= length
addToLoginIDs?boolean
Defaultfalse
onMergeUseExisting?boolean
Defaultfalse
providerId?string
Lengthlength <= 254
templateOptions?object
locale?string
Lengthlength <= 254
failOnConflict?boolean
mfa?boolean

When true, the existing refresh token's auth methods are preserved and the verified phone is added to them (MFA), instead of replacing the amr with a single factor. Requires a valid refresh token on the request.

Update phone, and verify via OTP based on an instant message

curl -X POST "https://api.descope.com/v1/auth/otp/update/phone/im" \  -H "Content-Type: application/json" \  -d '{    "loginId": "string",    "phone": "string"  }'
{  "maskedPhone": "string",  "verificationAttempts": 0}
export interface Response {maskedPhone?: stringverificationAttempts?: number}
Was this helpful?