The React Native SDK acts as a wrapper around the Tickpay Custom UI SDK in order to build a dynamic and responsive Checkout interface for your iOS or Android application.

Download the SDK

Generate API Key

To generate API key:
  1. Log into your Dashboard.
  2. Select the mode for which you want to generate the API key from the menu ribbon.
  3. Navigate to Settings.
  4. Click API Keys.
  5. Click Generate Key to generate key for the selected mode.

Note:
After generating the keys from the Dashboard, download and save them securely. If you do not remember your API Keys, you need to re-generate it from the Dashboard and replace it wherever required.

Note:
You have to generate separate API Keys for the test and live mode. No money is deducted from your account in test mode.

Usage

Use the index.js file within the example folder as a reference to integrate React Native with Tickpay.

Tip:
To avoid duplicate module names, make a copy of the example project onto a separate folder and run the project.

$ npm i

Steps

1. Import the Tickpay module to your component:

import Tickpay from 'react-native-customui';

2. Call the Tickpay.open method with the payment options as shown below:tick

{
var options = {
description: 'Credits towards consultation',
currency: 'INR',
key_id: '',
amount: '5000',
email: 'john.deo@example.com',
contact: '6134523455',
method: 'netbaking',
bank: 'HDFC'

}
Tickpay.open(options).then((data) => {
// handle success
alert(`Success: ${data.tickpay_payment_id}`);
}).catch((error) => {
// handle failure
alert(`Error: ${error.code} | ${error.description}`);
});
}}>

This method returns a JavaScript Promise where a then function is used for payment success and catch for payment failure.
Scroll to top
Bitnami