> ## Documentation Index
> Fetch the complete documentation index at: https://www.cashfree.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Verify Passport

> This API verifies passport information to confirm customer identity. Provide the passport file number in the request to fetch relevant details.

View the [test data](https://www.cashfree.com/docs/api-reference/vrs/data-to-test-integration#passport)  and use the information to trigger the validations. The test data are usable only in the test environment sandbox.

<Note> Passport verification is supported only for Indian passports.</Note>

<Accordion title="Response codes">
  | Sub code | Status  | Message                                                                                                                                                                                                              | Next action                                                                            |
  | -------- | ------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- |
  | 200      | SUCCESS | VALID                                                                                                                                                                                                                | -                                                                                      |
  | 200      | SUCCESS | INVALID                                                                                                                                                                                                              | Enter the correct information in the request.                                          |
  | 400      | ERROR   | verification\_id is missing in the request.                                                                                                                                                                          | Enter a valid verification\_id in the request.                                         |
  | 400      | ERROR   | verification\_id can include only alphanum, dot, hyphen, and underscores.                                                                                                                                            | Only alphanumeric, period (.), hyphen (-), and underscore ( \_ ) are allowed.          |
  | 400      | ERROR   | file\_number is missing in the request.                                                                                                                                                                              | Enter the file number in the request.                                                  |
  | 400      | ERROR   | dob is missing in the request.                                                                                                                                                                                       | Enter the date of birth of the passport holder in the request.                         |
  | 400      | ERROR   | dob should be of type YYYY-MM-DD.                                                                                                                                                                                    | Enter the DOB in the YYYY-MM-DD format.                                                |
  | 400      | ERROR   | Client secret belongs to test environment.                                                                                                                                                                           | Enter the correct environment credentials in the request.                              |
  | 400      | ERROR   | x-client-id is missing in the request.                                                                                                                                                                               | Enter all the header information in the API request.                                   |
  | 401      | ERROR   | Invalid clientId and clientSecret combination.                                                                                                                                                                       | Ensure you enter valid x-client-id and x-client-secret information in the API request. |
  | 403      | ERROR   | IP not whitelisted your current IP is 106.51.91.104. For IP whitelisting assistance, visit our [IP Whitelisting guide](https://www.cashfree.com/docs/secure-id/get-started/integration/ip-whitelisting-verification) | Whitelist the IP address.                                                              |
  | 409      | ERROR   | verification ID already exists.                                                                                                                                                                                      | Enter a unique verification ID to identify the request.                                |
  | 422      | ERROR   | Insufficient balance to process this request.                                                                                                                                                                        | Try again with sufficient balance.                                                     |
  | 500      | ERROR   | something went wrong.                                                                                                                                                                                                | Try again after some time.                                                             |
  | 502      | ERROR   | verification attempt failed.                                                                                                                                                                                         | Try again after some time.                                                             |
</Accordion>


## OpenAPI

````yaml post /passport
openapi: 3.0.0
info:
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
  contact:
    email: developers@cashfree.com
    name: API Support
    url: https://discord.com/invite/QdZkNSxXsB
  title: Cashfree Verification API's.
  version: '2023-12-18'
  description: >-
    Cashfree's Verification APIs provide different types of verification to our
    merchants.
servers:
  - description: Sandbox Server
    url: https://sandbox.cashfree.com/verification
  - description: Production Server
    url: https://api.cashfree.com/verification
security: []
tags:
  - name: Aadhaar
    description: Operations related to Aadhaar verification.
  - name: BAV V2
    description: Operations related to Bank account verification v2.
  - name: PAN
    description: Operations related to PAN verification.
  - name: Digilocker
    description: Operations related to Digilocker verification.
  - name: E-sign
    description: Operations related to E-sign verification.
  - name: Reverse Penny Drop
    description: Operations related to Reverse Penny Drop verification.
  - name: UPI Penny Drop
    description: Operations related to UPI Penny Drop verification.
  - name: Mobile Penny Drop
    description: Operations related to Mobile Penny Drop verification.
  - name: IP
    description: Operation related to IP verification.
  - name: UPI
    description: Operations related to UPI verification.
  - name: Passport
    description: Operation related to Passport verification.
  - name: CIN
    description: Operation related to CIN verification.
  - name: Name Match
    description: Operation related to Name Match verification.
  - name: PAN to GSTIN
    description: Operation related to PAN to GSTIN.
  - name: Face Match
    description: Operation related to Face Match verification.
  - name: Voter ID
    description: Operation related to Voter ID verification.
  - name: Reverse Geocoding
    description: Operation related to Reverse Geocoding.
  - name: Vehicle RC
    description: Operation related to Vehicle RC verification.
  - name: Driving License
    description: Operation related to Driving License verification.
  - name: GSTIN
    description: Operation related to GSTIN verification.
  - name: Account Aggregator
    description: Operations related to Account aggregator.
  - name: OTPLess
    description: Operations related to OTPLess Verification.
  - name: 1-Click
    description: Operations related to 1-Click.
  - name: Smart OCR
    description: Operations related to Smart OCR.
  - name: Geocoding
    description: Operations related to Geocoding.
  - name: Udyam
    description: Operation related to Udyam verification.
  - name: PAN to Udyam
    description: Operation related to PAN to Udyam.
paths:
  /passport:
    post:
      tags:
        - Passport
      summary: Verify Passport
      description: >-
        This API verifies passport information to confirm customer identity.
        Provide the passport file number in the request to fetch relevant
        details.


        View the [test
        data](https://www.cashfree.com/docs/api-reference/vrs/data-to-test-integration#passport) 
        and use the information to trigger the validations. The test data are
        usable only in the test environment sandbox.


        <Note> Passport verification is supported only for Indian
        passports.</Note>
      operationId: VrsPassportVerification
      parameters:
        - $ref: '#/components/parameters/x_cf_signature'
      requestBody:
        $ref: '#/components/requestBodies/PassportVerificationRequest'
      responses:
        '200':
          $ref: '#/components/responses/PassportVerificationResponse'
        '400':
          $ref: '#/components/responses/Response400Passport'
        '401':
          $ref: '#/components/responses/Response401'
        '403':
          $ref: '#/components/responses/Response403'
        '409':
          $ref: '#/components/responses/Response409DuplicateId'
        '422':
          $ref: '#/components/responses/Response422'
        '429':
          $ref: '#/components/responses/Response429'
        '500':
          $ref: '#/components/responses/Response500V2'
        '502':
          $ref: '#/components/responses/Response502V2'
      security:
        - XClientID: []
          XClientSecret: []
components:
  parameters:
    x_cf_signature:
      description: >-
        Send the signature if two-factor authentication is selected as Public
        Key.  [More
        details](https://www.cashfree.com/docs/api-reference/vrs/getting-started#2fa-api-signature-generation).
      name: x-cf-signature
      in: header
      required: false
      schema:
        type: string
      example: ''
  requestBodies:
    PassportVerificationRequest:
      description: >-
        Find the request parameter to retrieve your customer's passport
        information.
      required: true
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/PassportVerificationRequestSchema'
  responses:
    PassportVerificationResponse:
      description: Success response for retrieveing passport information.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/PassportVerificationResponseSchema'
          examples:
            Valid Passport:
              value:
                verification_id: ABC00123
                reference_id: 1358
                status: VALID
                file_number: PA1079341954215
                name: John doe
                dob: '1998-12-31'
                application_type: NORMAL
                application_received_date: '2003-12-31'
            Invalid Passport:
              value:
                verification_id: ABC00123
                reference_id: 1358
                status: INVALID
                file_number: PA0379341954215
                name: null
                dob: null
                application_type: null
                application_received_date: null
    Response400Passport:
      description: Validation errors for Verify Passport API.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseSchema'
          examples:
            Verification ID Missing:
              $ref: '#/components/examples/VerificationIdMissing'
            Verification ID With Special Chars:
              $ref: '#/components/examples/VerificationIdWithSpecialCharacter'
            fileNumber Missing:
              $ref: '#/components/examples/FileNumberMissing'
            DOB Missing:
              $ref: '#/components/examples/DOBMissing'
            Invalid DOB:
              $ref: '#/components/examples/InvalidDOB'
            Client ID/Client Secret in Missing:
              $ref: '#/components/examples/XClientIdMissing'
            Using-Test-Credentials-in-Prod:
              $ref: '#/components/examples/UsingTestCredentialsInProd'
    Response401:
      description: Invalid client ID and client secret combination.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseSchema'
          examples:
            Invalid client ID and client secret combination:
              value:
                type: authentication_error
                code: authentication_failed
                message: Invalid clientId and clientSecret combination
    Response403:
      description: Authentication error (IP not whitelisted).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseSchema'
          examples:
            IP not whitelisted:
              value:
                type: authentication_error
                code: ip_validation_failed
                message: >-
                  IP not whitelisted your current ip is 106.51.91.104.For IP
                  whitelisting assistance, visit our guide at
                  https://www.cashfree.com/docs/secure-id/get-started/integration/ip-whitelisting-verification
            x-cf-signature header missing:
              value:
                type: validation_error
                code: authentication_failed
                message: x-cf-signature missing in the request header
    Response409DuplicateId:
      description: Conflict error.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseSchema'
          examples:
            Conflict Error:
              value:
                type: validation_error
                code: verification_id_already_exists
                message: verification ID already exists
    Response422:
      description: >-
        Validation error because of insufficient balance to process this
        request.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseSchema'
          examples:
            Insufficient balance:
              value:
                type: validation_error
                code: insufficient_balance
                message: Insufficient balance to process this request
    Response429:
      description: Rate limit exceed error.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseSchema'
          examples:
            Rate limit error per operation:
              value:
                type: rate_limit_error
                code: too_many_requests_per_operation
                message: Too many requests for this operation, rate limit reached
            Rate limit error per IP:
              value:
                type: rate_limit_error
                code: too_many_requests_per_ip
                message: Too many requests from the IP, rate limit reached
    Response500V2:
      description: Internal error.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseSchema'
          examples:
            Internal Server Error:
              value:
                type: internal_error
                code: verification_failed
                message: something went wrong
    Response502V2:
      description: Gateway error.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponseSchema'
          examples:
            Bad Gateway:
              value:
                type: internal_error
                code: verification_failed
                message: verification attempt failed
  schemas:
    PassportVerificationRequestSchema:
      type: object
      example:
        verification_id: ABC00123
        name: John Doe
        file_number: PA1079341954215
        dob: '2007-03-01'
      required:
        - verification_id
        - file_number
        - dob
      properties:
        verification_id:
          description: >-
            It is the unique ID you create to identify the verification request.
            The maximum character limit is 50. Only alphanumeric, period (.),
            hyphen (-), and underscore ( _ ) are allowed.
          type: string
          example: ABC00123
          default: ABC00123
        name:
          type: string
          description: It is the name of the passport holder.
          example: John Doe
        file_number:
          type: string
          description: >-
            It is the unique alphanumeric code that identifies an individual's
            passport application.
          example: PA1079341954215
          default: PA1079341954215
        dob:
          type: string
          description: >-
            It is the date of birth of the passport holder. The format is
            YYYY-MM-DD.
          example: '2007-03-01'
          default: '2007-03-01'
    PassportVerificationResponseSchema:
      type: object
      example:
        value:
          verification_id: ABC00123
          reference_id: 1358
          status: VALID
          file_number: PA1079341954215
          name: John doe
          dob: '1998-12-31'
          application_type: NORMAL
          application_received_date: '2003-12-31'
      properties:
        reference_id:
          type: integer
          description: >-
            It displays the unique ID created by Cashfree Payments for reference
            purposes.

            format: `int64`
          example: 1358
        verification_id:
          type: string
          description: >-
            It displays the unique ID you created to identify the verification
            request.
          example: ABC00123
        status:
          type: string
          description: It displays the status of the passport.
          example: VALID
        file_number:
          type: string
          description: >-
            It displays the unique alphanumeric code that identifies an
            individual's passport application.
          example: XX0000000000000
        name:
          type: string
          description: It displays the name of the passport holder.
          example: John Doe
        dob:
          type: string
          description: It displays the date of birth of the passport holder.
          example: YYYY-MM-DD
        application_type:
          type: string
          description: It displays the type of passport application.
          example: NORMAL
        application_received_date:
          type: string
          description: It displays when the passport application was received.
          example: YYYY-MM-DD
    ErrorResponseSchema:
      type: object
      properties:
        code:
          type: string
          example: x-client-id_missing
        error:
          type: object
          example:
            ref_id: 102
        message:
          type: string
          example: x-client-id is missing in the request.
          description: It displays the outcome of the error.
        type:
          type: string
          example: validation_error
          description: It displays the type of error.
  examples:
    VerificationIdMissing:
      value:
        type: validation_error
        code: verification_id_missing
        message: verification_id is missing in the request.
    VerificationIdWithSpecialCharacter:
      value:
        type: validation_error
        code: verification_id_value_invalid
        message: >-
          verification_id can include only alphanum, dot, hyphen and
          underscores.
    FileNumberMissing:
      value:
        type: validation_error
        code: file_number_missing
        message: file_number is missing in the request.
    DOBMissing:
      value:
        type: validation_error
        code: dob_missing
        message: dob is missing in the request.
    InvalidDOB:
      value:
        type: validation_error
        code: dob_value_invalid
        message: dob should be of type YYYY-MM-DD.
    XClientIdMissing:
      value:
        type: validation_error
        code: x-client-id_missing
        message: x-client-id is missing in the request.
    UsingTestCredentialsInProd:
      value:
        type: validation_error
        code: x-client-secret_value_invalid
        message: Client secret belongs to test environment
  securitySchemes:
    XClientID:
      type: apiKey
      in: header
      name: x-client-id
      description: >-
        Your unique client identifier issued by Cashfree. You can find this in
        your [Merchant
        Dashboard](https://merchant.cashfree.com/verificationsuite/developers/api-keys).
    XClientSecret:
      type: apiKey
      in: header
      name: x-client-secret
      description: >-
        The secret key associated with your client ID. Use this to authenticate
        your API requests. You can find this in your [Merchant
        Dashboard](https://merchant.cashfree.com/verificationsuite/developers/api-keys).

````