ClavianAPI errors
All error codes

400 Bad Request

Incorrect code

Code
otp_invalid
Status
400 Bad Request
Type
https://errors.clavian.io/otp-invalid

What it means

The one-time code does not match the one sent. That code still works until it expires or five wrong attempts use it up.

What to do

Let the person type the code again. Once it is used up the answer becomes otp_expired, and they need a new one.

Example

The API answers with status 400 and this body, as application/problem+json. A detail may be added, saying what went wrong this time; it is for people, and changes.

{
  "type": "https://errors.clavian.io/otp-invalid",
  "title": "Incorrect code",
  "status": 400,
  "code": "otp_invalid",
  "requestId": "req_01k5znw4hmfay8vvr14d2pf2db"
}

Endpoints that return it

From the OpenAPI document, every endpoint that names it among its answers: