Fetch Order

This endpoint is used to fetch an order to verify its status

GET https://exchanger-api.fuspay.finance/api/v1/no-auth/PartnerP2P/FetchOrder?partner_order_id=009677098d274862bdb2bdfc39946dd2/

Order Status

INITIATED- We have the order on queue but not processed

PENDING - Order is open / pending

CANCELED - Order has been canceled

COMPLETED- Order has been completed and payment was made

EXPIRED- Order has expired

FAILED- Request cancelled by user, the customer canceled the payment on mpesa

Payment Status

PENDING - Order payment is not received yet

PAID - Order payment has been completed and payment was made by the Buyer

REFUND - Buyer was refunded

Query Parameters

NameTypeDescription

partner_order_id*

String

the id of the order generated

Headers

NameTypeDescription

Authorization*

String

partners public key

Content-Type*

String

application/json

{
  "status": "success",
  "messsage": "",
  "data": {
        "payment": {
            "status": "PENDING | PAID | REFUND"

            },
        "virtual_account": {
        "amount": "",
        "account_name": "",
        "bank_name": "",
        "account_number": ""
      },
     "order_details": {
     "status": "PENDING | COMPLETED | EXPIRED | CANCELED",
     "partner_order_id": "",
     "intrapay_order_reference": ""
     }

 }

}

Example Request- Code

const fetch = require('node-fetch');

fetch("https://exchanger-api.fuspay.finance/api/v1/no-auth/PartnerP2P/FetchOrder?partner_order_id=xxxxx", {
  "method": "GET",
  "headers": {
    "Content-Type": "application/json",
    "Authorization": "Bearer pk_partner_xxxx",
    "cookie": "connect.sid=s%253AoNBPv4ez8npeuKVKlS9KwX_1Dshiamlf.n8opjPuoF3XsU%252Be0VTLMUe6xzeAXmpCfQrpW9KW1KDs"
  }
})
  .then(response => console.log(response))
  .catch(err => console.error(err));

Last updated