> ## Documentation Index
> Fetch the complete documentation index at: https://handbook.nyotaimara.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Delivery Estimates: Get Live Quotes from Uber Direct

> Request real-time delivery fee quotes and ETAs from Uber Direct by providing pickup and dropoff coordinates for your Nairobi routes.

Before dispatching an order, get a live delivery quote from Uber Direct. The estimate endpoint returns the delivery fee in KES and an ETA so your customers know exactly what to expect before they commit.

This endpoint requires the `X-Organization-Id` header and the `logistics:delivery:read` permission.

***

## Request a delivery estimate

Send a `POST` request to `/v1/logistics/estimate` with the pickup and dropoff locations. Include both a human-readable address and GPS coordinates for accurate routing.

```bash theme={null}
curl -X POST https://api.nyotaimara.com/v1/logistics/estimate \
  -H "Authorization: Bearer <your_token>" \
  -H "X-Organization-Id: org_01j9kxp8a3bvc0nqrtzwmde4fy" \
  -H "Content-Type: application/json" \
  -d '{
    "pickup": {
      "address": "14 Mombasa Road, Industrial Area, Nairobi",
      "lat": -1.3031,
      "lng": 36.8479
    },
    "dropoff": {
      "address": "45 Ngong Road, Upper Hill, Nairobi",
      "lat": -1.2966,
      "lng": 36.8040
    }
  }'
```

**Response:**

```json theme={null}
{
  "success": true,
  "data": {
    "fee": 35000,
    "quoteId": "quote_uber_8f3a9c1e4b2d",
    "eta": "2025-11-04T11:45:00.000Z"
  }
}
```

<Note>
  The `fee` is returned in the **lowest currency denomination** from Uber Direct. For KES, this means the value is in cents — divide by 100 to get the amount in shillings. In the example above, `35000` = **350 KES**.
</Note>

***

## Use the quote ID

Save the `quoteId` from the estimate response. When you are ready to dispatch, pass this ID when creating the actual delivery to lock in the quoted price and ETA.

<Tip>
  Quote IDs have a short validity window. Request an estimate close to the time of dispatch rather than hours in advance.
</Tip>

***

## Request body reference

| Field             | Type   | Required | Description                         |
| ----------------- | ------ | -------- | ----------------------------------- |
| `pickup.address`  | string | Yes      | Human-readable pickup address       |
| `pickup.lat`      | number | Yes      | Pickup latitude (decimal degrees)   |
| `pickup.lng`      | number | Yes      | Pickup longitude (decimal degrees)  |
| `dropoff.address` | string | Yes      | Human-readable dropoff address      |
| `dropoff.lat`     | number | Yes      | Dropoff latitude (decimal degrees)  |
| `dropoff.lng`     | number | Yes      | Dropoff longitude (decimal degrees) |

***

## Response field reference

| Field     | Type   | Description                                                 |
| --------- | ------ | ----------------------------------------------------------- |
| `fee`     | number | Delivery fee in lowest denomination (divide by 100 for KES) |
| `quoteId` | string | Uber Direct quote ID — use when booking the delivery        |
| `eta`     | string | Estimated dropoff time (ISO 8601 UTC)                       |
