npm install dpay
You need to register an account from our website and then get the token from the settings page
var dpay = require("dpay")();
var params = {
auth_token:"YOUR AUTHENTICATION TOKEN",
order_code:"GENERATE UNIQUE CODE AND STORE IT ON YOUR DATABASE",
token_address:"YOUR TOKEN ADDRESS",
amount:"AMOUNT",
};
const result = await dpay.paymentIntents.create(params);
console.log(result)