# Update a delivery

Operation ID: `connectors.uberUpdateDelivery`

Update a delivery. POSTs the ``updates`` body to ``/customers/{customerId}/deliveries/{deliveryId}``.

## Public method

`updateDelivery`

Signature: `connectors.uber.createClient(config).updateDelivery(body)`

Return type: `Promise<UberDeliveryResponse>`

## Authentication

Classification: **AUTHENTICATED**

Schemes: `bearerAuth`

## Prerequisites

None documented.

## HTTP

`POST /connectors/uber/update-delivery`

## Path parameters

None.

## Query parameters

None.

## Body parameters

| Name | Type | Required | Format | Allowed values | Default | Nullable | Description |
|---|---|---:|---|---|---|---:|---|
| `body` | [`UberUpdateDeliveryRequest`](../models/UberUpdateDeliveryRequest.md) | Yes |  |  |  | No |  |

Request model: [`UberUpdateDeliveryRequest`](../models/UberUpdateDeliveryRequest.md)

## Request example

```json
{
  "client_id": "example-client_id",
  "client_secret": "example-client-secret",
  "customer_id": "example-customer_id",
  "delivery_id": "example-delivery_id",
  "mode": "sandbox",
  "updates": {
    "dropoff_notes": "smoke test — leave at door"
  }
}
```

## Success responses

| Status | Shape | Content type | Description |
|---|---|---|---|
| `200` | [`UberDelivery`](../models/UberDelivery.md) | application/json | Successful response |

## Success response examples

### 200

```json
{
  "complete": false,
  "courier_imminent": false,
  "created": "2026-08-17T18:20:15.487Z",
  "currency": "usd",
  "dropoff": {
    "address": "5900 Wilshire Blvd, Los Angeles, CA 90036, US",
    "detailed_address": {
      "city": "Los Angeles",
      "country": "US",
      "state": "CA",
      "street_address_1": "5900 Wilshire Blvd",
      "street_address_2": "",
      "zip_code": "+15555550123"
    },
    "location": {
      "lat": 34.062347,
      "lng": -118.358635
    },
    "name": "Repl S.",
    "notes": "smoke test — leave at door",
    "phone_number": "+15555550123"
  },
  "dropoff_deadline": "2026-08-17T19:17:34Z",
  "dropoff_eta": "2026-08-17T18:56:00.021Z",
  "external_id": "",
  "fee": 1099,
  "id": "example-id",
  "kind": "delivery",
  "live_mode": false,
  "manifest_items": [
    {
      "dimensions": {
        "depth": 20,
        "height": 20,
        "length": 20
      },
      "name": "Test Kit",
      "price": 100,
      "quantity": 1,
      "size": "small",
      "vat_percentage": 1250000,
      "weight": 300
    }
  ],
  "pickup": {
    "address": "841 S Cloverdale Ave, Los Angeles, CA 90036-4818, US",
    "detailed_address": {
      "city": "Los Angeles",
      "country": "US",
      "state": "CA",
      "street_address_1": "841 S Cloverdale Ave",
      "street_address_2": "Los Angeles, CA",
      "zip_code": "+15555550123"
    },
    "location": {
      "lat": 34.059517,
      "lng": -118.34752
    },
    "name": "Healthcheck PMC",
    "notes": "Follow big green 'Pickup' signs in the parking lot",
    "phone_number": "+15555550123"
  },
  "pickup_deadline": "2026-08-17T18:40:15Z",
  "pickup_eta": "2026-08-17T18:34:15.665Z",
  "pickup_ready": "2026-08-17T18:20:15Z",
  "quote_id": "example-quote_id",
  "status": "pending",
  "tracking_url": "https://delivery.uber.com/orders/37fb7d7b-614c-406b-abe1-f61d6250fa89?tenancyOverride=uber%2Ftesting%2Fdirect%2F56385860",
  "updated": "2026-08-17T18:20:17.899Z",
  "uuid": "example-uuid"
}
```

## Common errors

| Status | Shape | Content type | Description |
|---|---|---|---|
| `400` | [`StandardErrorResponse`](../models/StandardErrorResponse.md) | application/json | Connector validation rejected the payload, or a required field was missing or of the wrong type. |
| `401` | [`StandardErrorResponse`](../models/StandardErrorResponse.md) | application/json | The HealthCloud bearer token is missing or invalid, or the vendor rejected the supplied connector credentials. |
| `500` | [`StandardErrorResponse`](../models/StandardErrorResponse.md) | application/json | The connector failed unexpectedly. |
| `502` | [`StandardErrorResponse`](../models/StandardErrorResponse.md) | application/json | The vendor returned an application or transport-level failure. |
| `504` | [`StandardErrorResponse`](../models/StandardErrorResponse.md) | application/json | The vendor did not respond within the connector timeout. |

## Error examples

### 400 — Invalid request

```json
{
  "error": "Invalid request"
}
```

### 401 — Authorization required

```json
{
  "error": "Authorization required"
}
```

### 500 — Internal error

```json
{
  "error": "Internal error"
}
```

### 502 — Upstream vendor error

```json
{
  "error": "Upstream vendor error"
}
```

### 504 — Upstream timeout

```json
{
  "error": "Upstream timeout"
}
```

## NodeJS / TypeScript implementation

```ts
import { HCSDK } from "@healthcloudai/hc-sdk";
import type { UberUpdateDeliveryRequest } from "@healthcloudai/hc-sdk";
```

```ts
const body = {
  "client_id": "example-client_id",
  "client_secret": "example-client-secret",
  "customer_id": "example-customer_id",
  "delivery_id": "example-delivery_id",
  "mode": "sandbox",
  "updates": {
    "dropoff_notes": "smoke test — leave at door"
  }
};

const result = await connectors.uber.createClient(config).updateDelivery(body);
```

## cURL

```bash
curl -X POST \
  -H 'Authorization: Bearer <ACCESS_TOKEN>' \
  -H 'Content-Type: application/json' \
  -d '{"client_id":"example-client_id","client_secret":"example-client-secret","customer_id":"example-customer_id","delivery_id":"example-delivery_id","mode":"sandbox","updates":{"dropoff_notes":"smoke test — leave at door"}}' \
  'https://dev-api-connectors.health.cloud/connectors/uber/update-delivery'
```

## Notes

None.

## Prepared Test Console scenario

No canonical scenario is currently associated.

## Real response

No approved real integration response is currently published. Unapproved candidates are never rendered as examples.
