Insert Order
Returns
Returns a response Object object
Response object child attributes
success
BooleanBoolean value indicating the success of the order insert
response
StringA message on successful creation of the order
orderId
IntegerUnique Identifier for the particular order
| Possible enum values of 'paymentMethod' |
|---|
| cash |
| credit_card |
| Possible enum values of 'creditCardType' |
|---|
| VISA |
| MASTER_CARD |
| AMEX |
| OTHER |
orderItem array pickup object dropoff object
[
{
"name":"Veggie Duck",
"unitPrice":14.95,
"quantity":2,
"addOns": ["Onion Rings","Sauce"],
"detail": "Please don't use corn in mixed vegetables"
},
{
"name":"Mango Chicken",
"unitPrice":13.95,
"quantity":2
}
]
{
"address": {
"unit": "Apt 23",
"street": "890 Geneva Ave",
"city": "San Francisco",
"state": "CA",
"zip": "94112",
"country": "United States"
}
}
{
"address": {
"unit": "Suite 12",
"street": "556 Crestlake Dr",
"city": "San Francisco",
"state": "CA",
"zip": "94132",
"country": "USA"
}
}
orderNumber
string
required
Defaults to 99qT5A
Alphanumeric identifier for the order object
customerName
string
required
Defaults to Mr. Jhon Mason
The name of the customer
customerAddress
string
required
Defaults to 556 Crestlake Dr, San Francisco, CA 94132, USA
Address of the customer
customerEmail
string
Defaults to jhonMason@gmail.com
Email Address of the customer
customerPhoneNumber
string
required
Defaults to +14152392212
Phone number of the customer with country code
restaurantName
string
required
Defaults to Popeyes Louisiana Kitchen
Name of the restaurant
restaurantAddress
string
required
Defaults to 890 Geneva Ave, San Francisco, CA 94112, United States
Address of the restaurant
restaurantPhoneNumber
string
Defaults to +14152392013
Phone number of the restaurant with country code
expectedDeliveryDate
date
Defaults to 2021-06-03
Expected delivery date in UTC for the particular order ( yyyy-mm-dd format)
expectedPickupTime
date-time
Defaults to 17:45:00
Expected pickup time in UTC for the particular order (format hh:mm:ss)
expectedDeliveryTime
date-time
Defaults to 19:22:00
Expected Delivery Time in UTC for the particular order (format hh:mm:ss)
pickupLatitude
double
Defaults to 41.53867
Pickup location latitude
pickupLongitude
double
Defaults to -72.0827
Pickup location longitude
deliveryLatitude double
Defaults to 41.53867
Delivery location latitude
deliveryLongitude double
Defaults to -72.0827
Delivery location longitude
orderItem
array of objects
Array of Order item objects
orderItem
ADD object tips double
Defaults to 2.5
Tips amount for the order tax double
Defaults to 1.5
Tax amount for the order discountAmount double
Defaults to 1.5
Discount amount for the order deliveryFee double
Defaults to 3
Delivery fee amount for the order totalOrderCost double
Defaults to 13.47
Total cost for the particular order
pickupInstruction string
Pickup related instructions for the order deliveryInstruction string
Defaults to fast
Delivery Instruction for the driver or restaurant (if given)
orderSource string
Defaults to Seamless
Source of the order
additionalId string
Defaults to 4532
Additional ID for the order
clientRestaurantId int32
Defaults to 12
Client Restaurant ID
paymentMethod string
Defaults to credit_card
Selected payment method for the order
creditCardType string
enum
Defaults to VISA
Type of the credit card ( Not needed if the payment method is 'cash' )
Allowed:
VISA``MASTER_CARD``AMEX``OTHER
creditCardId int32
Defaults to 1234
Last four digits of the credit card ( Not needed if the payment method is 'cash' )
pickup object
Pickup details breakdown
pickup object dropoff object
Dropoff details breakdown dropoff object
isCatering boolean
Defaults to false
Marker of catering order
``200 200
object
success
boolean
Defaults to true
orderId
integer
Defaults to 0
``400 400
{
"success": true,
"response": "Order inserted with id 32841107",
"orderId": 32841107
}