RN: PaymentSDK Initial setup
Enable deep linking in ANDROID:
- To create a link to your app content, add an intent filter that contains these elements and attribute values in your AndroidManifest.xml:
Include theÂ
BROWSABLE
 category. It is required in order for the intent filter to be accessible from a web browser. Without it, clicking a link in a browser cannot resolve to your app.Also include theÂ
DEFAULT
 category. This allows your app to respond to implicit intents. Without this, the activity can be started only if the intent specifies your app component name.To accept the URIs that begin with “chaipay://checkout“
Enable deep linking in iOS:
To add the url schemes to the app, Go to ProjectSettings -> info
Add inside the URL types
- Should include the application url schemes in info.plist
LSApplicationQueriesSchemes - Specifies the URL schemes you want the app to be able to use with the canOpenURL: method of the UIApplication class.
To use the library:
- Add .npmrc file to the project
- In that file, add the following code and save it
- Go. to project terminal, run the following code
After successful installation, it will be shown in package.json under dependencies
- Import the library as below:
- Sample Payload containing the payment details:
- Initialise the checkout instance as below:
Params | Data type | Mandatory | Description |
---|---|---|---|
env | String | yes | env type. e,g "dev" "prod" |
callbackFunction | func | yes | returns the success and failure callback. |
redirectUrl | String | yes | redirect url for the app |
secretKey | String | yes | provided secret key |
chaipayKey | String | yes | provided chaipaykey |
Sample Response Payload:
Success callback :
Failure Callback:
Steps for Signature Hash Generation