feat(AllInOneSDK): add check to restrict app invocation (#3570)

* feat(AllInOneSDK): add plugin for Paytm All-in-One SDK

* feat(all-in-one-sdk): add check to restrict app invocation
This commit is contained in:
adarsh-chaudhary 2020-11-19 13:04:45 +05:30 committed by GitHub
parent b3d5baa46e
commit fd0cddc9d0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8,7 +8,7 @@ import { Observable } from 'rxjs';
* Paytm All-in-One SDK plugin for Cordova/Ionic Applications * Paytm All-in-One SDK plugin for Cordova/Ionic Applications
* Paytm All-in-One SDK provides a swift, secure and seamless payment experience to your users by invoking the Paytm app (if installed on your users smartphone) to complete payment for your order. * Paytm All-in-One SDK provides a swift, secure and seamless payment experience to your users by invoking the Paytm app (if installed on your users smartphone) to complete payment for your order.
* Paytm All-in-One SDK enables payment acceptance via Paytm wallet, Paytm Payments Bank, saved Debit/Credit cards, Net Banking, BHIM UPI and EMI as available in your customers Paytm account. If Paytm app is not installed on a customer's device, the transaction will be processed via web view within the All-in-One SDK. * Paytm All-in-One SDK enables payment acceptance via Paytm wallet, Paytm Payments Bank, saved Debit/Credit cards, Net Banking, BHIM UPI and EMI as available in your customers Paytm account. If Paytm app is not installed on a customer's device, the transaction will be processed via web view within the All-in-One SDK.
* For more information about Paytm All-in-One SDK, please visit https://developer.paytm.com/docs/all-in-one-sdk/ * For more information about Paytm All-in-One SDK, please visit https://developer.paytm.com/docs/all-in-one-sdk/hybrid-apps/cordova/
* *
* @usage * @usage
* ```typescript * ```typescript
@ -19,8 +19,8 @@ import { Observable } from 'rxjs';
* *
* ... * ...
* *
* For below parameters see [documentation](https://developer.paytm.com/docs/all-in-one-sdk/) * For below parameters see [documentation](https://developer.paytm.com/docs/all-in-one-sdk/hybrid-apps/cordova/)
* let paymentIntent = { mid : merchantID, orderId: orderId, txnToken: transactionToken, amount: amount, isStaging: isStaging, callbackUrl:callBackURL } * let paymentIntent = { mid : merchantID, orderId: orderId, txnToken: transactionToken, amount: amount, isStaging: isStaging, callbackUrl:callBackURL, restrictAppInvoke:restrictAppInvoke }
* *
* this.allInOneSDK.startTransaction(paymentIntent) * this.allInOneSDK.startTransaction(paymentIntent)
* .then((res: any) => console.log(res)) * .then((res: any) => console.log(res))
@ -66,7 +66,7 @@ export interface PaytmResponse{
} }
/** /**
* For below parameters see [documentation](https://developer.paytm.com/docs/all-in-one-sdk/) * For below parameters see [documentation](https://developer.paytm.com/docs/all-in-one-sdk/hybrid-apps/cordova/)
*/ */
export interface PaymentIntentModel{ export interface PaymentIntentModel{
mid : string; // Merchant ID mid : string; // Merchant ID
@ -75,4 +75,5 @@ export interface PaymentIntentModel{
amount : string; // Amount amount : string; // Amount
isStaging: boolean; // Environment isStaging: boolean; // Environment
callbackUrl: string; // Callback URL callbackUrl: string; // Callback URL
restrictAppInvoke: boolean; // To enable or disable the paytm app invocation
} }