---
title: Verify Account
slug: v3-gateway/verify-account
description: Learn how to obtain a Digilocker ID using a mobile number or Aadhaar number with the Verify Account API. Log in, pass the access token, and make a request with the provided curl command. Get the Digilocker ID and know if the mobile number or Aadhaar numbe
createdAt: 2023-03-15T06:56:01.000Z
---

## Introduction

You can get the Digilocker ID from a mobile number or Aadhaar number using Verify Account API. This API takes in aadhaar number/ mobile number as an input and if digilocker is registered with any of those, it returns the digilockerid as response .&#x20;

## How to call the API

You will need to log in before sending the request. You are required to pass the access token received from the login call, as the authorization header in the request.

## API Input Guidelines

**NOTE:&#xA0;**&#x45;ither mobileNumber or aadhaarNumber parameter is **compulsory.** Only **one** parameter must be sent.

### Sample Curl

::::Tabs
:::Tab{title="Production"}
```curl
curl --location 'https://api.wayne-rta.com/api/v1/digilocker/verifyAccount' \
--header 'Authorization;' \
--header 'Content-Type: application/json' \
--data '{
    "mobileNumber": ""
}'
```
:::
::::

### Input Parameters

| **PARAMETERS** | **DESCRIPTION** | **TYPE** | **VALUE**                |
| -------------- | --------------- | -------- | ------------------------ |
| mobileNumber   | Mobile Number   | String   | conditionally COMPULSORY |
| aadhaarNumber  | Aadhaar Number  | String   | conditionally COMPULSORY |

### Sample Response

:::CodeblockTabs
200

```json
{
    "result": {
        "registered": true/false,
        "digilockerid": "..digilockerid.."                          
    }
}

```
:::

### Response Parameter

| **PARAMETERS** | **DESCRIPTION**                                                                           | **TYPE** | **VALUE**                                        |
| -------------- | ----------------------------------------------------------------------------------------- | -------- | ------------------------------------------------ |
| registered     | Provides information whether Mobile number or Aadhaar number is available with Digilocker | Boolean  | true/false                                       |
| digilockerid   | Digilocker Id                                                                             | String   | Alpha numeric value(xxxxxxx-xxxxx-xxxxxx-......) |

## Sample Error

:::CodeblockTabs
```json
{
  "error": {
    "statusCode": "...status code...",
    "name": "error",
    "message": "....reason....",
    "status": "...status code...",
    "reason" : "",
    "type" : ""
  }
}
```

400

```json
{
    "error": {
        "reason": "BAD_REQUEST",
        "status": 400,
        "message": "INVALID requestId",
        "type": "Bad Request",
        "statusCode": 400,
        "name": "error"
    }
}
```

400

```json
{
    "error": {
        "reason": "AUTH_FAIL",
        "status": 400,
        "message": "This requestId is not authorized to perform this action.",
        "type": "Bad Request",
        "statusCode": 400,
        "name": "error"
    }
}
```

400

```json
{
    "error": {
        "reason": "VALIDATION_ERROR",
        "status": 400,
        "message": "Invalid mobile number",
        "type": "Bad Request",
        "statusCode": 400,
        "name": "error"
    }
}
```

400

```json
{
    "error": {
        "reason": "VALIDATION_ERROR",
        "status": 400,
        "message": "Invalid aadhaar number",
        "type": "Bad Request",
        "statusCode": 400,
        "name": "error"
    }
}
```

400

```json
{
    "error": {
        "reason": "VALIDATION_ERROR",
        "status": 400,
        "message": "\"value\" must contain at least one of [mobileNumber, aadhaarNumber]",
        "type": "Bad Request",
        "statusCode": 400,
        "name": "error"
    }
}
```

401

```json
{
    "message": "No API key found in request"
}
```
:::

### Error Parameter

| **PARAMETER NAME** | **DESCRIPTION**                    |
| ------------------ | ---------------------------------- |
| error              | This parameter contains the error. |
| error.name         | the name of the error              |
| error.message      | the error message                  |
| error.status       | status of the api                  |
| error.statusCode   | Request Status code from Signzy    |
| error.reason       | Reason for error                   |
| error.type         | Type of the error                  |

### Error Codes

| **CODE** | **DESCRIPTION**                   |
| -------- | --------------------------------- |
| 400      | Invalid inputs                    |
| 401      | Authorization Token is invalid    |
| 409      | If Upstream service not reachable |

:::hint{type="success"}
### Getting help

Please feel free to contact us if you have any questions, require clarification, or have ideas for how to make the documents or any of our services better.


You can reach out to us at [help@signzy.com](#).
:::

