> ## Documentation Index
> Fetch the complete documentation index at: https://developer.sandbox.co.in/llms.txt
> Use this file to discover all available pages before exploring further.

# Verify OTP for CSI download

> Verify the OTP to download the CSI file.

Use the reference ID returned by [Generate OTP for CSI download](/api-reference/tds/compliance/download-csi/endpoints/generate_otp) and the OTP sent to the mobile number.

On success, download the file using `data.csi_url`.

<Note>
  An incorrect or expired OTP can return HTTP 200 with an error in `data.message`. Continue only when the response includes `data.csi_url`.
</Note>


## OpenAPI

````yaml api-reference/tds/compliance/openapi.json POST /tds/compliance/csi/otp/verify
openapi: 3.1.0
info:
  title: compliance
  description: >-
    Tax Deducted at Source (TDS) is an indirect method of collecting Income Tax.
    TDS is based on the principle of “Pay as you earn” which is beneficial for
    both the Government and the taxpayer. It is where a person making a payment
    of specified nature is liable to deduct tax at a prescribed rate. This
    ensures continuous revenue for the Government by way of Tax Deducted at the
    Source.


    The Payer making a payment is also responsible to deposit TDS with the
    Income Tax Department within a specified date and file a TDS Return. Once
    filed, the deposited amount will be shown in the Payee's Form 26AS which
    they can then use to claim tax credits when filing ITR.


    However, staying TDS compliant can be a hassle for businesses, as they are
    required to :


    1. Deduct TDS from payments that are liable for TDS Deduction at an
    appropriate rate.
        
    2. Deposit TDS to Government before the due date.
        
    3. File TDS Returns on a Quarterly basis.
        
    4. Issue a TDS Certificate by the deductor to the deductee.
        

    Organizations deducting TDS have to remain compliant with each of the steps.
    Failure to do so results in TDS Penalties by Authorities. Sandbox provides
    TDS Compliance APIs to help you automate end-to-end TDS compliance.
  version: 1.0.0
servers:
  - url: https://test-api.sandbox.co.in
  - url: https://api.sandbox.co.in
security: []
tags:
  - name: TDS Compliance Check
  - name: Download CSI
  - name: FVU Generation
  - name: E-File TDS Return
  - name: TDS
  - name: TDS Certificate
  - name: TRACES Credentials
paths:
  /tds/compliance/csi/otp/verify:
    post:
      tags:
        - Download CSI
      summary: Verify OTP for CSI download
      description: Verify the OTP to download the CSI file.
      parameters:
        - name: authorization
          in: header
          description: JWT access token
          required: true
          example: ''
          schema:
            type: string
        - name: x-api-key
          in: header
          description: API key for identification
          required: true
          example: ''
          schema:
            type: string
        - name: x-api-version
          in: header
          description: ''
          required: false
          example: ''
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                '@entity':
                  type: string
                  enum:
                    - in.co.sandbox.tds.compliance.deductors.csi.request
                reference_id:
                  type: string
                  description: >-
                    The data.reference_id returned by Generate OTP for CSI
                    download.
                otp:
                  type: string
                  description: >-
                    OTP sent to the mobile number provided in the generation
                    request.
              required:
                - '@entity'
                - reference_id
                - otp
            examples:
              200 - Success:
                value:
                  '@entity': in.co.sandbox.tds.compliance.deductors.csi.request
                  reference_id: FOS005981930273
                  otp: '834201'
                summary: 200 - Success
              200 Invalid OTP:
                value:
                  '@entity': in.co.sandbox.tds.compliance.deductors.csi.request
                  reference_id: FOS101212121212121
                  otp: '121212'
                summary: 200 Invalid OTP
              200 OTP Expired:
                value:
                  '@entity': in.co.sandbox.tds.compliance.deductors.csi.request
                  reference_id: FOS101212121212121
                  otp: '121212'
                summary: 200 OTP Expired
      responses:
        '200':
          description: >-
            Check the response body for the result. HTTP 200 can also contain an
            application error in data.message.
          content:
            application/json:
              schema:
                type: object
                properties:
                  timestamp:
                    type: integer
                  transaction_id:
                    type: string
                  data:
                    type: object
                    properties:
                      '@entity':
                        type: string
                      tan:
                        type: string
                      from:
                        type: integer
                      to:
                        type: integer
                      reference_id:
                        type: string
                        description: Reference ID associated with the verified OTP request.
                      csi_url:
                        type: string
                        description: >-
                          Download the CSI file from this URL after successful
                          verification. The example URL is illustrative.
                      message:
                        type: string
                        description: >-
                          Application error message when verification fails,
                          such as an incorrect or expired OTP.
                  code:
                    type: integer
              examples:
                200 - Success:
                  summary: 200 - Success
                  value:
                    timestamp: 1731669721578
                    transaction_id: 8a0c097f-8e6d-4c11-8228-87d3c8cc44ce
                    data:
                      '@entity': in.co.sandbox.tds.compliance.deductors.csi.response
                      tan: AHMA09719B
                      from: 1722450600000
                      to: 1730313000000
                      reference_id: FOS005981930273
                      csi_url: https://example.com/challan.csi
                    code: 200
                200 Invalid OTP:
                  summary: 200 Invalid OTP
                  value:
                    code: 200
                    timestamp: 1763362637000
                    transaction_id: e2b9145f-69d5-4bbe-a6de-be6fc08b426f
                    data:
                      '@entity': in.co.sandbox.tds.compliance.deductors.csi
                      message: The OTP you have entered is incorrect.
                200 OTP Expired:
                  summary: 200 OTP Expired
                  value:
                    code: 200
                    timestamp: 1763362637000
                    transaction_id: e2b9145f-69d5-4bbe-a6de-be6fc08b426f
                    data:
                      '@entity': in.co.sandbox.tds.compliance.deductors.csi
                      message: OTP expired
          headers: {}
      deprecated: false
      security: []

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.