PayAgency Logo
Payout

Estimate Payout Amount API

This endpoint calculates the estimated total payout amount including MDR (Merchant Discount Rate) and transaction fees based on the provided amount, wallet ID, and card number.

API Endpoint

POST https://backend.pay.agency/api/v1/wallet/estimate-payout

Headers

Header NameDescription
Content-TypeSpecifies the content type. Always set to application/json.
AuthorizationBearer token for authentication.

Parameters

ParameterTypeDescriptionRequired
wallet_idStringWallet ID of the userYes
amountNumberTransaction amount in smallest currency unitYes
card_numberStringCredit/Debit card numberYes

Payload

The payload should be sent in JSON format. Below is the structure of the payload:

{
  "wallet_id": "WAL7825818519632620",
  "amount": 200,
  "card_number": "4111111111111111"
}

Example Responses

Success Response

{
  "data": {
    "amount_requried": 211.5,
    "wallet_balance": 1000,
    "total_fee": 11.5
  }
}

Error Response

{
  "message":"Insufficient wallet balance to complete the transaction."
}

On this page