File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -31,10 +31,13 @@ const token = jwt.sign(
3131console . log ( "DoorDash API JWT: " + token ) ;
3232
3333const crypto = require ( 'crypto' ) ;
34- const deliveryId = crypto . randomUUID ( ) ;
34+
35+ // Generate Unique ID for Delivery
36+ const deliveryId = crypto . randomUUID ( ) ; // TODO: Replace with generated system ID
3537
3638const axios = require ( 'axios' ) ;
3739
40+ // Create data needed to create a new delivery
3841const body = JSON . stringify ( {
3942 external_delivery_id : deliveryId ,
4043 pickup_address : '901 Market Street 6th Floor San Francisco, CA 94103' ,
@@ -48,6 +51,7 @@ const body = JSON.stringify({
4851 order_value : 1999 ,
4952} ) ;
5053
54+ // Make API call, write response data with successful result, otherwise write error
5155axios
5256 . post ( 'https://openapi.doordash.com/drive/v2/deliveries' , body , {
5357 headers : {
You can’t perform that action at this time.
0 commit comments