Security News
Combatting Alert Fatigue by Prioritizing Malicious Intent
In 2023, data breaches surged 78% from zero-day and supply chain attacks, but developers are still buried under alerts that are unable to prevent these threats.
@transak/transak-sdk
Advanced tools
A library for decentralised applications to onboard their global user base with fiat currency.
# Using yarn
$ yarn add @transak/transak-sdk
# Using npm
$ npm install @transak/transak-sdk
import { TransakConfig, Transak } from '@transak/transak-sdk';
const transakConfig: TransakConfig = {
apiKey: '<your-api-key>', // (Required)
environment: Transak.ENVIRONMENTS.STAGING/Transak.ENVIRONMENTS.PRODUCTION, // (Required)
// .....
// For the full list of customisation options check the link below
};
let transak = new Transak(transakConfig);
transak.init();
// To get all the events
Transak.on('*', (data) => {
console.log(data);
});
// This will trigger when the user closed the widget
Transak.on(Transak.EVENTS.TRANSAK_WIDGET_CLOSE, () => {
console.log('Transak SDK closed!');
});
/*
* This will trigger when the user has confirmed the order
* This doesn't guarantee that payment has completed in all scenarios
* If you want to close/navigate away, use the TRANSAK_ORDER_SUCCESSFUL event
*/
Transak.on(Transak.EVENTS.TRANSAK_ORDER_CREATED, (orderData) => {
console.log(orderData);
});
/*
* This will trigger when the user marks payment is made
* You can close/navigate away at this event
*/
Transak.on(Transak.EVENTS.TRANSAK_ORDER_SUCCESSFUL, (orderData) => {
console.log(orderData);
transak.close();
});
Refer here for the full list of customisation options
For in-depth instructions on integrating Transak, view our complete documentation.
This guide will help you to upgrade to v2 successfully!
FAQs
Transak SDK that allows you to easily integrate fiat on/off ramp
The npm package @transak/transak-sdk receives a total of 5,024 weekly downloads. As such, @transak/transak-sdk popularity was classified as popular.
We found that @transak/transak-sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 5 open source maintainers 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
In 2023, data breaches surged 78% from zero-day and supply chain attacks, but developers are still buried under alerts that are unable to prevent these threats.
Security News
Solo open source maintainers face burnout and security challenges, with 60% unpaid and 60% considering quitting.
Security News
License exceptions modify the terms of open source licenses, impacting how software can be used, modified, and distributed. Developers should be aware of the legal implications of these exceptions.