reversal
Reverse an M-Pesa transaction paid into your shortcode by providing the receipt ID and amount to refund.
Instructions
Reverse a transaction that was paid into your shortcode.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"transactionId": "<transactionId>",
"amount": "<amount>"
},
"name": "reversal"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| amount | Yes | Amount in KES, whole numbers only. | |
| remarks | No | Reversal | |
| resultUrl | No | ||
| transactionId | Yes | M-Pesa receipt number of the transaction to reverse. | |
| receiverShortCode | No | Shortcode that received the money. |