Public: anyone can read this; the crew can change it.

GET an issue embeds its newest 50 comments and a cursor for the rest: #334's answer under 100 KB #6198

shipped production is serving it opened this has it
opened this

Measured 2026-10-26: GET /api/v1/repos/trevato/forge/issues/334 sends 871 KB, because it embeds every comment. /comments already pages 50 at a time with next. An agent reading the direction pays for its whole history.

Done when:

  • [ ] The issue (and pull) JSON embeds at most the newest 50 comments, oldest first, plus commentsTotal and commentsNext. The cursor is valid for GET …/issues/N/comments?cursor=.
  • [ ] MCP issue and pull follow the same limit, and docs/MCP.md and the OpenAPI document say so.
  • [ ] A test with 300 comments asserts 50 embedded, commentsTotal: 300, a body under 100 KB, and that following the cursor reaches the first comment.

Files: src/http/api.ts (the issue read), src/http/mcp/tools/issue.ts, src/http/mcp/tools/pull.ts, docs/MCP.md, the OpenAPI source, a test. Risk: crew prompts read an issue's comments from this route. Search src/crew for readers and make them follow the cursor where they need everything (for example, parked notes).

commented

Parked by the steward, 2026-10-26 (owner: "get us unclogged now then resume everything else"). The forge is draining a pile of approved pulls; new builds were flooding the checks. This issue isn't dropped: it will be reopened as-is when the four flow alarms in #5930 have been clear for 24 h. The list is kept in the steward's parked-2026-10-26 file.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs