PT-448 cross-project 'goal' view
GET/api/tasks
PT-448 cross-project "goal" view. Lists every task carrying any of the requested labels across the projects the caller can read (tenant-scoped). Requires full tasks.read (the list is not ownership-scoped, so tasks.read.own is rejected) AND projects.read (or .own) plus an active membership. A GUEST member or a projects.read.own-only caller is restricted to collaborator/creator projects. Tasks in projects the caller cannot read are omitted; cross-project dependency references are redacted (taskKey + projectId omitted, title + status replaced with sentinels, isCrossProject=true) per the PT-283 precedent, so the real key/title never leak. Each row carries project, key, title, status, priority, and isBlocked/isBlocking flags; sorted by priority (URGENT first), task key as tiebreak. Capped at the 500 highest-priority rows; truncated is true when more match. This endpoint also serves four cross-project flow roll-ups (mutually exclusive, and ignoring labels): ?ready=true — the dependency-gated ready set plus per-project agent wip (PT-667); ?review=true — the review queue (PT-602); ?blocked=true — the blocked reveal, would-be-ready tasks held out by an unfinished predecessor, each row carrying blockedBy (PT-685); and ?awaiting_decision=true — the Decisions queue (ADR-028), open agent decision-requests ordered oldest-first by askedAt, each row carrying decisionWaitMinutes, decisionQuestion, decisionOptions, decisionRequestId, and decisionAskedByUserId (PT-905). Narrow any roll-up to one project with ?projectId=<uuid>.
Request
Responses
- 200
- 400
- 401
- 403
Successful response
Bad Request — missing/empty/over-cap labels (goal view)
Unauthorized — authentication credentials are missing or invalid
Forbidden — requires full tasks.read and projects.read (or .own) plus an active membership