---
updatedAt: 2026-11-12T11:24:09.000Z
agentTools:
  projectIndex: https://docs.decentro.tech/llms.txt
---

# Account Balance Callback/Webhook

# Overview

The platform can use this callback to receive the updated balance of the consumer (receiving entity) after a successful credit or when a debit happens towards a refund or settlement. This callback helps the platform maintain a running balance after each transaction. If you are looking only for the latest balance, you can also use Decentro's merchant dashboard against a consumer to see the latest balance.

A balance callback due to a credit transaction can be received for the below scenarios.

* [Generate payment link API](https://docs.decentro.tech/reference/payments_api-collectionsv3-paymentlink)
* Issue Collect Request
* [Generate Dynamic QR](https://docs.decentro.tech/reference/payments_api-collectionsv3-dynamicqr)
* Static QR Code (Under development)
* Virtual Account based collections (Under development)

A balance callback due to a debit transaction can be received for the below scenarios.

* [Refund API](https://docs.decentro.tech/reference/payments_api-collectionsv3-refund)
* Settlement-related debit to the platform's bank account

## Flow

Below is the flow for receiving the callback.

* The platform asks Decentro to configure an endpoint against which the balance callbacks will be triggered by dropping a mail at <pgsupport@decentro.tech>
* The platform creates a payment request, and a successful transaction is processed through any of the support models mentioned above
* Decentro triggers a balance callback to the configured endpoint after the [Terminal Transaction Status Callback/Webhook](https://docs.decentro.tech/reference/payments_api-collectionsv3-statuscallback) is triggered with type = CREDIT.
* The platform initiates a refund request against a transaction using the [Refund API](). The callback is also triggered with type = DEBIT in such a scenario.
* Decentro initiates a settlement to the platform's bank account per the settlement schedule. The callback is also triggered with type = DEBIT in such a scenario.

The platform can use the decentroTxnId parameter from the original transaction initiation to map the balance at its end.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "your_custom_endpoint",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://your.custom.endpoint.com"
    }
  ],
  "security": [
    {}
  ],
  "paths": {
    "/account_balance/clientcustomendpoint": {
      "post": {
        "summary": "Account Balance Callback/Webhook",
        "description": "",
        "operationId": "payments_api-collectionsv3-balancecallback",
        "parameters": [
          {
            "name": "your_custom_key_1",
            "in": "header",
            "description": "The header token shared by you should not contain any unsanitized values like @ # $ % ^ & * ! ; : ' \" ~ ` ? = + ) (",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "your_custom_key_2",
            "in": "header",
            "description": "The header token shared by you should not contain any unsanitized values like @ # $ % ^ & * ! ; : ' \" ~ ` ? = + ) (",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "callback_attempt",
                  "callback_txn_id",
                  "consumer_urn",
                  "callback_timestamp",
                  "original_callback_txn_id",
                  "type",
                  "account_balance",
                  "collection_type",
                  "decentro_txn_id",
                  "amount"
                ],
                "properties": {
                  "callback_attempt": {
                    "type": "string",
                    "description": "Number of times the callback has been attempted."
                  },
                  "callback_txn_id": {
                    "type": "string",
                    "description": "Unique identifier mapped to the callback attempt."
                  },
                  "consumer_urn": {
                    "type": "string",
                    "description": "Unique urn assigned to client that they pass in request payload for creating a payment link, collect request or dynamic QR."
                  },
                  "callback_timestamp": {
                    "type": "string",
                    "description": "Timestamp of the Callback. Not the transaction itself."
                  },
                  "original_callback_txn_id": {
                    "type": "string",
                    "description": "Unique identifier mapped to the callback."
                  },
                  "type": {
                    "type": "string",
                    "description": "Possible values = Credit or Debit"
                  },
                  "account_balance": {
                    "type": "string",
                    "description": "The updated balance of the account mapped to consumer URN"
                  },
                  "collection_type": {
                    "type": "string",
                    "description": "The method of collection. Describes whether the funds were received via a payment link, dynamic QR, collect request, or a static QR. Only applicable for collection transactions."
                  },
                  "decentro_txn_id": {
                    "type": "string",
                    "description": "The unique transaction identifier, passed against the payment request, by Decfin at the time of transaction initiation."
                  },
                  "amount": {
                    "type": "string",
                    "description": "The transaction amount."
                  },
                  "transaction_type": {
                    "type": "string",
                    "description": "Possible values: MAIN or COMMISSION"
                  },
                  "payee_account_number": {
                    "type": "string",
                    "description": "The internal account number where the funds are collected."
                  },
                  "payee_account_ifsc": {
                    "type": "string",
                    "description": "The account IFSC of the payee account number"
                  },
                  "transaction_message": {
                    "type": "string",
                    "description": "Description message to be shown after the completion of payment."
                  },
                  "transfer_type": {
                    "type": "string",
                    "description": "Values: IMPS, RTGS, NEFT. Only passed in virtual account based collections."
                  },
                  "parent_decentro_txn_id": {
                    "type": "string",
                    "description": "decentro_txn_id of the transaction that is already in terminal state."
                  },
                  "payer_account_number": {
                    "type": "string",
                    "description": "Account number of the payer/remitter. Passed only for virtual account based collections if provided by the bank partner."
                  }
                }
              },
              "examples": {
                "Success Callback": {
                  "value": {
                    "callback_attempt": 1,
                    "callback_txn_id": "8917F8EA839249A29E84757C3F8606DA",
                    "callback_timestamp": "2024-12-13T14:10:09.766745",
                    "original_callback_txn_id": "A1AA459090114441B5B2F40D1FF93851",
                    "type": "credit",
                    "account_balance": 27,
                    "decentro_txn_id": "5D7C113CA3xxxxxxxxxxxx4FB7885C6",
                    "amount": 1,
                    "payee_account_ifsc": "YExxxxxSNOC",
                    "payee_account_number": "46252xxxxxx000001",
                    "transaction_type": "MAIN",
                    "transaction_message": "CREDIT of INR 1.0000 to 4625250000000001 as part of transaction with URN 5D7C113CA3A348EDA0D4A344FB7885C6",
                    "collection_type": "e_collect",
                    "consumer_urn": "E51CDC6BCV56DF78SD52A74F1E96A239",
                    "payer_account_number": "1013xxxx66",
                    "transfer_type": "IMPS"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Correct Acknowledgement": {
                    "value": "{\n  \"response_code\": \"CB_S00000\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "response_code": {
                      "type": "string",
                      "example": "CB_S00000"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Incorrect Acknowledgement": {
                    "value": "{\n  \"response_code\": \"CB_E00009\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "response_code": {
                      "type": "string",
                      "example": "CB_E00009"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```