# standup_list

Get Standup Entries

## Beschreibung

Reads daily standup entries (Yesterday / Today / Blockers).
Unique per `(user, account, report_date)` — one per person per day.

Admin / employer see all members' entries (filter via `user_id`);
regular members see only their own.

- `blocked` is derived from `blockers.present?` when the flag
  column is nil; when explicitly set, that value wins.
- `submitted == completed_at.present?`. Drafts may be partial.
- `previous_completed: false` on a submitted entry → carryover
  signal (yesterday's plan didn't finish).
- Sorted `report_date DESC, user_id ASC`, capped at 500 rows.

## Zugriff

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

## Parameter

| Name | Typ | Pflicht | Beschreibung |
| --- | --- | --- | --- |
| `account_id` | string | Ja | Account prefix ID (e.g., acct_abc123). |
| `user_id` | string | Nein | User prefix ID (user_…) or @handle / handle (e.g., 'sam' or '@sam'). Admin/employer only for foreign users — regular members may pass their own or omit. |
| `start_date` | string | Nein | Inclusive lower bound on report_date (YYYY-MM-DD). Use alone for a single day. |
| `end_date` | string | Nein | Inclusive upper bound on report_date. Defaults to start_date when only start_date is given — pair them for a range. |

## Eingabeschema

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "account_id": {
      "type": "string",
      "description": "Account prefix ID (e.g., acct_abc123)."
    },
    "user_id": {
      "type": "string",
      "description": "User prefix ID (user_…) or @handle / handle (e.g., 'sam' or '@sam'). Admin/employer only for foreign users — regular members may pass their own or omit."
    },
    "start_date": {
      "type": "string",
      "format": "date",
      "description": "Inclusive lower bound on report_date (YYYY-MM-DD). Use alone for a single day."
    },
    "end_date": {
      "type": "string",
      "format": "date",
      "description": "Inclusive upper bound on report_date. Defaults to start_date when only start_date is given — pair them for a range."
    }
  },
  "required": [
    "account_id"
  ],
  "type": "object"
}
```

## Ausgabeschema

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "standup_entries": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Standup prefix ID (sup_…). Unique per (user, account, report_date)."
          },
          "user": {
            "type": "object",
            "properties": {
              "id": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "handle": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "name": {
                "type": "string"
              }
            }
          },
          "report_date": {
            "type": "string",
            "format": "date"
          },
          "previous": {
            "type": [
              "string",
              "null"
            ],
            "description": "Yesterday's work / outcomes."
          },
          "next": {
            "type": [
              "string",
              "null"
            ],
            "description": "Today's plan."
          },
          "blockers": {
            "type": [
              "string",
              "null"
            ]
          },
          "blocked": {
            "type": "boolean",
            "description": "Derived from blockers.present? when the flag column is nil; otherwise the stored value."
          },
          "previous_completed": {
            "type": [
              "boolean",
              "null"
            ],
            "description": "User confirmed yesterday's plan finished."
          },
          "submitted": {
            "type": "boolean",
            "description": "True iff completed_at is set — otherwise it's a draft."
          },
          "completed_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "user",
          "report_date",
          "blocked",
          "submitted"
        ]
      }
    }
  },
  "required": [
    "standup_entries"
  ],
  "type": "object"
}
```
