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

# Validate OTP

`POST /staff/validate`

Lets admin users validate OTP sent to the staff’s registered mobile number or email id through the `staff/sendOtp` API.

## Headers

- `X-CAP-API-AUTH-KEY` string, required
- `X-CAP-API-AUTH-ORG-ID` string, required

## Request body

- object
  - `id` integer, required — Unique id created for the staff
  - `username` string, required — Registered username of the staff.
  - `mobile` string — Registered mobile number of the staff to send OTP. You can use this to validate mobile number and also to authenticate login.
  - `email` string — Registered email id of the staff to send OTP. You can use this to validate email id and also to authenticate login.
  - `identifierType` 'EMAIL' | 'MOBILE', required — Specify EMAIL for email id validation and MOBILE for mobile number validation.
  - `password` string, required — The password of the staff account.
  - `otp` string, required — One time password received on the specified identifierType.

## Response `200`

200

- object
  - `entity` integer
  - `warnings` unknown[]
    - unknown
  - `errors` unknown[]
    - unknown
  - `success` boolean

## 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)
