> ## Documentation Index
> Fetch the complete documentation index at: https://razorpay-881012b3.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Check Balance of a Payment Source

> Check balance of a payment source using the Razorpay TPAP Pro API.

<div style={{display:"flex",flexWrap:"wrap",alignItems:"center",gap:"0.35rem 0.9rem",border:"1px solid rgba(128,128,128,0.28)",borderRadius:"0.5rem",padding:"0.45rem 0.75rem",margin:"0 0 1.25rem",fontSize:"0.875rem"}}>
  <span style={{fontWeight:600}}>Available in</span>
  <span>🇮🇳 India</span>
</div>

Use this endpoint to check the balance of a payment source.

<RequestExample>
  ```bash Curl theme={null}
  curl -X POST 'api.rzp.<bank>.com/v1/upi/tpap/fundsources/:fundsource_id/balance' \
  -u [YOUR_KEY_ID]:[YOUR_SECRET] \
  -H "Content-type: application/json" \
  -H "x-device-fingerprint: <device_fingerprint>" \
  -H "x-device-fingerprint-timestamp: 1496918882000" \
  -H "x-customer-reference: customer-id-from-customer" \
  -d '{
    "upi_credentials":{
        // credentials received from WebCL 
    },
    "upi_transaction_id":"123qwert12",
    "vpa":"abc@upiexample",
    "device":{
      "geocode":"1234.1213",
      "ip":"198.1.1.1"
      }
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
    "entity":"upi.fundsource.balance",
    "fundsource_id":"string",
    "currency":"string",
    "amount":"80000",
    "customer_reference":"SKALq2p",
    "upi_transaction_id":"TxnSLALQPl",
    "vpa":"string",
    "masked_account_number":"XXXXXXXXX1234",
    "upi_iin":"12MWKO02"
  }
  ```
</ResponseExample>

## Query Parameters

<ParamField query="fundsource_id" type="string" required>
  The unique identifier of the payment source.
</ParamField>

## Request Parameters

<ParamField body="upi_credentials" type="string" required>
  The encrypted UPI PIN. NPCI credentials is the output from the WebCL page.
</ParamField>

<ParamField body="upi_transaction_id" type="string" required>
  The unique identifier of the transaction across all entities, created by the originator.
</ParamField>

<ParamField body="vpa" type="string" required>
  The VPA of the customer requesting the balance.
</ParamField>

<ParamField body="device" type="object">
  Device details.
</ParamField>

<ParamField body="ip" type="string">
  The IP address of the device.
</ParamField>

<ParamField body="geocode" type="string">
  The location coordinates of the device. For example, `12.9667,77.5667`.
</ParamField>

## Response Parameters

<ResponseField name="entity" type="string">
  Name of the entity.
</ResponseField>

<ResponseField name="fundsource_id" type="string">
  Unique identifier of the payment source.
</ResponseField>

<ResponseField name="currency" type="string">
  Currency of the balance.
</ResponseField>

<ResponseField name="amount" type="string">
  The amount in the lowest denomination of the currency.
</ResponseField>

<ResponseField name="customer_reference" type="string">
  The customer reference that requested the balance.
</ResponseField>

<ResponseField name="upi_transcation_id" type="string">
  The transaction ID that brought the balance.
</ResponseField>

<ResponseField name="vpa" type="string">
  The VPA of the customer.
</ResponseField>

<ResponseField name="masked_account_number" type="string">
  The masked account number of the customer.
</ResponseField>

<ResponseField name="upi_iin" type="string">
  UPI Issuer Identification Numbers (upi\_iin) of the payment source provider issued by NPCI.
</ResponseField>
