m2pfintech
API LibraryBalance And Transactions

Debit funds from a wallet

Debit funds from a customer wallet. This API withdraws the specified amount from the wallet associated with the provided kit number.

Idempotent on the externalTransactionId field. Duplicate requests with the same ID return the original result.

The transactionType field indicates the nature of the debit. Common values are C2M (customer-to-merchant transfer), P2P (peer-to-peer transfer), and BILL_PAY (utility or bill payment).

The amount must be a positive number and must not exceed the available balance. Insufficient balance returns error code Y212 or TXN_003.

POST
/Yappay/transaction-manager/debit

Authorization

BearerAuth TenantHeader
AuthorizationBearer <token>

JWT Bearer token obtained from the /auth/login endpoint

In: header

TENANT<token>

Tenant identifier provided by M2P (e.g. ENBDTABBY)

In: header

Request Body

application/json

kitNo*string

Kit number of the card or wallet to debit

amount*number

Amount to debit. Must be greater than zero and not exceed available balance.

Formatdouble
Range0.01 <= value
currency?string

Currency code in ISO 4217 format. Defaults to INR.

Default"INR"
externalTransactionId*string

Your unique reference number for idempotency and tracking

transactionType*string

Nature of the debit. C2M for customer-to-merchant, P2P for peer-to-peer, BILL_PAY for bill payments.

Value in"C2M" | "P2P" | "BILL_PAY"
narration?string

Transaction description. Optional.

beneficiaryName?string

Name of the recipient or merchant. Optional.

Response Body

application/json

application/json

curl -X POST "https://api.m2p.com/Yappay/transaction-manager/debit" \  -H "Content-Type: application/json" \  -d '{    "kitNo": "KIT20260306001234",    "amount": 2500,    "currency": "INR",    "externalTransactionId": "ACME-TXN-20260306-002",    "transactionType": "C2M",    "narration": "Purchase at Amazon",    "beneficiaryName": "Amazon India"  }'
{
  "status": "success",
  "data": {
    "transactionId": "TXN20260306005678",
    "externalTransactionId": "ACME-TXN-20260306-002",
    "amount": 2500,
    "availableBalance": 17500,
    "transactionStatus": "COMPLETED",
    "transactionDate": "2026-03-06T11:00:00Z"
  }
}

{
  "result": null,
  "exception": {
    "detailMessage": "Not enough balance in the account",
    "shortMessage": "Insufficient balance",
    "errorCode": "Y601",
    "languageCode": "en"
  },
  "pagination": null
}