Check a verification code
check_verificationCheck the code the human typed, for the number the code was sent to. The result is the verification only when it is approved; every other outcome is a tool error with an error.code. Let the user in only when a check answers 200 with status approved; treat every other answer, a timeout and a network error as not approved.
Errors: incorrect_code (attempts remain), too_many_attempts (start a new verification), recipient_mismatch (to is not the number the code was sent to), verification_expired, verification_closed (already approved or replaced), verification_not_found. A wrong code costs an attempt, and five close the verification: do not retry a check by yourself; ask the human for the code again.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | The number the code was sent to, which your application is about to mark as verified. | |
| code | Yes | The six digits the human typed, as a string. | |
| api_key | No | An sk_test_ key, for example from create_test_key. Leave it out to use the key in this MCP server's Authorization header. A live key (sk_live_) is refused here: tool arguments are kept in the conversation, so a live key belongs in the header. | |
| verification_id | Yes | The verification `id` from start_verification (ver_…). |