s-m-r-t
Open the s-m-r-t source on GitHub Switch to dark color scheme
← All packages
Agents & runtime v0.57.40 New

@happyvertical/smrt-mcp-apps

A framework-neutral, browser-only view-side bridge for portable MCP Apps: lifecycle, correlated transport, and capability gates.

Source ↗

What it gives you

A framework-neutral, browser-only view-side bridge for portable MCP Apps: lifecycle, correlated transport, and capability gates.

  1. 01McpAppBridge binds one host window and one exact origin from trusted configuration for its whole lifetime
  2. 02Implements initialize, server tools/call, ui/open-link, text ui/message, text and structured model-context updates, display-mode requests, and teardown
  3. 03Bounded JSON everywhere: nesting, array, key, and character budgets, with cycles and accessors rejected

What it is not

It is not a server adapter, host or sandbox implementation, authorization layer, or WebMCP tool registrar. No app-tools capability is advertised. Resource proxying, sampling, and downloads have no built-in adapter; an opt-in extension adapter may register a bounded contract. Consumers must keep a normal app or review URL fallback.

Svelte bindings

useMcpApp and useMcpAppIntent are imported from the explicit @happyvertical/smrt-svelte/mcp-apps subpath. useMcpApp constructs the bridge on mount and disposes it on unmount. useMcpAppIntent binds a declared view intent to a mounted registry as a component-local callable, never a remote tool.

Pinned upstream contract

The runtime schema of a pinned ext-apps revision is authoritative. Its prose examples differ from the schema in places; contract tests pin the runtime shapes explicitly.