Auth
- POSTAnonymous user
- POSTLogin with phone
- POSTLogin with email
- POSTLogin with whatsapp
- POSTLogin with password
- POSTVerify OTP
- POSTRegister with phone
- POSTRegister with email
- POSTRegister with whatsapp
- POSTRegister with password
- GETRetrieve a user
- PUTUpdate a user
- GETRetrieve a profile image
- PUTUpdate profile image
- POSTAdd profile image
- DELDelete profile image
- PUTDeactivate account
- POSTRefresh access token
- POSTChange password
- POSTForgot password
- POSTReset password
- GETRetrieve user notification preferences
- PUTUpdate user notification preferences
- POSTCreate user notification preferences
- POSTGenerate OTP
- POSTLogout user
- POSTCheck email/phone verification status
Catalog
Carts
- POSTCreate cart
- GETRetrieve cart detail
- DELDelete cart
- GETRetrieve cart using user id
- DELDelete cart using user id
- POSTAdd/delete cart item
- POSTUpdate cart address
- POSTApply coupon
- DELRemove coupon
- POSTRedeem loyalty points
- DELRemove loyalty points
- POSTUse credit balance
- DELRemove credit balance
- POSTRedeem gift card
- DELRemove gift card
- GETRetrieve wishlist
- POSTAdd product to wishlist
- DELDelete product from wishlist
Coupons & promotions
Customers
Orders
Shipping
Analytics
Campaigns
Juspay
Create order in juspay
Juspay
Create order in juspay
Creates an order in the Juspay system and fetches the corresponding client_auth_token. To be used for Express Checkout integration.
POST
/
payments
/
juspay
/
create-order
curl --request POST \
--url https://staging.api.commercengine.io/api/v1/{store_id}/storefront/payments/juspay/create-order \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"order_number": "<string>",
"return_url": "<string>"
}'
{
"message": "<string>",
"success": true,
"content": {
"data": {
"id": "<string>",
"udf10": "<string>",
"udf9": "<string>",
"udf8": "<string>",
"udf7": "<string>",
"udf6": "<string>",
"udf5": "<string>",
"udf4": "<string>",
"udf3": "<string>",
"udf2": "<string>",
"udf1": "<string>",
"status_id": "<string>",
"status": "<string>",
"return_url": "<string>",
"refunded": false,
"product_id": "<string>",
"payment_links": {
"web": "<string>",
"mobile": "<string>",
"iframe": "<string>"
},
"order_id": "<string>",
"merchant_id": "<string>",
"juspay": {
"client_auth_token": "<string>",
"client_auth_token_expiry": "<string>"
},
"date_created": "<string>",
"customer_phone": "<string>",
"customer_id": "<string>",
"customer_email": "<string>",
"currency": "<string>",
"amount_refunded": 123,
"amount": 123
}
}
}
Authorizations
Access token
Response
200
application/json
OK
curl --request POST \
--url https://staging.api.commercengine.io/api/v1/{store_id}/storefront/payments/juspay/create-order \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"order_number": "<string>",
"return_url": "<string>"
}'
{
"message": "<string>",
"success": true,
"content": {
"data": {
"id": "<string>",
"udf10": "<string>",
"udf9": "<string>",
"udf8": "<string>",
"udf7": "<string>",
"udf6": "<string>",
"udf5": "<string>",
"udf4": "<string>",
"udf3": "<string>",
"udf2": "<string>",
"udf1": "<string>",
"status_id": "<string>",
"status": "<string>",
"return_url": "<string>",
"refunded": false,
"product_id": "<string>",
"payment_links": {
"web": "<string>",
"mobile": "<string>",
"iframe": "<string>"
},
"order_id": "<string>",
"merchant_id": "<string>",
"juspay": {
"client_auth_token": "<string>",
"client_auth_token_expiry": "<string>"
},
"date_created": "<string>",
"customer_phone": "<string>",
"customer_id": "<string>",
"customer_email": "<string>",
"currency": "<string>",
"amount_refunded": 123,
"amount": 123
}
}
}