Skip to content

Instantly share code, notes, and snippets.

@mikepaszkiewicz
Last active June 29, 2022 22:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mikepaszkiewicz/a2abfc8ab5ecac060c0616114a5858b5 to your computer and use it in GitHub Desktop.
Save mikepaszkiewicz/a2abfc8ab5ecac060c0616114a5858b5 to your computer and use it in GitHub Desktop.
//note ready_at in /quotes and ready_by in /orders are the same value
POST /quotes
{
origin:
'2000 Market Street, 2000 Market St, Philadelphia, PA 19103, USA',
destination:
'1999 North 52nd Street, , Philadelphia, PA, 19131, United States',
vendor_id,
bag_count: 1,
ready_at: '2022-06-30 07:00:00+00',
}
POST /orders
{
tip: 0,
method: 'Delivery',
source: 'Restaurant Preview Channel',
ready_by: '2022-06-30 07:00:00+00',
quote_id: quote?.quoteId,
daas_type: 'online',
scheduled: true,
seller_id: '05a3b881-ee42-11eb-a309-21dcd8197474',
external_id: 'afa5931d-a426-41b6-aa0a-a3633570d822',
order_total: 5.51,
plain_order: [
{
itemName: 'Crispy Fingers',
quantity: 1,
itemPrice: 5,
modifiersText: [],
itemInstructions: '',
},
],
customer_name: 'test',
customer_phone: '+14433869479',
delivery_address:
'1999 North 52nd Street, , Philadelphia, PA, 19131, United States',
diner_delivery_fee: 0,
special_instructions:
' | Special Instructions: DELIVERY SCHEDULED',
delivery_instructions: '',
}
-------------
result
//Order is queued on scheduled orders for pickup time sent in quotes/orders, deliver time is based on routing
{
"id": "6d428680-f7f4-11ec-ade8-c5d9025c25a6",
"created_EDT": "06/29 05:42 PM",
"order_number": 9068,
"external_id": "afa5931d-a426-41b6-aa0a-a3633570d822",
"pickup_at_est": "2022-06-30 07:00:00+00",
"delivered_at_est": "2022-06-30 07:15:59+00",
"scheduled": true,
"status": "queued"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment