Introduction
The document is for 3rd party vendor that wants to vend transport tickets on our platform.
Vendors will be given MerchantKey and MerchantCode to access the trips web booking widget.
The document is for 3rd party vendor that wants to vend transport tickets on our platform.
Vendors will be given MerchantKey and MerchantCode to access the trips web booking widget.
The Api requires bearer token for authentication which is SHA512 endcoded MerchantKey:MerchantCode (https://passwordsgenerator.net/sha512-hash-generator/)
Widget base url: https://widget.staging.trips.ng
Request Headers:
Authorization: bearer + SHA512(MerchantKey:MerchantCode)
MerchantKey: {merchantkey}
MerchantCode: {merchantcode}
Content-Type: application/json
Request Headers Sample:
Authorization: Bearer abc123
Content-Type: application/json
MerchantCode: merchant code providedMethod A: Using URL Parameters Structure
https://widget.staging.trips.ng/{MerchantCode}/{MerchantHash}
Example: https://widget.staging.trips.ng/GH773-2977...8jha31/457b25...5afd
How to Use:
Replace {MerchantCode} and {MerchantHash} with your actual credentials.
Open the link in a browser or embed it in an iframe
Method B: Using Local Storage
See code snippet for React Native below:
To Get The Token
Get Token API: https://api.staging.trips.ng/api/account/gettoken
TOKEN REQUEST AND RESPONSE SAMPLE
The Api used to login to get hash token for using the trips web boking widget, see sample request model and response.
Sample Request
Last updated