---
title: "Event envelope | Docs | Inventory by R&D Copilot"
description: "Every Inventory event has the same envelope; only data changes with the type of the event."
canonical: "https://inventory.rdcopilot.com/docs/events/event-envelope/"
language: en
updated: 2026-11-22
---

# Event envelope

Every Inventory event has the same envelope; only `data` changes with the type of the event.

The `type` has the form `com.rdcopilot.inventory.<event>.v1`. The last part is the version of `data`.

## Fields

| Field | Meaning |
| --- | --- |
| `specversion` | Version of the envelope format. |
| `id` | Identifier of this event. A repeated delivery of the same event has the same `id`. |
| `type` | What happened, in the form above. |
| `source` | The product that sent the event. |
| `time` | When the event happened, as a date and time with a time zone. |
| `customerOrgId` | Your organisation. |
| `legalCompanyId` | The legal company that the event belongs to, test or live. |
| `aggregateType` | The kind of record that changed. |
| `aggregateId` | The record that changed. |
| `aggregateRevision` | The revision of the record after the change. |
| `correlationId` | Ties together everything that came from one request or one flow. |
| `causationId` | The document or operation that caused this event. |
| `actor` | Who or what made the change. |
| `data` | The content of the event. Its shape depends on `type`. |

## Example

JSON

```json
{
  "specversion": "1.0",
  "id": "517ef9ce-9831-449c-bd68-d37290ecd357",
  "type": "com.rdcopilot.inventory.movement.v1",
  "source": "urn:rdcopilot:service:inventory-runtime",
  "time": "2026-11-23T07:12:00.000Z",
  "datacontenttype": "application/json",
  "customerOrgId": "690fa0e3-547f-4f93-96b7-824475cc3d7c",
  "legalCompanyId": "d84ba982-ca9a-4e91-9566-21bd23f7227b",
  "aggregateType": "inventory-balance",
  "aggregateId": "c2c684e0-3700-5969-a967-1f8b830a2012",
  "aggregateRevision": 6,
  "correlationId": "90aebca5-208b-47dd-9e6d-c9159d4aab06",
  "causationId": "46091949-3c11-414b-9157-994f3048e568",
  "actor": {
    "serviceId": "brumar-erp",
    "userId": "4e2f591e-3df0-4f36-8741-3e49134249b0"
  },
  "data": {
    "movementId": "771d53db-5d2c-4a12-b9a6-bb3c86e5eeea",
    "productId": "6cbfcba3-55fd-4cf0-9709-6e75c9717bb3",
    "locationId": "b006344d-2fae-4970-bb6f-c32877084b4f",
    "onHandDelta": "0",
    "reservedDelta": "24"
  }
}
```

Deliveries can repeat. Use `id` to skip an event you already handled. [Delivery and retries](https://inventory.rdcopilot.com/docs/events/delivery-and-retries/) says when an event is sent again.

The full rule: [Developer guide](https://rdcopilot.com/docs/events/)
