The request should include the transaction code in the raw request body.
curl --location 'http://sandbox.yogupay.com/auth/view-transaction' \
--header 'token: [Generated after login]' \
--data '{
"trx_code": "ECQ14Y4PQS"
}'
{
"status": 0,
"transaction": {
"id": 6537,
"transaction_code": "ECQ14Y4PQS",
"transaction_type": "MOBILE MONEY",
"transaction_source_currency_code": "KES",
"source_amount": 50,
"transaction_destination_currency_code": "KES",
"destination_amount": 50,
"transaction_charge": 0,
"total_amount_charged": 50,
"recipient_msisdn": 254702423791,
"recipient_bank_account": "",
"recipient_bank_code": "",
"recipient_email": "johndoe@yogupay.com",
"recipient_name": "John Doe",
"sender_narrative": "Payment",
"created_at": "2024-11-04T14:06:23.000Z",
"status": 2
},
"transaction_status": "Successful"
}
{
"error": "Invalid request"
}