# Activities

Activities record runtime actions sent by the Supervisor. Each target node receives an entry with its own status. Use the Supervisor API, `{supervisor_url}`, for these requests.

## Supported Runtimes and Actions

| Runtime | Actions |
| --- | --- |
| `iggy` | `start`, `stop`, `restart`, `reconfigure:{config_id}` |
| `connectors` | `start`, `stop`, `restart`, `reconfigure:{config_id}` |
| `mcp` | `enable`, `disable`, `start`, `stop`, `restart` |
| `kafka_gateway` | `enable`, `disable`, `start`, `stop`, `restart`, and `upgrade` on clusters |

`enable` turns on the deployment's [MCP runtime](/mcp#deployment-data) and `disable` turns it off and keeps it stopped. Both answer `202 Accepted` and change the deployment's `mcp_enabled` field. A deployment without the MCP runtime answers `400` with `deployment_runtime_missing`. A new MCP configuration version is applied by [activating it](/api/configuration), not by `reconfigure`.

For `kafka_gateway`, `enable` turns on the deployment's [Kafka gateway](/kafka-gateway) and `disable` turns it off and keeps it stopped, which changes the deployment's `kafka_gateway_enabled` field. Both answer `202 Accepted`, and `enable` answers `400` with `deployment_runtime_missing` for a deployment that cannot run the gateway, and `400` with `unsupported_runtime_action` on BYOC and On-Premise. `upgrade` runs one node at a time and answers `400` with `unsupported_runtime_action` on a standalone or Free deployment. A new Kafka gateway configuration version is applied by [activating it](/api/configuration#kafka-gateway-configuration).

## Activity Status

| Status | Meaning |
| --- | --- |
| `processing` | Action dispatched, waiting for node to complete |
| `completed` | Action finished successfully |
| `rejected` | Action failed or was rejected by the node |

## Trigger a Runtime Action

`POST {supervisor_url}/deployments/{deployment_id}/activities/{runtime}/{action}`

Execute a runtime action on all nodes (or specific nodes) in a deployment.

| Path Parameter | Values |
| --- | --- |
| `runtime` | `iggy`, `connectors`, `mcp`, `kafka_gateway` |
| `action` | `start`, `stop`, and `restart` for every runtime, `reconfigure:{config_id}` for `iggy` and `connectors`, `enable` and `disable` for `mcp` and `kafka_gateway`, and `upgrade` for `kafka_gateway` on clusters |

To target all nodes, omit the body or send `{}`:

```bash
curl -X POST {supervisor_url}/deployments/{deployment_id}/activities/iggy/restart \
-H "ld-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'
```

To select nodes, supply their IDs:

```bash
curl -X POST {supervisor_url}/deployments/{deployment_id}/activities/iggy/restart \
-H "ld-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
  "nodes": [610809900976570889]
}'
```

| Field | Required | Description |
| --- | --- | --- |
| `nodes` | No | Array of node IDs to target. Omit or send `{}` to target all nodes. |

A successful request returns `202 Accepted`.

This action requires `deployment:manage`.

***

## List Activities

`GET {supervisor_url}/deployments/{deployment_id}/activities`

Retrieve the activity log for this deployment, paginated.

```bash
curl "{supervisor_url}/deployments/{deployment_id}/activities?page=1&results=10" \
-H "ld-api-key: YOUR_API_KEY"
```

```json
{
  "items": [
    {
      "id": 1,
      "tenant_id": 1,
      "workspace_id": 1,
      "environment_id": 1,
      "deployment_id": 1,
      "author_id": 608123456789012345,
      "runtime": "iggy",
      "action": "restart",
      "node_id": 610809900976570889,
      "status": "completed",
      "created_at": "2026-03-16T12:00:00Z",
      "finished_at": "2026-03-16T12:00:05Z"
    }
  ],
  "page": 1,
  "total_results": 1,
  "total_pages": 1
}
```

This request requires `deployment:read`.

- [Configuration](/api/configuration): Versioned Iggy and connector configs
- [Observability](/api/observability): Metrics, logs, and heartbeats
- [Warden Agent](/deployments/warden): How Warden executes activities

Source: https://docs.laserdata.com/api/activities
