0.0.6 • Published 2 years ago
payed-terminal v0.0.6
How to install
npm install --save payed-terminalHow to use
- Import the library
import { PayedTerminal } from "payed-terminal"- Create an instance using your application id
const appId = "your-app-id" //gotten from the payed web portal
const terminalInstance = new PayedTerminal(appId);- Initiate a transaction
const transactionReference = "your-unique-transaction-reference"
const totalPrice = 120 //your price in Naira
//optionally call this endpoint to append lines to the printout
terminalInstance.appendToPrintOutOnSuccess({
"Customer": "09064082341"
})
terminalInstance.initiatePayment(transactionReference, totalPrice)- You can retrieve the terminal id
const terminalId = terminalInstance.getTerminalId()