curl --request POST \
--url https://local.auth.local.nhost.run/v1/signin/passwordless/sms \
--header 'Content-Type: application/json' \
--data '{
"phoneNumber": "<string>",
"options": {
"allowedRoles": [
"me",
"user"
],
"defaultRole": "user",
"displayName": "John Smith",
"locale": "en",
"metadata": {
"firstName": "John",
"lastName": "Smith"
},
"redirectTo": "https://my-app.com/catch-redirection"
}
}'
"OK"
Send a one-time password (OTP) to a user through SMS
curl --request POST \
--url https://local.auth.local.nhost.run/v1/signin/passwordless/sms \
--header 'Content-Type: application/json' \
--data '{
"phoneNumber": "<string>",
"options": {
"allowedRoles": [
"me",
"user"
],
"defaultRole": "user",
"displayName": "John Smith",
"locale": "en",
"metadata": {
"firstName": "John",
"lastName": "Smith"
},
"redirectTo": "https://my-app.com/catch-redirection"
}
}'
"OK"
The body is of type object
.
SMS sent successfully
The response is of type string
.
"OK"
Was this page helpful?