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

# Event envelope

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

The `type` has the form `com.rdcopilot.erp.<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": "b1370dd6-14e1-4aee-bdbd-4b0da92165e9",
  "type": "com.rdcopilot.erp.sales-order.confirmed.v1",
  "source": "/erp/v1",
  "time": "2026-11-23T07:40:00Z",
  "customerOrgId": "e008e1af-fe83-441e-8dae-e518a9f6c52a",
  "legalCompanyId": "e532fe90-4649-4d42-8767-77a0f6dc1d54",
  "aggregateType": "sales-order",
  "aggregateId": "74bf6304-7842-41e8-9928-f4420004d89c",
  "aggregateRevision": 2,
  "correlationId": "6a8b2984-79ae-42da-b009-dfabd0c2f7e1",
  "causationId": "bcf8f768-d67b-47aa-a7af-25b74eb53991",
  "actor": {
    "clientId": "9cdf2ed6-aca2-4654-9334-b958d8053885"
  },
  "data": {
    "number": "CV-1048",
    "status": "confirmed"
  }
}
```

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

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