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

# File Download

> File content downloaded by matching hash values.



## OpenAPI

````yaml post /terminals/download/file
openapi: 3.0.3
info:
  title: Paycode - API Documentation
  description: >

    ## Get started


    Paycode provides a collection of APIs that enable you to process and manage
    payments.

    Our APIs accept and return JSON in the HTTP body, and return standard HTTP
    response codes.


    You can consume the APIs directly using your favorite HTTP/REST library.


    We have a testing environment referred to "sandbox", which you can setup to
    test API calls without

    affecting production data.

    Currently, our sandbox environment is live while our production environment
    is under development

    and will be available soon.

    You can sign up on our Dashboard to get API keys to access Paycode API.


    ### Environment


    Use the following base URLs when making requests to the APIs:


    | Environment   |  Base URL                          |

    |---------------|------------------------------------|

    | Sandbox       | <https://api.staging.paycodefintech.net>   |

    | Production    | <https://api.production.paycodefintech.net>       |


    ## Authentication


    When you sign up on our [dashboard](https://app.staging.paycodefintech.net)
    and create a merchant

    account, you are given a secret key (also referred as api-key) and a
    publishable key.

    You may authenticate all API requests with Paycode server by providing the
    appropriate key in

    the request Authorization header.


    | Key             | 
    Description                                                                                 
    |

    |-----------------|-----------------------------------------------------------------------------------------------|

    | api-key         | Private key. Used to authenticate all API requests from
    your merchant server                  |

    | publishable key | Unique identifier for your account. Used to authenticate
    API requests from your app's client  |


    Never share your secret api keys. Keep them guarded and secure.
  contact:
    name: Paycode Support
    url: https://paycodefintech.net
    email: Paycode@juspay.in
  license:
    name: Apache-2.0
  version: 0.1.0
servers:
  - url: https://api.staging.paycodefintech.net
    description: Sandbox Environment
security: []
tags:
  - name: Merchant Account
    description: Create and manage merchant accounts
  - name: Profile
    description: Create and manage profiles
  - name: Merchant Connector Account
    description: Create and manage merchant connector accounts
  - name: Payments
    description: Create and manage one-time payments, recurring payments and mandates
  - name: Refunds
    description: Create and manage refunds for successful payments
  - name: Mandates
    description: Manage mandates
  - name: Customers
    description: Create and manage customers
  - name: Payment Methods
    description: Create and manage payment methods of customers
  - name: Disputes
    description: Manage disputes
  - name: API Key
    description: Create and manage API Keys
  - name: Payouts
    description: Create and manage payouts
  - name: payment link
    description: Create payment link
  - name: Routing
    description: Create and manage routing configurations
  - name: Event
    description: Manage events
  - name: POS
    description: Point of Sale operations including balance enquiry
paths:
  /terminals/download/file:
    post:
      tags:
        - Terminal
      summary: File Download
      description: File content downloaded by matching hash values.
      operationId: File Download
      requestBody:
        description: Request body for downloading terminal file content
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TerminalFileDownloadRequest'
            examples:
              Sample Request:
                value:
                  file_type: AID
                  file_version: v2.1.5
                  hash: >-
                    2e7eb7a293d2718e23c3777691adc9e16624a8b5ad9dbfa25ddcea3fdb437cc9
                  network_token: TI5vXQgbZZPHXP7TOCo0
                  terminal_id: term_tPYmyt3FEfKl83JiHpb2
        required: true
      responses:
        '200':
          description: Terminal File Content Downloaded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TerminalFileDownloadResponse'
              examples:
                Sample Response:
                  value:
                    file_content:
                      - aid: A0000008851010
                        applicationLabel: MOSOLO DEBIT
                        defaultTAC: DC4000A800
                        denialTAC: '0010000000'
                        onlineTAC: DC4004A800
                        terminalFloorLimit: 100000
                        transactionLimit: 250000
                    file_type: AID
                    file_version: v2.1.5
        '404':
          description: Terminal not found
      security:
        - api_key: []
components:
  schemas:
    TerminalFileDownloadRequest:
      type: object
      required:
        - terminal_id
        - file_type
        - file_version
        - hash
        - network_token
      properties:
        terminal_id:
          type: string
          description: Terminal ID (required)
        file_type:
          $ref: '#/components/schemas/TerminalFileType'
        file_version:
          type: string
          description: version of the file
        hash:
          type: string
          description: |-
            checksum of the file
            SHA256 checksum represented as a hex string
        network_token:
          type: string
          description: network-token
    TerminalFileDownloadResponse:
      type: object
      required:
        - file_type
        - file_version
        - file_content
      properties:
        file_type:
          $ref: '#/components/schemas/TerminalFileType'
        file_version:
          type: string
          description: version of the file
        file_content:
          type: object
          description: binary content of the file, base64 encoded
    TerminalFileType:
      type: string
      enum:
        - PARAMS
        - HOTLIST
        - TAC
        - CVM
        - TAGS
        - AID
        - CAPK
        - KEYS
        - FXRATES
  securitySchemes:
    api_key:
      type: apiKey
      in: header
      name: api-key
      description: >-
        Use the API key created under your merchant account from the Paycode
        dashboard. API key is used to authenticate API requests from your
        merchant server only. Don't expose this key on a website or embed it in
        a mobile application.

````