Skip to content

feat(mcp): expose existing queued message commands - #10555

Merged
juliusmarminge merged 2 commits into
agents/mcp-thin/thread-organizationfrom
agents/mcp-thin/queue
Sep 7, 2026
Merged

feat(mcp): expose existing queued message commands#10555
juliusmarminge merged 2 commits into
agents/mcp-thin/thread-organizationfrom
agents/mcp-thin/queue

Conversation

@juliusmarminge

@juliusmarminge juliusmarminge commented Sep 7, 2026

Copy link
Copy Markdown
Member

Part 5/16 of the shared-core and MCP stack. Based on #10554. Next: #10556.

Expose queued message list/read/edit/cancel/reorder/promote through ThreadManagementService and the existing queue commands.

Output text is bounded by Unicode code points. Paging is a live offset. Queue ordering, dispatch and replay semantics remain in the existing services.

MCP-only rebuild of #8699, preserving attribution to Julius Marminge's original work. Original branches remain available for separate service follow-ups.

Validation: The composed stack passes 94 tests across 12 focused files, including shared core MCP and real MCP/V2 integration, attachment intake, project RPC/service contracts, and client model command selection. Server/contracts/shared/client-runtime typechecks and targeted format/lint/diff checks pass. New behavior coverage lives with the shared operation; no per-tool mock suite was added. Current-head CI is shown below.

Layer size: 6 files, +191/-6. No domain-service production implementation or documentation files change in this MCP layer.

Prepared with Codex in the OpenAI agent runtime.

Note

Expose six queued-message MCP tools in ThreadToolkit

  • Adds t3_queue_list, t3_queue_read, t3_queue_edit, t3_queue_cancel, t3_queue_reorder, and t3_queue_promote_to_steer MCP tools for managing queued thread runs
  • List entries cap message text at 1,000 characters; direct reads cap at 16,000 characters, both using Unicode-code-point counting via Array.from
  • Mutation handlers dispatch existing orchestration commands through a shared dispatch helper that maps failures to the unavailable MCP error
  • Registers t3_queue_list and t3_queue_read in CLAUDE_READ_ONLY_T3_MCP_ALLOWED_TOOLS and adds display names in the shared presentation registry
  • Risk: queueEntry helper in handlers.ts returns undefined for non-queued or unmatched runs, causing t3_queue_read to return invalid_request — callers passing a run ID that is not currently queued will see this failure

Macroscope summarized 0a74c93.

@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:L 100-499 changed lines (additions + deletions). labels Sep 7, 2026
@juliusmarminge juliusmarminge changed the title feat(mcp): expose existing queued message operations feat(mcp): expose existing queued message commands Sep 7, 2026
@macroscopeapp

macroscopeapp Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Not approved

Macroscope's review found this PR not approvable — This PR adds six production MCP queue tools, including destructive mutations, and expands Claude's default read-only tool allowlist. The integration coverage is useful but does not fully exercise the new handler command and failure paths.

No code changes detected at 0a74c93. Prior analysis still applies.

You can add or adjust custom eligibility rules. Learn more.

@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Thread transfer impact

⚠️ The latest CI run did not produce a thread transfer result for 0a74c93.

This comment will update automatically after the next completed run.

Comment thread apps/server/src/mcp/toolkits/thread/handlers.ts
Comment thread apps/server/src/mcp/toolkits/thread/handlers.ts Outdated
@juliusmarminge
juliusmarminge merged commit d83cbdd into t3code/codex-turn-mapping Sep 7, 2026
25 checks passed
@juliusmarminge
juliusmarminge deleted the agents/mcp-thin/queue branch September 7, 2026 21:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L 100-499 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant