Skip to Content
Mantle MCP v0.1.0
ConceptsArchitecture Model

Architecture Model

Runtime Path

At runtime, the architecture is straightforward:

  1. MCP server is created via createServer().
  2. Client discovers tools through listTools.
  3. Agent runtime maps MCP tool schemas into AI SDK tool definitions.
  4. LLM decides and calls tools.
  5. Tool handlers execute domain logic and return structured results.

Why InMemoryTransport Matters in E2E

E2E tests use InMemoryTransport.createLinkedPair() to eliminate network transport noise while preserving the full MCP request/response boundary.

That gives high signal for:

  • tool discovery behavior
  • argument generation quality
  • server handler integration

without introducing unrelated socket/process instability.

Domain Coverage in v0.1.0

  • Chain: network metadata and block status.
  • Registry: canonical contract/token address resolution and validation.
  • Account: balances and allowances.
  • Token: metadata, resolution, and valuation interface.
  • DeFi Read: quote/liquidity/market read paths.
  • Indexer: subgraph and SQL query interfaces with policy checks.
  • Diagnostics: endpoint health and probing tools.

Operational Guardrails

Architecturally, safety is enforced before external calls:

  • endpoint policy enforcement
  • query shape and read-only restrictions
  • timeout and bounded response handling
  • explicit error typing for safe agent interpretation
Last updated on