MCP 服务器概览
What is Snipara MCP?
Snipara MCP (snipara-mcp) is a lightweight stdio MCP connector that exposes Snipara’s hosted Project Intelligence APIs to MCP-compatible AI coding agents (Claude Code, Cursor, Codex, OpenAI Agents, etc.). It provides durable project context, reviewed memory, code-graph insights, and shared guidance so agents don’t start cold every session.
How to use it
- Quick run (no local install):
uvx snipara-mcp. - Pip install:
pip install snipara-mcp(orpip install "snipara-mcp[rlm]"for runtime helper). - Login & init:
snipara loginthensnipara initto configure a project and MCP settings. - Configure MCP clients: either point the client to the hosted HTTP endpoint (preferred if supported) or configure the client to run the local stdio command (e.g.
uvx snipara-mcp) with environment variables:SNIPARA_API_KEY,SNIPARA_PROJECT_ID(orSNIPARA_PROJECT_SLUG)- Optional:
SNIPARA_API_URL,SNIPARA_TOOL_PROFILE(coreorfull)
- Example: set env vars and run the stdio server for clients that expect a local process.
Key features
- Small stdio MCP connector exposing the same compact default MCP contract as hosted Snipara.
- 13 core agent-callable tools (retrieval, memory, inbox review, context, code graph, etc.).
- Retrieval and recall APIs:
snipara_context_query,snipara_get_chunk,snipara_recall, etc. - Durable memory and structured end-of-task commits with a
whyblock (decision, rationale, alternatives, constraints, outcome). - Unified conversational Inbox review and agent-assisted decision proposals with human-approval apply semantics.
- Configurable code-impact traversal (depth, direction, edge kinds) and code-graph utilities (
snipara_code_*). - Agent-readable tool contracts, detailed behavior annotations, and safe parameter guidance.
- Credential-free discovery for
initialize/tools/list(actual tool calls still require authentication). - Security floor: requires MCP Python SDK >= 1.28.1 (session isolation, task ownership fixes, WebSocket Host/Origin validation).
- Thin, easy-to-audit client; heavy state and processing remain on the hosted Snipara service.
Use cases
- Provide persistent project context to coding agents so they can make informed edits across sessions.
- Let agents recall past decisions, reusable memory, and team guidance when automating code changes.
- Plan and evaluate code impact and risky changes using code-graph queries and impact traversal.
- Review and apply evidence-backed ProjectDecision drafts with human admin approval.
- Support stdio-only MCP clients or local workflows where hosted HTTP streaming isn’t available.
- Integrate with IDEs, agent orchestrators, and CI tools to surface project intelligence to LLM-driven workflows.
FAQ
-
Q: When should I use the hosted HTTP endpoint vs snipara-mcp? A: Use hosted HTTP MCP when your client supports streamable HTTP (preferred). Use snipara-mcp when your client expects a local stdio process or for local compatibility.
-
Q: How do I authenticate? A: Provide
SNIPARA_API_KEYandSNIPARA_PROJECT_ID(or login viasnipara loginto store tokens in~/.snipara/tokens.json). Tools/list may be visible before auth but actual calls require credentials. -
Q: What tools are available? A: Core tools include context retrieval, search, chunk read, recall/memory APIs, inbox review, document upload/sync, settings/index operations, and code-graph tools. Full specialist tools are available with
SNIPARA_TOOL_PROFILE=full. -
Q: Is this secure for production? A: The connector enforces a security floor by requiring a recent MCP SDK with session isolation and host/origin checks. Authentication is mandatory for tool calls and the hosted service enforces access and project ownership checks.
-
Q: How do I install and develop locally? A: Install via pip or run
uvx snipara-mcp. For development:pip install -e ".[dev]", run tests withpytest, and lint withruff. -
Q: License? A: MIT.