---
title: "Create a record by verification code"
method: POST
path: "/api/verifications/verification-code"
tags: ["Verifications"]
---

# Create a record by verification code

`POST /api/verifications/verification-code`

Create a verification record and send the code to the specified identifier. The code verification can be used to verify the given identifier.

## Request body

- object
  - `identifier` union, required — The identifier (email address or phone number) to send the verification code to.
    - object
      - `type` string, "email", required
      - `value` string, regex, required
    - object
      - `type` string, "phone", required
      - `value` string, regex, required
  - `templateType` union — Optional override for the template type used to send the verification code. If the identifier is new, BindNewIdentifier will be used regardless.
    - string, "BindMfa"
    - string, "UserPermissionValidation"

## Response `201`

The verification code has been successfully sent.

- object
  - `verificationRecordId` string, required
  - `expiresAt` string, required

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `403` — Forbidden
- `422` — The email address is restricted by the email blocklist policy.
- `429` — Too Many Requests
- `501` — The connector for sending the verification code is not configured.

---

[API](https://skmtc.net/logto/apis/logto-api-references.md) · [All operations](https://skmtc.net/logto/apis/logto-api-references/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/logto/logto-api-references/revisions/a163dc77d842/schema)
