For the complete documentation index, see llms.txt. Markdown variants are available by appending .md to any URL or sending an Accept: text/markdown header. An agent skill is available at /.well-known/agent-skills/site-skill.md.
FrakmentFrakment

MCP

Run Frakment as a Model Context Protocol server so any MCP-capable agent can browse and install components.

Frakment ships an MCP server that exposes the registry as tools. Agents call the tools instead of scraping HTML or writing custom HTTP glue.

Quick start

Tools at a glance

list_components
Every component in the registry, with name and description.
search_components
Case-insensitive substring search across name and description.
view_component
Full source, npm dependencies, and registry dependencies of one component.
get_install_command
The exact CLI command to install a component.
list_scenarios
Ready-made compositions for common UI scenarios.
compose
Components, resolved dependencies, and install command for a scenario.

Tools

list_components

Returns every component with name and description.

Input: none

Output: text list of components.

view_component

Returns the full source of one component.

PropTypeDefaultDescription
name*string—Component slug from /r/index.json.

Output: markdown with file contents, npm dependencies, and registry dependencies.

search_components

Case-insensitive substring search across name and description.

PropTypeDefaultDescription
query*string—Free-text search term.

Output: matching components with descriptions.

get_install_command

Returns the exact CLI command.

PropTypeDefaultDescription
name*string—Component slug.

Output: npx frakment@latest add <name>

list_scenarios

Returns the built-in compositions available for common UI scenarios. No parameters.

Output: a list of scenario names with one-line descriptions.

compose

Returns the components, resolved dependencies, and install command for a scenario.

PropTypeDefaultDescription
scenario*string—Scenario key from `list_scenarios`.

Output: scenario name, description, components, install command, and a note about transitive dependencies.

Supported scenarios: chat, agent-timeline, code-output, login-form, settings-panel, empty-state, search-input, status-dashboard.

Client configuration

Claude Desktop

Config lives at ~/Library/Application Support/Claude/claude_desktop_config.json on macOS, or %APPDATA%\Claude\claude_desktop_config.json on Windows.

claude_desktop_config.json
{
  "mcpServers": {
    "frakment": {
      "command": "npx",
      "args": ["-y", "@frakment/mcp"]
    }
  }
}

Cursor

Config lives at ~/.cursor/mcp.json:

mcp.json
{
  "mcpServers": {
    "frakment": {
      "command": "npx",
      "args": ["-y", "@frakment/mcp"]
    }
  }
}

Generic stdio

Any client that spawns stdio processes:

$ npx @frakment/mcp

Environment

PropTypeDefaultDescription
FRAKMENT_REGISTRYstringhttps://www.arrafi.dev/frakment/rOverride the registry base URL. Useful for local dev against http://localhost:3000.

Troubleshooting

The component name does not exist in the registry. Call list_components first to get a valid slug.

The registry is unreachable. Check FRAKMENT_REGISTRY or your network. For local dev, run FRAKMENT_REGISTRY=http://localhost:3000 npx @frakment/mcp.

Verify the client config JSON parses, and that npx -y @frakment/mcp runs from a terminal without errors.

Source

The MCP server lives in the mcp/ directory of the Frakment repo. It is a thin wrapper over the registry JSON with no interpretation logic. Browse the source on GitHub.