# Bill of lading updated

> Sent when a new version of a bill of lading is attached.

`eventType` is `billOfLading.updated`.

Sent each time a new bill of lading replaces the shipment's last one, such as after a correction. Each version has its own `url`, so download the new one and keep it as the current version.

Unlike [`billOfLading.created`](https://docs.mothership.com/reference/bill-of-lading-created), this event has no `createdAt`.

## Subscribing

Add `billOfLading.updated` to a configuration's `subscribedEvents`. It needs no extra permission.

## Event data

- `shipmentId` (string): The shipment's reference number, such as `MS123456`. Pass it to Get shipment details.
- `type` (string): The kind of document. One of: `billOfLading`.
- `url` (string): Where to download the document. Download it when the event arrives. To fetch it later, call List shipment documents for a current URL.
- `expiresAt` (string, deprecated): An ISO 8601 string a year after Mothership built the event. It still goes out on every document event, but it doesn't say when `url` stops working.
- `updatedAt` (string): When Mothership built the event for the new version, as an ISO 8601 string in UTC.

## Envelope

Mothership sends a `POST` with this JSON body. The envelope is the same on every event, and `data` holds the keys above.

- `eventType` (string): The event. Always `billOfLading.updated` here. Route on it, and answer `2xx` to types you don't handle.
- `sentAt` (string): When Mothership queued the event to send, as an ISO 8601 string in UTC. Every retry and resend carries the same value, so it does not say when this attempt went out.
- `deliveryAttempt` (integer): Which send of this event this is, starting at `1`. Resends from the dashboard count too.
- `pendingRetries` (integer): How many automatic attempts are left if this one fails. `0` on the last one.

## Example request

```json Example body
{
  "eventType": "billOfLading.updated",
  "data": {
    "shipmentId": "MS123456",
    "type": "billOfLading",
    "url": "https://files.mothership.com/MS123456/billOfLading.pdf",
    "expiresAt": "2026-10-15T15:04:05.000Z",
    "updatedAt": "2026-10-08T15:04:01.000Z"
  },
  "sentAt": "2026-10-08T15:04:05.000Z",
  "deliveryAttempt": 1,
  "pendingRetries": 16
}
```