Skip to main content
POST
/
signin
/
otp
/
email
Sign in with email OTP
curl --request POST \
  --url https://{subdomain}.auth.{region}.nhost.run/v1/signin/otp/email \
  --header 'Content-Type: application/json' \
  --data '{
  "email": "john.smith@nhost.io",
  "options": {
    "allowedRoles": [
      "me",
      "user"
    ],
    "defaultRole": "user",
    "displayName": "John Smith",
    "locale": "en",
    "metadata": {
      "firstName": "John",
      "lastName": "Smith"
    },
    "redirectTo": "https://my-app.com/catch-redirection"
  }
}'
"OK"

Body

application/json

Email address and optional user options for OTP authentication

email
string<email>
required

A valid email

Example:

"john.smith@nhost.io"

options
object

Response

OTP sent to user's email successfully

The response is of type enum<string>.

Available options:
OK
I