payminto-web-sdk
v1.0.5
Published
[Documentation](https://documentation.url.com).
Downloads
4
Readme
Payminto Ngenius Web SDK (NodeJS)
Before you start, You will need your API key, Merchant ID and Outlet reference. These credentials can be gotten from the N-Genius merchant Online portal.
Services
- Request an access token
- Create an order
Getting Started
Installing SDK
npm install payminto-web-sdk
Setup & Usage
import { getAuthToken, createAnOrder, oneTimePayment, fetchOrderByReference, capturePayment, refundCapture, create3ds, resolve3ds } from 'payminto-web-sdk'
const params = {
outletRef: ``,
apiKey: ``,
MID: ``,
orderRef: ``,
paymentRef: ``,
captureRef: ``,
}
const body = {
"action": "PURCHASE",
"emailAddress": "[email protected]",
"billingAddress": {
"firstName": "Tom",
"lastName": "Test"
},
"amount": {
"currencyCode": "USD",
"value": 150
}
};
//Create an order
createAnOrder(params, body).then((data) => {
// do something with body
console.log(data)
}).catch((error) => {
// do something with error
console.log(error)
})