Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

We highly recommend that when you receive a notification from us, even after checking to ensure the hash values match, you should initiate a get transaction status request to us with either the paymentReference or transactionReferenceor transactionReference to confirm the actual status of that transaction before updating the records on your database. 

Info
titleEndpoint
GET: https://sandbox.monnify.com/api/v1

This endpoint is protected with OAuth 2.0 Bearer token. To find out more about authorization for Monnify endpoints, check Here

Endpoint URL: {{base_url}}/api/v2/merchant/transactions/query

...

Please note that this endpoint is protected using basic authentication. We’ve touched on Basic Authentication in the Authentication section of this document.

HTTP Method: GET

Info

The {{base_url}} for test is https://sandbox.monnify.com but when you go live, it changes to the live url

You can get the transaction status with a simple GET request to the get status endpoint and endpoint and simply add either of the following query params in the table below

Request

Field

Description

paymentReference

Unique reference generated by the merchant for each transaction. 

transactionReference

Unique transaction reference generated by Monnify for each transaction

Here is a sample request and response

Get Transaction Status Request

Get Transaction Status Request
Code Block
languagejs
themeRDark
titleGet Transaction Status Requestjson
Request Headers
Authorization:"Basic TUtfUFJPRF9XV0RYRktCN1paOkVUOVJMU1dESjNEN1FYRE44UUNSTVlSTlBCM1czRUFL"

Request URL
GET https://sandbox.monnify.com/api/v1v2/merchant/transactions/query?paymentReference=reference12345

Or 

GET https://sandbox.monnify.com/api/v1v2/merchant/transactions/query?transactionReference=MNFY|20190809123429|000000 
Code Block
languagejs
themeRDark
title

Get Transaction Status Response

Likely responses include: PAID, OVERPAID, PARTIALLY_PAID, PENDING, ABANDONED, CANCELLED, FAILED, REVERSED, EXPIRED.


Success response

Expand
Code Block
languagejson
{
    "requestSuccessful": true,
    "responseMessage": "success",
    "responseCode": "0",
    "responseBody": {
        "transactionReference": "MNFY|87|20230629132018|049239",
        "paymentReference": "MNFY|87|20230629132018|049239",
        "amountPaid": "200.00",
        "totalPayable": "200.00",
        "settlementAmount": "196.77",
        "paidOn": "29/06/2023 01:20:18 PM",
        "paymentStatus": "PAID",
        "paymentDescription": "Tes",
        "currency": "NGN",
        "paymentMethod": "ACCOUNT_TRANSFER",
        "product": {
            "type": "RESERVED_ACCOUNT",
          
"createdOn": "2019-08-09T18:52:45.000+0000",
  "reference": "xnkxxbbdmpjnckmcfkcl"
        },
        "cardDetails": null,
        "accountDetails": {
            "accountName": "BENJAMIN CHUKWUEMEKA ONONOGBU",
            "accountNumber": "*******3241",
            "bankCode": "100004",
            "amountPaid": "200.00",
            "sessionId": "100004230629121914104830107292",
            "destinationAccountNumber": "7025415989",
            "destinationAccountName": null,
            "destinationBankCode": "035",
            "destinationBankName": "Wema bank",
            "bankName": null
        },
        "accountPayments": [
            {
                "accountName": "BENJAMIN CHUKWUEMEKA ONONOGBU",
                "accountNumber": "*******3241",
                "bankCode": "100004",
                "
amount
amountPaid": 
100.00,
"200.00",
                "sessionId": "100004230629121914104830107292",
                "
currencyCode
destinationAccountNumber": "7025415989",
                "
NGN
destinationAccountName": null,
                
"customerName
"destinationBankCode": "035",
                "destinationBankName": "
Test Reserved Account",
Wema bank",
                "bankName": null
            }
        ],
        "customer": {
            "
customerEmail
email": "test@tester.com",
            "name": "John Doe"
        },
        "metaData": {}
    }
}

Pending Response

Expand
Code Block
languagejson
{
    "requestSuccessful": true,
    "responseMessage": "success",
    "responseCode": "0",
    "responseBody": {
        "transactionReference": "MNFY|44|20220407112123|000684",
        "paymentReference": "130i0o0hfhlaad0",
        "amountPaid": "0.00",
        "totalPayable": "0.00",
        "settlementAmount": null,
        "paidOn": null,
        "paymentStatus": "PENDING",
        "paymentDescription
": "Test Reserved Account
": "Trial transaction",
        "currency": "NGN",
        "paymentMethod": "CARD",
        "product": {
            "type": "WEB_SDK",
            "reference": "130i0o0hfhlaad0"
        },
        "cardDetails": {
            "cardType": "Sandbox Card Scheme",
            "last4": "0007",
            "expMonth": "12",
            "expYear": "22",
            "bin": "520000",
            "bankCode": null,
            "bankName": null,
            "reusable": false,
            "countryCode": null,
            "cardToken": null,
            "supportsTokenization": false,
            "maskedPan": "520000******0007"
        },
        "accountDetails": null,
        "accountPayments": [],
        "customer": {
            "email": "stephen@ikhane.com",
            "name": "Stephen Ikhane"
        },
        "metaData": {}
    }
}

Expired Response

Expand
Code Block
{
    "requestSuccessful": true,
    "responseMessage": "success",
    "responseCode": "0",
    "responseBody": {
        "transactionReference": "MNFY|02|20220318085941|000387",
        "paymentReference": "123031klsaad0",
        "amountPaid": "0.00",
        "totalPayable": "0.00",
        "settlementAmount": null,
        "paidOn": "18/03/2022 09:30:42 AM",
        "paymentStatus": "EXPIRED",
        "paymentDescription": "Trial transaction",
        "currency": 
"PAID
"NGN",
        "paymentMethod": "ACCOUNT_TRANSFER",
        "product": {
            "type": "API_NOTIFICATION",
            "reference": "123031klsaad0"
        },
        "cardDetails": null,
        "accountDetails": null,
        "accountPayments": [],
        "customer": {
            "email": "stephen@ikhane.com",
            "name": "Stephen Ikhane"
        },
        "metaData": {}
    }
}

Failed Response

Expand
Code Block
{
    "requestSuccessful": true,
    "responseMessage": "success",
    "responseCode": "0",
    "responseBody": {
        "transactionReference": "MNFY|44|
20190809123429
20220407112123|
000000
000684",
        "paymentReference": "130i0o0hfhlaad0",
        "amountPaid": "0.00",
        "totalPayable": "0.00",
        "settlementAmount": null,
    
"reference12345"
    "paidOn": null,
        "paymentStatus": "FAILED",
        "paymentDescription": "Trial transaction",
        "currency": "NGN",
        "paymentMethod": "CARD",
        "product": {
            "type": "WEB_SDK",
            "reference": "130i0o0hfhlaad0"
        },
        "cardDetails": {
            "cardType": "Sandbox Card Scheme",
            "last4": "0007",
            "expMonth": "12",
            "expYear": "22",
            "bin": "520000",
            "bankCode": null,
            "bankName": null,
            "reusable": false,
            "countryCode": null,
            "cardToken": null,
            "supportsTokenization": false,
            "maskedPan": "520000******0007"
        },
        "accountDetails": null,
        "accountPayments": [],
        "customer": {
            "email": "stephen@ikhane.com",
            "name": "Stephen Ikhane"
        },
        "metaData": {}
    }
}