Get Order [v3]
This API returns the data of order .
Query Parameters
The order_id for which the payment is being made
The invoice_id for which payment is being made
- 200
- 4XX
- 5XX
When the order is successfully fetched, the response will be as below
Schema
- Array [
- ]
- Array [
- ]
This is the date and time at which the order was created in UTC
This is the unique order_id generated by Nimbbl for the invoice_id shared by you. This will be used in subsequent API calls
Possible values: [new
]
This is the status of the order, at the time of order creation, this will always be
This is your internal unique reference identifier for this order
user object
This is the user information fetched from Nimbbl depending on the user details shared during the create order API call
This is the unique identifier for the consumer on Nimbbl
This is the mobile number of your consumer shared by you
This is the country code as defined by the Internation Telecom Union
This is the email address of your consumer stored at Nimbbl
This is the first name of your consumer stored at Nimbbl
This is the last name of your consumer stored at Nimbbl
This is the number of payment attempts made on this order, for a new order this will be 0
This field denotes the max_retries allowed for the customer to retry the payment
This is the currency code in ISO-4217 format
This is the amount before tax for your entire cart amount
This is the tax amount for your entire cart amount
This is the total amount inclusive of taxes for your entire cart amount
order_line_items object[] nullable
This contains the cart items so that they can be displayed on the checkout or cart based offers can be calculated. Cart information is typically mandatory to create an order, in case you are unable to provide cart information, please reach out to our team and we can make certain fields nullable to meet your requirements
This is the unique id of the product stored in your system
This is the title of the product that is being sold
This is the detailed description of the product being sold
This is the public URL from which the image of the product can be fetched
This is the pre tax rate of the item
This is the quantity that is being purchased
This is the rate * quantity i.e. the amount before tax
This is the tax amount on the cart item
This is the sum of amount before tax and the tax amount
address object nullable
This field contains the block of address of user
This is the first line of the address for your consumer
This is the name of the street of the address for your consumer
This is the name of the landmark of the address for your consumer
This is the name of the area of the address for your consumer
This is the name of the city of the address for your consumer
This is the name of the state of the address for your consumer
This is the pincode or zipcode of the address for your consumer
This is a name or tag given to a specific address
currency_conversion object nullable
This object is sent only if the transaction currency was changed. This object will have all the details related to currency conversion.
This is the currency code in ISO-4217 format in which the order was initiated
This is the currency code in ISO-4217 format in which the order will be processed in
This is the exchange rate used to convert amounts from original currency to converted currency
Possible values: [ALTERNATE_CURRENCY_CONFIG
]
This is the reason for currency conversion
This is the amount_before_tax
received when the order was initiated
This is the tax
when the order was initiated, if not received will be set to 0
This is the total_amount
received when the order was initiated
refund_details object nullable
This field will only come when the order_status is completed
. This object will have all the refund details for the order.
This is the currency code in ISO-4217 format in which the refund will be initiated
This is the amount which is available for refund
This is the amount which has been already refunded successfully
This is the maximum refundable amount available for the order
next object[]
The next array provides a recommendation for the next API call to be made, where multiple options are available, all of these are provided
Possible values: [payment_modes
]
To show on your checkout all the payment modes that are enabled for you and are personalised for your customer, you can call this API
Possible values: [/api/v3/payment-modes
]
This is the end point of the API that needs to be called for the above action, you will need to append the baseurl as provided in this doc
Possible values: [complete_payment
]
To complete the payment, you will need to call the API. This is currently only supported for certain pay later providers. If you don't want to natively handle the complete payment flow, you can always redirect the user using the redirect action and the Nimbbl screen will take care of completing the payment
Possible values: [/api/v3/payment
]
This is the end point of the API that needs to be called for the above action, you will need to append the baseurl as provided in this doc
Possible values: [otp
, auto_debit
]
The payment flow provides input whether the complete payment API is expecting an otp or the payment can be completed without any user input i.e. auto_debit. In the case of otp, you will need to provide a screen for the user to enter the otp, please ensure you also have provision for resend otp in case otp isn't delivered. For auto_debit, you can simply call the next API.
Possible values: [update_order
]
To update the details in an order, you can call this API
Possible values: [/api/v3/update-order
]
This is the end point of the API that needs to be called for the above action, you will need to append the baseurl as provided in this doc
{
"order_date": "2023-09-20 13:53:09",
"order_id": "o_ex1DayQOGygbpbrW",
"status": "new",
"invoice_id": "invoice_1239",
"user": {
"user_id": "user_6NGvG4wPXJmlp3DM",
"mobile_number": "9579487629",
"country_code": "+91",
"email": "akshay@nimbbl.biz",
"first_name": "Akshay",
"last_name": "Parate"
},
"attempts": 1,
"max_retries": 1,
"currency": "INR",
"amount_before_tax": 1000,
"tax": 105,
"total_amount": 1180,
"order_line_items": [
{
"sku_id": "item_2783027490",
"title": "Best Sliced Alphonso Mango",
"description": "The Alphonso mango is a seasonal fruit harvested from mid-April through the end of June. The time from flowering to harvest is about 90 days, while the time from harvest to ripening is about 15 days.The fruits generally weigh between 150 and 300 grams (5.3 and 10.6 oz), have a rich, creamy, tender texture and delicate, non-fibrous, juicy pulp. As the fruit matures, the skin of an Alphonso mango turns golden-yellow with a tinge of red across the top of the fruit",
"image_url": "https://en.wikipedia.org/wiki/Alphonso_mango#/media/File:Alphonso_mango.jpg",
"rate": 1050,
"quantity": "2",
"amount_before_tax": "2100.00",
"tax": "105.00",
"total_amount": "2205.00"
}
],
"address": {
"address_1": "1080 Beach Mansion",
"street": "Magic Beach Drive",
"landmark": "Opposite Magic Mountain",
"area": "Elyria",
"city": "Atlantis",
"state": "Castalia",
"pincode": "100389",
"address_type": "Beach House"
},
"currency_conversion": {
"original_currency": "USD",
"converted_currency": "INR",
"exchange_rate": 83.72,
"conversion_reason": "ALTERNATE_CURRENCY_CONFIG",
"original_amount_before_tax": 11.94,
"original_tax": 2.15,
"original_total_amount": 14.09
},
"refund_details": {
"refundable_currency": "INR",
"available_refundable_amount": 1180,
"refunded_amount": 0,
"total_refundable_amount": 1180
},
"next": [
{},
{},
{}
]
}
{
"order_id": "o_9yo5wxlLlbJGK6dp",
"order_date": "2021-04-15 04:34:15.990152",
"status": "new",
"invoice_id": "inv_asjjeibdhakk49hnek3",
"attempts": 0,
"currency": "INR",
"amount_before_tax": 2100,
"tax": 105,
"total_amount": 2205,
"user": {
"email": "wonderwoman@themyscira.gov",
"first_name": "Diana",
"last_name": "Prince",
"country_code": "+91",
"mobile_number": 9876543210,
"user_id": "user_78hsjkdhb2482ndk"
},
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VyX2lkIjo2LCJzdWJfbWVyY2hhbnRfaWQiOjMsImV4cCI6MTcwNzg5ODk1OSwidHlwZSI6Im1lcmNoYW50IiwiaWF0IjoxNzA3ODk3NzU5LCJpc3MiOiJ1cm46bmltYmJsIiwidG9rZW5fdHlwZSI6InRyYW5zYWN0aW9uIn0.YLpLWonfBIlB8FFBEXQcLt_JA6ymnN0zXANR1J_Bg2M",
"token_expiration": "2021-01-09T09:49:57.715413",
"refresh_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VyX2lkIjo2LCJzdWJfbWVyY2hhbnRfaWQiOjMsImV4cCI6MTcwNzg5ODk1OSwidHlwZSI6Im1lcmNoYW50IiwiaWF0IjoxNzA3ODk3NzU5LCJpc3MiOiJ1cm46bmltYmJsIiwidG9rZW5fdHlwZSI6InRyYW5zYWN0aW9uIn0.YLpLWonfBIlB8FFBEXQcLt_JA6ymnN0zXANR1J_Bg2M",
"refresh_token_expiration": "2021-01-09T09:49:57.715413",
"next": [
{
"action": "payment_modes",
"url": "/api/v3/payment-modes"
},
{
"action": "update_order",
"url": "/api/v3/update-order"
},
{
"action": "resolve_user",
"url": "/api/v3/resolve-user"
}
]
}
When the data of order cannot be fetched, the response will be as below
Schema
error object
This is the error_code generated by Nimbbl
This is a customer friendly message that can be displayed to your consumer
This explains to your team how to recover from the error
{
"error": {
"nimbbl_error_code": "INVALID_REQUEST_PARAMETER",
"nimbbl_consumer_message": "Sorry, your payment cannot be processed due to a technical error. Please try again after some time.",
"nimbbl_merchant_message": "There is an input validation error, please check the payload of your request."
}
}
When there is a problem on the server, the response will be as below
Schema
error object
This is the error_code generated by Nimbbl
This is a customer friendly message that can be displayed to your consumer
This explains to your team how to recover from the error
{
"error": {
"nimbbl_error_code": "INVALID_REQUEST_PARAMETER",
"nimbbl_consumer_message": "Sorry, your payment cannot be processed due to a technical error. Please try again after some time.",
"nimbbl_merchant_message": "There is an input validation error, please check the payload of your request."
}
}