humanmade / humanmade/hm-rest-ability

Research spike: elicitation-based confirmation

Open
#33 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
PHP
Stars
2
Forks
0
Avg merge
1d 12h
Merged PRs (30d)
16

Description

Research only. Do not start implementation until this has been reviewed.

Confirmation guidance in tool descriptions (#30) is advisory — a model can ignore it. Elicitation is the MCP mechanism for a real prompt: the server asks the client to confirm before a call proceeds. Claude Code supports it. MCP Adapter v0.6.1 does not implement it.

Upstream discussion: WordPress/mcp-adapter#176. What it establishes:

- `mcp_adapter_pre_tool_call` already exists (adapter v0.5.0). A plugin can rewrite arguments or return a `WP_Error` to block a call. That's a hard stop, not a prompt — it can't ask the user anything.
- A custom pending/approved/rejected envelope was proposed and turned down. That vocabulary isn't part of the MCP protocol, so a generic client only sees text and doesn't know to poll. This also rules out a home-grown "preview then confirm" convention as a general fix.
- Elicitation needs a server-to-client channel, which over HTTP means SSE. The adapter has no SSE transport, and the maintainer doesn't expect one soon — an open stream pins a PHP worker, and WordPress runs on hosts with aggressive timeouts.
- `McpTransportInterface` is frozen public API. A plugin can register its own transport (the STDIO one already does), so an SSE transport with elicitation-based approval could be proven outside the adapter first. The maintainer explicitly asked for a runnable proof over more design discussion.

Write up:

1. Whether hm-rest-ability is the right home for an SSE transport, or whether it belongs in a separate plugin.
2. The hosting cost — a pinned PHP worker per open session is a real constraint on Altis/VIP and most managed hosts. This may be the thing that rules it out.
3. Which clients support elicitation today, and whether that's enough coverage to justify the work.
4. Prior art: `ibrahimhajjaj/abilityguard` (ability-layer approval, snapshot, rollback) and the merged `Automattic/agents-api#234`.
5. Related upstream issue WordPress/mcp-adapter#228 — a `mcp_adapter_tool_executed` action for audit logging. Independent of approval, may be worth supporting either way.

A conclusion of "not yet, hosting cost is too high" is a valid outcome. Write it down so the decision doesn't get re-litigated.

Part of #28.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading the upstream discussions WordPress/mcp-adapter#176 and #228, then inspect McpTransportInterface and the existing STDIO transport. Compare SSE elicitation support, hosting costs, client coverage, and the listed prior art, and record whether hm-rest-ability or a separate plugin is appropriate. Done means a written recommendation covering all five requested points, including a possible “not yet” conclusion.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, wordpress
Domain
api, backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.