# roadmap_activities

Roadmap Activity Feed

## Beschreibung

Returns the reverse-chronological activity feed for a roadmap.
Both roadmap-level events (created / title_changed /
description_changed / archived / unarchived) and entry-level
events (entry_created / entry_title_changed /
entry_status_changed / entry_dates_changed / entry_destroyed /
entry_project_linked / entry_project_unlinked) flow into the
same feed, ordered newest first.

`payload` shape depends on the event:
- `title_changed`, `entry_title_changed`: `{from, to}`
- `entry_status_changed`: `{from, to}` (status names)
- `entry_dates_changed`: `{starts_on: {from,to}, due_on: {from,to}}`
- `entry_project_linked` / `entry_project_unlinked`:
  `{project_id, project_name}` (denormalised so the log
  survives project renames)
- `entry_created`: `{title}`
- Other events carry an empty or minimal payload.

`limit` defaults to 50, clamped to [1, 200].

## Zugriff

Zugriffsprofil: `gated`. Module: `projects_tasks`.
Die Freigabe im Profil ersetzt keine Account-, Workspace- oder Rollenberechtigung.

## Parameter

| Name | Typ | Pflicht | Beschreibung |
| --- | --- | --- | --- |
| `account_id` | string | Ja |  |
| `roadmap_id` | string | Ja | Roadmap prefix ID (rmap_…). |
| `limit` | integer | Nein | Number of rows to return. Default 50, clamped to [1, 200]. |

## Eingabeschema

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "account_id": {
      "type": "string"
    },
    "roadmap_id": {
      "type": "string",
      "description": "Roadmap prefix ID (rmap_…)."
    },
    "limit": {
      "type": "integer",
      "description": "Number of rows to return. Default 50, clamped to [1, 200]."
    }
  },
  "required": [
    "account_id",
    "roadmap_id"
  ],
  "type": "object"
}
```

## Ausgabeschema

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "activities": {
      "type": "array",
      "description": "Newest first.",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "ra_…"
          },
          "event": {
            "type": "string",
            "description": "Event name; see the description for the full list."
          },
          "payload": {
            "type": [
              "object",
              "null"
            ],
            "description": "Event-specific data; shape depends on event."
          },
          "user": {
            "type": [
              "object",
              "null"
            ],
            "description": "Actor. Null for system events.",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name"
            ]
          },
          "roadmap_entry_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "Set for entry-level events; null for roadmap-level events."
          },
          "created_at": {
            "type": "string",
            "description": "ISO 8601."
          }
        },
        "required": [
          "id",
          "event",
          "created_at"
        ]
      }
    }
  },
  "required": [
    "activities"
  ],
  "type": "object"
}
```
