Skip to content

feat(wallet-mcp): add Spectra plugin - #15

Open
GaspardPeduzzi wants to merge 1 commit into
coinbase:mainfrom
GaspardPeduzzi:add-spectra-plugin
Open

GaspardPeduzzi wants to merge 1 commit into
coinbase:mainfrom
GaspardPeduzzi:add-spectra-plugin

Conversation

@GaspardPeduzzi

Copy link
Copy Markdown

Description

Adds the Spectra Wallet MCP plugin (skills/wallet-mcp/plugins/spectra.md, version 0.1.0, external-mcp, chains base, ethereum, arbitrum, optimism, bsc, avalanche). It also appends fixed-rate to the tag vocabulary in skills/wallet-mcp/references/plugin-spec.md, the one shared-file edit the Contribution Scope allows for a new tag.

Spectra is a permissionless fixed-rate and yield-trading protocol. Principal Tokens (PT) lock a fixed rate when held to maturity; the protocol also has Yield Tokens (YT), LP pools and curated MetaVaults. The plugin uses the Spectra MCP server that Perspective hosts at https://mcp.spectra.finance/mcp/trade (Streamable HTTP, stateless, no account or API key). Its tools read markets and positions and return unsigned PT buy, sell and redeem steps {to, data, value: "0", chain_id}: an exact-amount ERC-20 approval only when the onchain allowance is short, then the Spectra router call. The server refuses calldata whose to is not the pinned router for that chain, and cross-checks each quote against the market's spot PT price.

The plugin maps chain_id to the Wallet MCP chain string. Before submitting, the agent checks the router address against a table pinned in the plugin, then submits the steps in order with send_calls once the user has confirmed the quote. It tells the agent to present rates as fixed only if the PT is held to maturity and never as guaranteed. The server hides tokenized-equity markets from all users.

Contact: https://github.com/perspectivefi/spectra-ai/issues. Docs: https://docs.spectra.finance

Change type

  • Harness integration or metadata
  • Skill workflow
  • Bug fix
  • Documentation
  • Breaking change (describe migration)

Validation

  • tools/list on https://mcp.spectra.finance/mcp/trade returns the eight spectra_* tools the plugin names. https://mcp.spectra.finance/mcp returns the six data tools, which is how ## Detection tells the two endpoints apart. Both answer tools/list with application/json and need no initialize round trip.

  • The six router addresses in ## Notes match Spectra's pinned contract table and the Spectra app's contract registry. eth_getCode returns contract code at each address on its chain.

  • A 10-unit PT buy and a 10-unit PT sell on a Base market were quoted, then built with a placeholder receiver (not submitted). Each build returned approve(<Base router>, exact amount) on the token being spent, then the router's execute(bytes,bytes[]) with TRANSFER_FROM as its first command, all with value 0. There is no permit and no embedded signature, so the batch works with the smart-contract Coinbase Wallet Account.

  • Checked by hand against references/plugin-spec.md: frontmatter enums, canonical sections and order, the authoring checklist and the contribution scope. Also checked against the evaluation criteria of the plugin-review skill, which is not in this repo; it was removed from base/skills in chore: remove wallet-mcp and base-mcp skills base/skills#171, and its last version is at base/skills@ef8bcd52. Relative links resolve under the same rule as validate_links.

  • On this branch, python3 -m unittest discover -s tests passes (38 tests) and python3 scripts/build-distributions.py dist succeeds.

  • Not run: an authenticated Wallet MCP send_calls, or any onchain transaction.

  • Generated portable manifest and MCP config validate against the vendored Agent Plugins schemas (N/A: no manifest or MCP config changes)

  • Package paths and skill references remain inside each generated plugin root (N/A: wallet-mcp is not packaged; the plugin links only to ../references/)

  • Marketplace, skills, MCP, and icon paths are valid (N/A: no changes)

  • Exactly one canonical skill library; generated copies are not committed

  • Claude compatibility metadata/endpoint and marketplace sources agree with the portable package (N/A: no changes)

  • Tool schemas, authorization, and retry behavior reviewed (the Spectra MCP needs no auth; the plugin forbids silent retries and slippage changes)

  • README and changelog updated; versions consistent (N/A: the Contribution Scope limits plugin PRs to the plugin file and the tag line)

  • No unapproved disclosures or sensitive data

  • Signed commits

Release considerations

Maintainers add the SKILL.md registry row and the conformance entry on acceptance. No skills/base-mcp/plugins/ copy is included because that folder does not exist in this repo.

As of 2026-11-03 the public Spectra catalog lists markets on Base, Ethereum, BNB Chain and Avalanche, and none on Arbitrum or Optimism. Both stay in chains because the Spectra router is deployed there and pools are permissionless.

🤖 Generated with Claude Code

Add skills/wallet-mcp/plugins/spectra.md and append fixed-rate to the tag vocabulary in plugin-spec.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant