Skip to main content

Test item additions by a shopper

Simulate a shopper being asked by the customer to add an item to the order.

The following request specifies the shopper ID 21850710, the order ID a1b2c3, and the item UPC 123456789012.

curl --request POST \
--url 'https://<instacart_development_domain>/v2/fulfillment_sandbox/shoppers/21850710/orders/a1b2c3/items' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"delivered_count": 10,
"item": {
"upc": "123456789012"
},
"scans": [
{
"scanned_string": "123456789012",
"scanned_string_type": "upca"
}
]
}'

The response confirms that the item is added.

{
"success": true
}

To verify the item details are correct, get the order by using the Fulfillment API, and then find the item in the response.

curl --request GET \
--url 'https://<instacart_development_domain>/v2/fulfillment/users/kamalsingh/orders/a1b2c3' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \