Create Order and Process Checkout
Endpoint: POST api/v1/Instify/CreateOrder
Headers:
ACCESS- TOKEN |
---|
Request Body (JSON):
Content-Type: application/json
API Request Parameter | API Request Parameter Detail |
---|---|
payMode | Payment Mode cc – credit card dc – debit card upi- unified payments interface nb – net banking |
merchantId | Numeric value shared via mail |
productInfo | Description of the transaction or product |
amount | Transaction Amount |
OrderId | Created at authentication Api |
merchantTxnId | Unique Transaction ID |
customerName | Name of customer |
customerMobile | Mobile No |
customerEmail | Email of customer |
redirectionURL | https://redirectionURL.com |
currencyCode | inr |
{
"amount": "166",
"merchantTxnId": "Txn2024051224",
"orderId": "Order2024817",
"payMode": "cc",
"merchantId": "MerchantID",
"productInfo": "Testing",
"customerName": "Arun",
"customerMobile": "8754554852",
"customerEmail": "arun@gmail.com",
"redirectionURL":
"https://redirectionURL.com ",
"currencyCode": "inr"
}
Response (200 OK - Success):
{
"responseCode": "200",
"responseMessage": "Success",
"data": {
"url":
"https://uat.ins.com?instifi=T29qNWR2NUJGY
WcwODNrY0dvS3A3N3JaWXJ0WkdWWHA3UEo
zM05rN0JaSFREV2xVYVozOCt0Qjk5TWhibWU2
OEFGMzVQQzRVSUowVlR3MXdjeDY3T3RYQTIv
dFArTy9jQTRmN0sxUldkYTQ9"
}
}
Steps to Redirect the User:
Extract the URL: The url value is included inside the data field of the response.
Perform the Redirect: Use the extracted URL to redirect the customer to the checkout page.
Redirection url used to route back users to merchant after a transaction , if redirection url given as https://mydomain.in/redirection method then after the transaction it will get redirected to https://mydomain.in/redirection method?txnId= using the getstatus api and txnId status and details can be fetched.