From adcf497eb39bfa33de5accea89a09e60dc7c0d7a Mon Sep 17 00:00:00 2001 From: iamshabell <91321698+iamshabell@users.noreply.github.com> Date: Mon, 11 Dec 2023 20:03:24 +0300 Subject: [PATCH] add(docs): details on 'credit' and 'request' method responses --- apps/docs/pages/guide/credit.mdx | 13 ++++++++++++- apps/docs/pages/guide/purchase.mdx | 11 ++++++++++- 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/apps/docs/pages/guide/credit.mdx b/apps/docs/pages/guide/credit.mdx index 15c0745..31b59db 100644 --- a/apps/docs/pages/guide/credit.mdx +++ b/apps/docs/pages/guide/credit.mdx @@ -28,4 +28,15 @@ app.get('/purchase', async (req, res) => { }); -``` \ No newline at end of file +``` + +The `credit` method returns a `PaymentInfo` object. It'll return these details: + +- **`transactionId`:** This identifier is obtained from the vendor's transaction ID. It uniquely identifies the transaction in the vendor's system. + +- **`paymentStatus`:** The payment status is also retrieved from the vendor's response. It indicates the current status of the payment transaction in the vendor's system. + +- **`referenceId`:** The reference ID is specific to Marupay and is provided in Marupay's response. It serves as a unique identifier for the transaction within Marupay's system. + +These details are essential for tracking and reconciling transactions between your application, the vendor, and Marupay. Ensure that you appropriately handle and store these values for accurate record-keeping and future reference. + diff --git a/apps/docs/pages/guide/purchase.mdx b/apps/docs/pages/guide/purchase.mdx index 7ab717e..6821d69 100644 --- a/apps/docs/pages/guide/purchase.mdx +++ b/apps/docs/pages/guide/purchase.mdx @@ -23,5 +23,14 @@ app.get('/credit', async (req, res) => { } }); +``` -``` \ No newline at end of file +It'll return the same response detail as from [`credit`](credit.mdx) method `PaymentInfo` object: + +- **`transactionId`** + +- **`paymentStatus`** + +- **`referenceId`** + +Feel free to incorporate these details into your application's logic based on your specific use case and requirements. \ No newline at end of file