Skip to content

mcp

Start the MCP (Model Context Protocol) server for AI assistant integration.

Usage

bash
fcheap mcp serve

Transport

The MCP server uses stdio transport, which is the standard for local MCP servers. AI assistants like Claude communicate with it over stdin/stdout.

Claude Code Configuration

Add fcheap to your Claude Code MCP config:

json
{
  "mcpServers": {
    "file-cheap": {
      "command": "fcheap",
      "args": ["mcp", "serve"]
    }
  }
}

Available Tools

ToolDescription
fcheap_saveSave a file or directory to the stash vault
fcheap_listList all stashes, optionally filtered by tag
fcheap_infoGet detailed info about a stash
fcheap_restoreRestore a stash to a target directory
fcheap_dropPermanently delete a stash (requires force=true)
fcheap_searchSearch across all indexed stashes (keyword / semantic / hybrid)
fcheap_analyzeIndex a stash and optionally search within it
fcheap_diffCompare a stash against a target directory
fcheap_connectConnect a stash to a codebase via vecgrep semantic search to surface candidate file:line locations
fcheap_vacuumRemove orphaned metadata/index entries for stashes whose directory is gone, then compact the DB
fcheap_ttlSet or clear a stash expiry
fcheap_sweepPlan or apply deletion of expired stashes
fcheap_cleanupAnalyze cleanup candidates; apply only explicit TTLs or regenerable caches
fcheap_docsRead embedded documentation (safe list/show) or get the docs site URL

The server also exposes resources (fcheap://stashes, fcheap://stash/{id}) and prompts (investigate_stash, find_across_stashes) — see the MCP overview.

Tool Schemas

All tools use typed input structs with JSON schema auto-generation. The jsonschema tag provides the description, and json tag omitempty controls required vs optional.

go
type saveInput struct {
    Path string `json:"path" jsonschema:"Absolute path to the file or directory"`
    Name string `json:"name,omitempty" jsonschema:"Display name for the stash"`
}

Released under the MIT License.