Open RanvijayChouhan12 opened 1 month ago
Please use this version: "globalpayments-api": "3.5.1-fix-4". A fix is being worked on and may be released this Thursday 5/30.
Thanks Above Solved the Previous Issue
but Now i am getting some new Error
const config = new ServicesConfig() ^
TypeError: ServicesConfig is not a constructor
at Object.
My CODE 👍🏻
const config = new ServicesConfig() .setServiceUrl(Environment.Sandbox) .setLicenseId("") // Replace with your License ID .setSiteId("") // Replace with your Site ID .setMerchantId("") // Replace with your Merchant ID .setPassword("");
Also if you could help me , Which Fileld will have What Values and Where i can get them
thanks,
Hi,
Going forward, please send all inquiries to the developers group directly. https://developer.heartlandpaymentsystems.com/Support
Specifically: developers@heartland.us
With regards to your issue. Use the below.
const config = new PorticoConfig(); config.secretApiKey = "skapi_cert_your secret api key" config.developerId = '000000'; // your dev id, if you started the cert process and received one, else use these values config.versionNumber = '0000'; // your dev version id, if you started the cert process and received one, else use these values config.serviceUrl = 'https://cert.api2.heartlandportico.com'; ServicesContainer.configureService(config);
Looks Like test Folder is Missing in the modules,
i checked the Node-modules but didn't find test Folder anywhere
Please Help with this
ERROR :
Error: Cannot find module '../../test/Integration/Gateways/Terminals/RequestIdProvider' Require stack:
MY CODE 🥇
const express = require("express"); const GlobalPayments = require("globalpayments-api"); const app = express();
app.use(express.json());
app.post("/create-payment", async (req, res) => { try { const { cardNumber, expiry, cvv, amount } = req.body; const response = await GlobalPayments.cards.charge({ cardNumber, expiry, cvv, amount, currency: "USD", });
} catch (error) { res.status(500).json({ message: error.message }); } });
app.listen(3000, () => console.log("Server running on port 3000"));