/otp/verify
✅ Email as user_id
user_id
These are the possible response codes when you make an API call to the /otp/verify
endpoint using an email address as user_id
.
Warning
If the
/token
endpoint receives five (5) attempts (either successful or failed) within a minute, it will return a429 Too Many Requests
error response. This will block the user account for 5 minutes and will automatically be unblocked when the time has passed.
Response code | Error | Message | Scenario | Resolution |
---|---|---|---|---|
200 OK | - | - | Verify OTP successfully | - |
200 OK | - | - | Invalid redirect_uri | - |
200 OK | - | - | Missing redirect_uri value | - |
200 OK | - | - | Remove redirect_uri parameter | - |
200 OK | - | - | Missing locale value | - |
200 OK | - | - | Remove locale value | - |
400 Bad Request | http_exception | "Invalid json format" | Empty payload | Add the payload. |
400 Bad Request | invalid_parameters | "Invalid json format" | Invalid JSON format used in the payload. | Use correct JSON format for the payload. |
403 Forbidden | http_exception | "Forbidden" | Invalid client_id (not existing) | Enter a valid client_id value. |
422 Unprocessable Entity | invalid_code' | "message": "Please enter a valid verification code." no error description | Enter an incorrect code | Enter a valid code value. |
422 Unprocessable Entity | invalid_code' | "message": "Please enter a valid verification code." no error description | Enter an invalid code | Enter a valid code value. |
422 Unprocessable Entity | invalid_code' | "code": "field required" | Removed code parameter | Add the code parameter and value. |
422 Unprocessable Entity | invalid_parameters' | "client_id":{ "missing": "required" } no error description | Missing client_id value | Enter a valid client_id value. |
422 Unprocessable Entity | invalid_parameters' | "client_id": "field required" | Removed client_id parameter | Add the client_id parameter and value. |
422 Unprocessable Entity | invalid_parameters' | "user_id":{ "invalid": "invalid value" } no error description | Invalid user_id "not existing" | Enter a valid user_id value. |
422 Unprocessable Entity | invalid_parameters' | "user_id":{ "invalid": "invalid fomat" } no error description | Missing user_id value | Enter a valid user_id value. |
422 Unprocessable Entity | invalid_parameters' | "user_id": "field required" | Removed user_id parameter | Add a user_id parameter and value. |
422 Unprocessable Entity | invalid_parameters' | "auth_type":{ "invalid": "unsupported auth_type value" } no error description | Invalid auth_type value | Enter a valid auth_type value. |
422 Unprocessable Entity | invalid_parameters' | "auth_type":{ "invalid": "unsupported auth_type value" } no error description | Missing auth_type value | Enter a valid auth_type value. |
422 Unprocessable Entity | invalid_parameters' | "auth_type":"field required" | Removed auth_type parameter | Add the auth_type parameter and value. |
422 Unprocessable Entity | invalid_parameters' | "message":"Please enter a valid verification code." no error description | Expired OTP code | Use a fresh OTP code. |
429 Too Many Requests | user_attempts_limits | "Too many requests" | Attempts rate limit exceeded ( 5 attempts in one minute) | |
502 Bad Gateway | - | - | Did not enter code or Missing code value | Enter a valid code value. |
502 Bad Gateway | - | - | Invalid locale value | Enter a valid code value. |
✅ Mobile phone number as user_id
user_id
These are the possible response codes when you make an API call to the /otp/verify
endpoint using a mobile phone number as user_id
.
Response code | Error | Message | Scenario | T |
---|---|---|---|---|
getaddrinfo ENOTFOUND | "Could not send request" | Invalid environment ID | Enter a valid environment ID. | |
200 OK | - | - | Successfully verified OTP send from mobile number | - |
200 OK | - | - | Invalid redirect_uri | - |
200 OK | - | - | Invalid redirect_uri (Correct URL but not part of the host whitelist) | - |
200 OK | - | - | Missing redirect_uri value | - |
200 OK | - | - | Remove redirect_uri value | - |
200 OK | - | - | Missing locale value | - |
200 OK | - | - | Remove locale parameter | - |
403 Forbidden | http_exception | "Forbidden" | Invalid client_id value | Enter a valid client_id value. |
422 Unprocessable Entity | invalid_parameters | "client_id": { "missing": "required" } no error description | Missing client_id value | Enter a valid client_id value. |
422 Unprocessable Entity | invalid_parameters | "client_id": "field required" | Removed client_id parameter | Add the client_id parameter and value. |
422 Unprocessable Entity | invalid_code | "message": "Please enter a valid verification code." no error description | Invalid code value | |
422 Unprocessable Entity | invalid_code | "message": "Please enter a valid verification code." no error description | Expired code value | Enter a valid code value. |
422 Unprocessable Entity | invalid_parameters | "code": "field required" | Removed code parameter | Add the code parameter and value. |
422 Unprocessable Entity | invalid_parameters | "user_id": { "invalid": "invalid value" } no error description | Invalid user_id value | Enter a valid user_id value. |
422 Unprocessable Entity | invalid_parameters | "user_id": { "invalid": "invalid format" } no error description | Missing user_id value | Enter a valid user_id value. |
422 Unprocessable Entity | invalid_parameters | "user_id": "field required" | Removed user_id parameter | Add the user_id parameter and value. |
422 Unprocessable Entity | invalid_parameters | "auth_type": { "invalid": "unsupported auth_type value" } no error description | Invalid auth_type | Enter a valid auth_type value. |
422 Unprocessable Entity | invalid_parameters | "auth_type": { "invalid": "unsupported auth_type value" } no error description | Missing auth_type | Enter a valid auth_type value. |
422 Unprocessable Entity | invalid_parameters | "auth_type": "field required" | Removed auth_type parameter | Add the auth_type parameter and value. |
429 Too Many Requests | user_attempts_limit | "Too many requests" | Attempts rate limit exceeded ( 5 attempts in one minute) | Limit calls to the endpoint within the rate limit. |
502 Bad Gateway | - | - | Missing code value | Enter a valid code value. |
502 Bad Gateway | - | - | Invalid locale value | Enter a valid code value. |
503 Service Temporarily Unavailable | - | "Backend action does not exist" | Invalid version Number | Enter a valid version number. |