Claude Code marketplace and agentaos plugin (MCP + skill) - #39
Merged
Merged
Conversation
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KdSgWa5Lf9mnHxY3x76Fy1
PancheI
added a commit
that referenced
this pull request
Sep 9, 2026
…, reusing device-code approval (#41) ## Why ChatGPT, Claude.ai and other hosted assistants cannot run the stdio MCP server or paste an API key. They speak OAuth 2.1 to a remote MCP server (MCP authorization spec: protected-resource metadata, PKCE S256, CIMD / dynamic client registration), verified against OpenAI's plugin auth doc and Claude's custom-connector article. ## What `packages/mcp-remote`: a Cloudflare Worker at `mcp.agentaos.ai/mcp`. - `@cloudflare/workers-oauth-provider` is the OAuth front door (`/authorize`, `/token`, `/register`, metadata). - The human step reuses the platform's existing device-code approval: `/authorize` starts a device code and sends the merchant to the app's approve page with a return address; `/callback` redeems it for a one-shot session, mints a normal secret key named after the client ("ChatGPT"), and seals it into the OAuth token. The session is dropped. - `/mcp` serves the same seven `agenta_pay_*` tools as the CLI over stateless Streamable HTTP, bound to that key. Revoking the key on Developers disconnects the assistant; the tools then say so. - The seven tools take a client factory (`registerPayTools(server, getClient)`, exported as `agentaos/mcp`) so the stdio CLI and the Worker share one implementation. ## Verified locally `wrangler dev --local-protocol https --host localhost:8788` against the local API and app: 401 → discovery → registration → approve page → key minted with the client's name → tokens → `tools/list` → `list_customers`, `create_checkout`; revoke → every tool refuses with the reconnect sentence. Run with the MCP SDK client and with the official MCP Inspector. ## Deploy (after the platform release that ships the approve page and `secret_keys.label`) `wrangler login` → `wrangler kv namespace create OAUTH_KV` (paste id) → `wrangler deploy` (custom domain `mcp.agentaos.ai`). Replaces #40, which GitHub closed when its base branch (#39, merged) was deleted. Includes the changeset for agentaos 3.0. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01KdSgWa5Lf9mnHxY3x76Fy1 --------- Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Claude Code marketplace and
agentaospluginAdds a Claude Code plugin marketplace to this repo so a coding agent gets AgentaOS in two commands:
What the plugin bundles
.mcp.json: theagentaosMCP server, run asnpx -y agentaos(the same npm binary as the CLI; with no arguments it serves MCP over stdio). The API key is read from the user'sAGENTAOS_GATEWAY_KEYenvironment variable, nothing is baked in.skills/agentaos/SKILL.md: a copy of the served skill at https://agentaos.ai/SKILL.md (source of truth noted at the top).README.md: install, the key export, and theclaude mcp add … -efallback for the open upstream issue with${VAR}expansion in plugin MCP configs ([BUG] env variable expansion not working in plugin .mcp.json anthropics/claude-code#9427).Validated locally
claude plugin validate .andclaude plugin validate ./plugins/agentaospass (strict).claude mcp listshowsplugin:agentaos:agentaosconnected.Safety review
🤖 Generated with Claude Code
https://claude.ai/code/session_01KdSgWa5Lf9mnHxY3x76Fy1