Search code examples
uber-api

Uber Rush delivery update fails (sandbox)


Making the following request fails for all the deliveries I have tried (except the first one when it worked once yesterday).

curl -X PUT https://sandbox-api.uber.com/v1/sandbox/deliveries/e4084dd3-9152-4cb8-8748-2200715a5eca   -H "Authorization: Bearer <access_token>"   -d "{\"status\":\"en_route_to_pickup\"}" -H "Content-Type: application/json"

The above fails with error code 400 and body

{
  "message": "Bad request for delivery update",
  "code": "bad_delivery_update"
}

Any idea what may be wrong with the request?


Solution

  • The status that you're updating to must be part of a valid state transition, as shown in the diagram on the Delivery Statuses page. If the current status is en_route_to_pickup, then the next status must be at_pickup.