Paytm provides you additional JS APIs to "bridge" the gap between native and web app (e.g geolocation, contacts, gallery, camera, permission).
Note: This is an optional integration for your specific requirements. However, we recommend you to integrate these JS APIs to enhance user experience wherever required
The list of JS APIs currently supported are given below:
|paytmPushWindow is used to push a new window to show new page. It adds a page to the stack and can be launched with custom startup params.
|popWindow is used to close the current page. Can be called to exit the AppContainer.
|openInBrowser is used to download any file in Mini Apps by passing the control to mobile browser eg. PDF.
|Checks if permissions are granted/denied.
|A bridge that requests permissions from users.
|Use the bridge below to open a custom image picker on iOS/Android, and get a callback once the user has picked an image or has cancelled
|This bridge when invoked (assuming that camera permissions are already granted), opens the camera, and once the user clicks a picture, passes data to the web context.
|Improve the overall checkout experience by using the paytmSelectUserAddress API, and autofill the delivery /shipping address fields with user addresses that are saved with Paytm
|Allow a user to create the Mini App icon shortcut on their home screen.