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

# Events

> Webhook event types we deliver to your endpoint

export const webhookEventsTableColumns = [{
  "key": "name",
  "header": "Event",
  render: value => <code className="font-mono text-[13px] font-regular">{value}</code>
}, {
  "key": "resource_type",
  "header": "Resource",
  render: value => <code className="font-mono text-[13px] font-regular">{value}</code>
}, {
  "key": "description",
  "header": "Description"
}];

export const webhookEvents = [{
  "name": "account.activated",
  "resource_type": "account",
  "description": "A suspended account is reactivated."
}, {
  "name": "account.closed",
  "resource_type": "account",
  "description": "An account is permanently closed."
}, {
  "name": "account.closing",
  "resource_type": "account",
  "description": "An account begins closing and enters wind-down."
}, {
  "name": "account.opened",
  "resource_type": "account",
  "description": "A new account is opened."
}, {
  "name": "account.suspended",
  "resource_type": "account",
  "description": "An account is suspended."
}, {
  "name": "customer_authority.revoked",
  "resource_type": "customer_authority",
  "description": "A customer's authority is revoked."
}, {
  "name": "customer.closed",
  "resource_type": "customer",
  "description": "A customer profile is permanently closed."
}, {
  "name": "order.cancelled",
  "resource_type": "order",
  "description": "An order is cancelled."
}, {
  "name": "order.executing",
  "resource_type": "order",
  "description": "An order is submitted for execution."
}, {
  "name": "order.filled",
  "resource_type": "order",
  "description": "An order is fully executed and its trades are recorded."
}, {
  "name": "order.pending",
  "resource_type": "order",
  "description": "An order is waiting on a prerequisite before execution."
}, {
  "name": "order.placed",
  "resource_type": "order",
  "description": "A new order is accepted into the system."
}, {
  "name": "order.settled",
  "resource_type": "order",
  "description": "All trades on an order are settled."
}, {
  "name": "position.closed",
  "resource_type": "position",
  "description": "A position is fully closed."
}, {
  "name": "position.closing",
  "resource_type": "position",
  "description": "A position begins closing and can no longer be traded."
}, {
  "name": "position.opened",
  "resource_type": "position",
  "description": "A new position is opened."
}, {
  "name": "trade.executed",
  "resource_type": "trade",
  "description": "A trade is executed against an order."
}, {
  "name": "trade.settled",
  "resource_type": "trade",
  "description": "A trade is settled."
}];

export const Table = ({columns = [], data = [], idKey, title}) => {
  const keyField = idKey || columns[0]?.key;
  const getColWidth = (col, index) => {
    if (col.width) return col.width;
    return index === 0 ? "auto" : "minmax(0, 1fr)";
  };
  const gridTemplate = columns.map(getColWidth).join(" ");
  return <div className="w-full text-sm border border-gray-200 rounded-lg overflow-hidden" style={{
    display: "grid",
    gridTemplateColumns: gridTemplate
  }}>
      {}
      {title && <div className="py-3 px-4 font-semibold text-md text-gray-700 border-b border-gray-200" style={{
    gridColumn: "1 / -1"
  }}>
          {title}
        </div>}
      {}
      {columns.map(col => <div key={`header-${col.key}`} className="py-3 px-4 font-semibold text-[12px] text-gray-600 uppercase whitespace-nowrap bg-gray-50 border-b border-gray-200">
          {col.header}
        </div>)}
      {}
      {data.map((row, rowIndex) => columns.map((col, colIndex) => <div key={`${row[keyField]}-${col.key}`} id={colIndex === 0 ? row[keyField] : undefined} className={`py-3 px-4 text-gray-600 leading-relaxed border-b border-gray-100 ${colIndex === 0 ? "whitespace-nowrap" : ""} ${rowIndex % 2 === 0 ? "bg-white" : "bg-gray-50"}`}>
            {col.render ? col.render(row[col.key]) : row[col.key]}
          </div>))}
    </div>;
};

We send a webhook for each event listed below. Every active webhook in your account receives every event; we don't support per-event subscriptions yet.

## Event payloads

Event payloads follow the [Event](/api-reference/events/list-events) resource schema. The `name` field matches the event type in the table, and `resource` identifies the resource that changed.

As of now, events do not carry any data in the `data` field. It is always an empty object. To get the latest state, fetch the resource using `resource.id` and `resource.resource_type` (for example, call [Retrieve order](/api-reference/trading/retrieve-an-order) when `resource_type` is `order`).

```json theme={"theme":"catppuccin-mocha"}
{
  "id": "evt_abc123",
  "name": "order.filled",
  "resource": {
    "id": "ord_xyz789",
    "resource_type": "order"
  },
  "data": {},
  "created_at": "2026-01-15T10:30:00Z"
}
```

## Event types

<Table columns={webhookEventsTableColumns} data={webhookEvents} idKey="name" />
