Skip to content

Commit 4e08bab

Browse files
added additional comments
1 parent abd0e85 commit 4e08bab

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

source/test-app/app.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,13 @@ const token = jwt.sign(
3131
console.log("DoorDash API JWT: " + token);
3232

3333
const 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

3638
const axios = require('axios');
3739

40+
// Create data needed to create a new delivery
3841
const 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
5155
axios
5256
.post('https://openapi.doordash.com/drive/v2/deliveries', body, {
5357
headers: {

0 commit comments

Comments
 (0)