Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Khipu payments API client for Node.js applications.
npm install --save fi-khipu
var khipu = require('fi-khipu');
This module must be configured with your receiver ID and secret before using it:
khipu.configure(receiverId, secret);
Any other configuration options can be done directly to the config
property:
khipu.config.sslVerification = false;
A list with full configuration options will be added soon.
This module exposes convenient methods to perform the API calls:
This method is called with just a callback Function
that will receive a KhipuException
custom error object if any and a bank
Array
if any:
khipu.listBanks(function callback(err, banks) {
if (err) {
throw err;
}
//...
});
This method must be called with the payment Object
and a callback Function
that will receive a KhipuException
custom error if any and the created payment information if any:
var payment = {
subject: 'Payment subject',
amount: 100
//...
};
khipu.createPayment(payment, function callback(err, payment) {
if (err) {
throw err;
}
//...
});
This method must be called with the payment ID String
and a callback Function
that will receive a KhipuException
custom error if any and the requested payment information if any:
var paymentId = 'Aa1...Jw1';
khipu.getPaymentById(paymentId, function (err, payment) {
if (err) {
throw err;
}
//...
});
This method must be called with the payment's notification token String
and a callback Function
that will receive a KhipuException
custom error if any and the requested payment information if any:
var notificationToken = 'Aa1bB2...KhqJw1';
khipu.getPaymentByNotificationToken(notificationToken, function (err, payment) {
if (err) {
throw err;
}
//...
});
This method must be called with the payment ID String
and a callback Function
that will receive a KhipuException
custom error if any and the deleted payment information if any:
var paymentId = 'Aa1...Jw1';
khipu.deletePayment(paymentId, function (err, payment) {
if (err) {
throw err;
}
//...
});
This method must be called with the payment ID String
and a callback Function
that will receive a KhipuException
custom error if any and the refunded payment information if any:
var paymentId = 'Aa1...Jw1';
khipu.refundPayment(paymentId, function (err, payment) {
if (err) {
throw err;
}
//...
});
This is an extended Error
Object
with the following additional properties:
Object
if possible.Object
if possible.To test this module you must first clone the repository as the test
folder is excluded from npm
installations. After you've cloned the repository you must create a config.json
inside the test
folder with your receiverId
and secret
:
{
"receiverId": 10101,
"secret": "30519b...d85c51"
}
This file is git-ignored to keep this data safe.
Each test will generate a test/tests.log
file with additional information on the tests. This file is deleted and created again on each test.
FAQs
Khipu payments convenience layer for Node.js applications
We found that fi-khipu demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.