---
title: Face Extraction API
slug: v2-apis/g0rt-face-extraction-api
description: Learn how to use the PAN verification API in India to efficiently verify permanent account numbers. This document offers detailed guidelines, code examples, and contact information for assistance, making it easier for you to ensure accurate PAN verificati
createdAt: 2022-09-22T21:03:21.000Z
---

## Introduction

A permanent account number is a ten-character alphanumeric identifier, issued in the form of a laminated "PAN card", by the Indian Income Tax Department, to any "person" who applies for it or to whom the department allots the number without an application.

## How to call the API

Before going for Auto reading or Verification calls, you first need to create an Identity object. For best results, please make sure that the image you use fits tightly in camera view and is horizontally aligned. Each image/pdf should be less than 2MB and an expired image should not be uploaded.

## API Input Guidelines

- The Image should be of good quality
- The Image should be less than 2MB in size
- This API accepts only image, pdf, or URLs of image(png/jpg/jpeg/tiff)

## Step 1: Hit Identities API

:::ApiMethodV2
```json
{
  "tab": "examples",
  "url": "https://preproduction.signzy.tech/api/v2/patrons/<Patron ID>/identities",
  "name": "Identity Request",
  "method": "POST",
  "request": {
    "pathParameters": [],
    "queryParameters": [],
    "headerParameters": [
      {
        "kind": "required",
        "name": "Authorization",
        "type": "string",
        "children": [],
        "description": "Contains the id parameter returned from the login step"
      },
      {
        "kind": "required",
        "name": "Content-Type",
        "type": "string",
        "children": [],
        "description": "Application/JSON"
      }
    ],
    "bodyDataParameters": [
      {
        "kind": "required",
        "name": "type",
        "type": "string",
        "description": "Type of identity - PAN"
      },
      {
        "kind": "required",
        "name": "email",
        "type": "string",
        "children": [],
        "description": "e-mail ID"
      },
      {
        "kind": "required",
        "name": "callbackurl",
        "type": "string",
        "children": [],
        "description": "URL where response will be posted"
      },
      {
        "kind": "required",
        "name": "images",
        "type": "Array",
        "children": [],
        "description": "Front and back image of aadhaar"
      }
    ],
    "formDataParameters": []
  },
  "results": {
    "languages": [
      {
        "id": "AldhBKlzZNUpNGHj-FvO7",
        "code": "{\n    \"type\": \"individualPan\",\n    \"email\": \"ankur.rand@signzy.com\",\n    \"callbackUrl\": \"https://www.w3schools.com\",\n    \"images\": [],\n    \"accessToken\": \"<Access Token>\",\n    \"autoRecognition\": [],\n    \"verification\": [],\n    \"forgeryCheck\": [],\n    \"id\": \"<ID>\",\n    \"patronId\": \"<PatronID>\"\n}",
        "language": "200",
        "customLabel": ""
      }
    ],
    "selectedLanguageId": "AldhBKlzZNUpNGHj-FvO7"
  },
  "examples": {
    "languages": [
      {
        "id": "y2f_VZjz30OnY7EU_Y9xV",
        "code": "curl --location --request POST 'https://preproduction.signzy.tech/api/v2/patrons/<Patron ID>/identities' \\\n--header 'Authorization: <Auth Key>' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n    \"type\": \"individualPan\",\n    \"email\": \"<email Id>\",\n    \"callbackUrl\": \"https://www.w3schools.com\",\n    \"images\": [<images Url>]\n}'",
        "language": "curl",
        "customLabel": "Preproduction"
      },
      {
        "id": "Cuy5OBiTMi25oM_xpIiF8",
        "code": "curl --location --request POST 'https://signzy.tech/api/v2/patrons/<Patron ID>/identities' \\\r\n--header 'Authorization: <Auth Key>' \\\r\n--header 'Content-Type: application/json' \\\r\n--data-raw '{\r\n    \"type\": \"individualPan\",\r\n    \"email\": \"<email Id>\",\r\n    \"callbackUrl\": \"https://www.w3schools.com\",\r\n    \"images\": [<images Url>]\r\n}'",
        "language": "curl",
        "customLabel": "Production"
      }
    ],
    "selectedLanguageId": "y2f_VZjz30OnY7EU_Y9xV"
  },
  "description": "Creating Identity card object",
  "currentNewParameter": {
    "label": "Body Parameter",
    "value": "bodyDataParameters"
  }
}
```
:::

### Identity Response Parameters

| **Parameter Name** | **Data Type** | **Description**                         |
| ------------------ | ------------- | --------------------------------------- |
| accessToken        | String        | This is provided by identities API      |
| autoRecognition    | String        | Auto recognises face from aadhaar image |
| verification       | String        | Verification                            |
| frogeryCheck       | String        | Forgery check of the image              |
| id                 | String        | Contains the Identity object id         |
| patronId           | String        | Unique ID of the user                   |

***

## Step 2: Hit Snoops API and receives a response

:::ApiMethodV2
```json
{
  "tab": "examples",
  "url": "https://preproduction.signzy.tech/api/v2/snoops",
  "name": "Snoop request",
  "method": "POST",
  "request": {
    "pathParameters": [],
    "queryParameters": [],
    "headerParameters": [
      {
        "kind": "required",
        "name": "Content-Type",
        "type": "string",
        "children": [],
        "description": "Application/JSON"
      }
    ],
    "bodyDataParameters": [
      {
        "kind": "required",
        "name": "service",
        "type": "string",
        "description": "Type of Signzy service - “identity extraction"
      },
      {
        "kind": "required",
        "name": "itemId",
        "type": "string",
        "children": [],
        "description": "Contains the identity item id"
      },
      {
        "kind": "required",
        "name": "task",
        "type": "string",
        "children": [],
        "description": "Task- Face Extraction"
      },
      {
        "kind": "required",
        "name": "essentials",
        "type": "Object",
        "children": [
          {
            "kind": "required",
            "name": "url",
            "type": "string",
            "description": "URL of the pan image from which face to be extracted "
          }
        ],
        "description": "Contains the essential output data"
      }
    ],
    "formDataParameters": []
  },
  "results": {
    "languages": [
      {
        "id": "DhbJ_vixnOkpCrZqji4t3",
        "code": "{\n    \"service\": \"Identity\",\n    \"itemId\": \"<Item Id>\",\n    \"task\": \"faceExtraction\",\n    \"essentials\": {\n        \"url\": \"<>\"\n    },\n    \"accessToken\": \"<Access Token>\",\n    \"id\": \"<ID>\",\n    \"response\": {\n        \"url\":\"<URL of  PAN image to be cropped >\" ,\n        \"ttl\": \"10 mins\",\n        \"id\": 25,\n        \"result\": {\n            \"cropped\": \"<Image URL of face extracted>\"\n        }\n    }\n}",
        "language": "200",
        "customLabel": ""
      }
    ],
    "selectedLanguageId": "DhbJ_vixnOkpCrZqji4t3"
  },
  "examples": {
    "languages": [
      {
        "id": "IUyd0fXV16FzqwRomPH8e",
        "code": "curl --location --request POST 'https://preproduction.signzy.tech/api/v2/snoops' \\\n--header 'Content-Type: application/json;charset=UTF-8' \\\n--data-raw '{\n    \"service\": \"Identity\",\n    \"itemId\": \"<Item Id>\",\n    \"accessToken\": \"<Access Token>\",\n    \"task\": \"faceExtraction\",\n    \"essentials\": {\n        \"url\": \"<Image URL>\"\n    }\n}'",
        "language": "curl",
        "customLabel": "Preproduction"
      },
      {
        "id": "QIUCpAx1bKdl6g6TL-gV7",
        "code": "curl --location --request POST 'https://signzy.tech/api/v2/snoops' \\\r\n--header 'Content-Type: application/json;charset=UTF-8' \\\r\n--data-raw '{\r\n    \"service\": \"Identity\",\r\n    \"itemId\": \"<Item Id>\",\r\n    \"accessToken\": \"<Access Token>\",\r\n    \"task\": \"faceExtraction\",\r\n    \"essentials\": {\r\n        \"url\": \"<Image URL>\"\r\n    }\r\n}'",
        "language": "none",
        "customLabel": "Production"
      }
    ],
    "selectedLanguageId": "QIUCpAx1bKdl6g6TL-gV7"
  },
  "description": "Performing autoRecognition & verification",
  "currentNewParameter": {
    "label": "Body Parameter",
    "value": "bodyDataParameters"
  }
}
```
:::

### Response Parameters

| **Parameter Name**      | **Description**                                                                                                                   |
| ----------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| service                 | Type of Signzy service - “identity extraction”                                                                                    |
| itemId                  | Contains the identity item id                                                                                                     |
| task                    | The type of task performed - “face extraction”                                                                                    |
| essentials              | Contains the essential output data                                                                                                |
| accessToken             | Contains the access token that was received from identity request                                                                 |
| Id                      | Contains the unique Id of the snoop request                                                                                       |
| response.url            | URL of PAN image to be cropped                                                                                                    |
| response.ttl            | ttl is Time to live Time to live (TTL) is the time that an object is stored in a caching system before it's deleted or refreshed. |
| response.id             | ID od the resonse                                                                                                                 |
| response.result.cropped | URL of Cropped image from PAN                                                                                                     |

###

:::hint{type="info"}
### 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](#).
:::

