Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Description of how to retrieve the WPF Url for Peach Payments using Node.js
var request = require('request');
exports.getPaymentUrl = function(data, callback) {
//You will need to supply values for these first four values
var params = {
'USER.LOGIN': 'xxxx',
'USER.PWD': 'xxxx',
'FRONTEND.POPUP': "false",
'NAME.GIVEN': "Ian",
'NAME.FAMILY': "Petzer",
'ADDRESS.STREET': "8 Denheath",
'ADDRESS.ZIP': "8001",
'ADDRESS.CITY': "Cape Town",
'ADDRESS.COUNTRY': "South Africa",
}'', {form: params}, function (err, res, body) {
if (err) callback(err);
var payload = {};
body.split("&").forEach(function (responseParts) {
var keyValues = responseParts.split('=');
payload[keyValues[0]] = decodeURIComponent(keyValues[1]);
callback(null, payload['FRONTEND.REDIRECT_URL']);

HI, please help me to create the same payment web app you did on safara

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment