---
title: "Otp Generate"
method: POST
path: "/v1/contact-verification/otp/generate"
tags: ["Contact Verification"]
---

# Otp Generate

`POST /v1/contact-verification/otp/generate`

Send one OTP over every requested channel, billing the caller per channel.

`channels` is comma-separated (e.g. "sms,email"); each delivered channel is billed
at its own product's price. Returns a reference_id for /otp/verify.

## Response `200`

Successful Response

- RESPONSECONTACTVERIFICATIONOTPGENERATE — A send fans out to N channels and so writes N usage rows. Each sent channel's usage-row id surfaces as `data.channels[ch].delivery_id`; failed/cooling channels show null. The envelope's transaction_id is therefore *not* a usage row — `data.reference_id` is what ties the rows together and what /otp/verify takes.
  - `code` integer, required
  - `timestamp` integer
  - `transaction_id` string
  - `sub_code` string
  - `message` string, required
  - `data` OtpGenerateData — Send payload. reference_id/validity_seconds/delivered are present only when at least one channel landed; the all-cooldown and all-failed paths carry channel detail but mint no reference to verify.
    - `reference_id` string
    - `validity_seconds` integer
    - `delivered` string[]
    - `retry_after` integer
    - `channels` object

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `422` — Validation Error
- `429` — Too Many Requests
- `500` — Internal Server Error

---

[API](https://skmtc.dev/deepvue/apis/deepvue-tech-developers-guide.md) · [All operations](https://skmtc.dev/deepvue/apis/deepvue-tech-developers-guide/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/deepvue/deepvue-tech-developers-guide/revisions/c1b0558e7d77/schema)
