---
title: "Validate OTP"
method: POST
path: "/otp/validate"
---

# Validate OTP

`POST /otp/validate`

Lets you authenticate customer by validating the OTP sent to the customer through SMS or email and proceed with the necessary action such as redeeming points/coupons, and registering customer.

In Response, `entity: true` indicates the OTP validation is successful, and `"entiry": false` if the validation fails.

## Request body

- object
  - `entityType` 'MOBILE' | 'EMAIL', required — Specify MOBILE to validate OTP send to the registered mobile number, EMAIL to send the validation code to the registered email ID.
  - `entityValue` string, required — Specify the registered mobile number or email id of the customer based on the entityType passed.
  - `code` string, required — Validation code received by the customer.
  - `action` 'COUPON (for coupon redemption)' | 'POINTS (for points redemption)' | 'REGISTRATION' | 'USERGROUP' | 'SUBSCRIPTION' | 'GENERIC (for other purposes)' | 'CUSTOMER_IDENTIFIER_CHANGE' | 'CUSTOMER_STATUS_UPDATE' | 'CUSTOMER_ISSUE_LINK_CARD.', required — Action to be performed on successful validation.

## Response `200`

200

- object
  - `entity` boolean
  - `warnings` unknown[]
    - unknown

## Other responses

- `400` — 400

---

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