Skip to main content
Glama

Evidence MCP Server

An MCP (Model Context Protocol) server that provides tools for AI assistants to help users create Evidence reports and dashboards.

Installation

# Clone and install
git clone https://github.com/jaho5/evidence-mcp.git
cd evidence-mcp
uv sync

Related MCP server: DBT Core MCP Server

Usage

# Run the MCP server
uv run evidence-mcp

# With custom Evidence project path
EVIDENCE_MCP_EVIDENCE_PROJECT_PATH=/path/to/project uv run evidence-mcp

Configuration

Environment variables:

Variable

Default

Description

EVIDENCE_MCP_EVIDENCE_DEV_URL

http://localhost:3000

Evidence dev server URL

EVIDENCE_MCP_EVIDENCE_PROJECT_PATH

-

Path to Evidence project

EVIDENCE_MCP_TRANSPORT

stdio

Transport mode: stdio, sse

Tools

get_metadata

Returns database schema from Evidence's DuckDB connection.

read_docs

Retrieves Evidence documentation using hierarchical lookup.

edit_page

Proposes changes to the current Evidence markdown page.

debug_code

Analyzes validation errors and suggests fixes.


Claude Code Setup

Add to your Claude Code MCP settings (~/.claude.json):

{
  "mcpServers": {
    "evidence-mcp": {
      "command": "uv",
      "args": ["run", "--directory", "/path/to/evidence-mcp", "evidence-mcp"],
      "env": {
        "EVIDENCE_MCP_EVIDENCE_PROJECT_PATH": "/path/to/your/evidence/project"
      }
    }
  }
}

Or add via CLI:

claude mcp add evidence-mcp -- uv run --directory /path/to/evidence-mcp evidence-mcp

To verify installation:

claude mcp list

Claude Desktop Setup

Add to Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json on macOS or %APPDATA%\Claude\claude_desktop_config.json on Windows):

{
  "mcpServers": {
    "evidence-mcp": {
      "command": "uv",
      "args": ["run", "--directory", "/path/to/evidence-mcp", "evidence-mcp"],
      "env": {
        "EVIDENCE_MCP_EVIDENCE_PROJECT_PATH": "/path/to/your/evidence/project"
      }
    }
  }
}

Programmatic Usage (MCP Client)

import asyncio
from mcp import ClientSession, StdioServerParameters
from mcp.client.stdio import stdio_client

async def main():
    server_params = StdioServerParameters(
        command="uv",
        args=["run", "--directory", "/path/to/evidence-mcp", "evidence-mcp"],
        env={
            "EVIDENCE_MCP_EVIDENCE_PROJECT_PATH": "/path/to/your/evidence/project"
        }
    )

    async with stdio_client(server_params) as (read, write):
        async with ClientSession(read, write) as session:
            # Initialize the connection
            await session.initialize()

            # List available tools
            tools = await session.list_tools()
            print("Available tools:", [t.name for t in tools.tools])

            # Call get_metadata
            result = await session.call_tool("get_metadata", arguments={})
            print("Metadata:", result.content)

            # Call read_docs
            result = await session.call_tool("read_docs", arguments={
                "doc_type": "charts",
                "component": "LineChart"
            })
            print("Docs:", result.content)

asyncio.run(main())

With OpenAI Agents SDK

First, run the server in SSE mode:

EVIDENCE_MCP_TRANSPORT=sse \
EVIDENCE_MCP_EVIDENCE_PROJECT_PATH=/path/to/your/evidence/project \
uv run evidence-mcp

Then use HostedMCPTool to connect:

from agents import Agent, HostedMCPTool

agent = Agent(
    name="Evidence Assistant",
    instructions="Help users create Evidence reports and dashboards.",
    tools=[
        HostedMCPTool(
            tool_config={
                "type": "mcp",
                "server_label": "evidence",
                "server_url": "http://localhost:8000/sse",
                "require_approval": "never",
            }
        )
    ],
)

Development

# Install with dev dependencies
uv sync --extra dev

# Run tests
uv run pytest

# Run tests with coverage
uv run pytest --cov=evidence_mcp

# Lint
uv run ruff check

# Format
uv run ruff format

Available Tools

4 tools
debug_codeC

Analyzes validation errors and suggests fixes.

Examines the provided errors and page content to identify issues and generate actionable fix suggestions.

Returns: Dictionary with 'analysis', 'suggestions' list, and optionally 'fixed_content'

ParametersJSON Schema
NameRequiredDescriptionDefault
errorsYes
page_contentYes

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description should disclose behavioral traits; it mentions returning a dictionary with suggestions but does not confirm if the tool modifies state, requires permissions, or has side effects.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description has some redundancy (first sentence rephrased in second) and could be more concise, but it is structured with a summary and return list.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema and no annotations, the description is incomplete; it does not explain the error format, page content expectations, or details of the analysis dictionary.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, and the description does not add meaning beyond parameter names—'errors' and 'page_content' are not clarified in structure or format.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool analyzes validation errors and suggests fixes, differentiating it from siblings like edit_page, get_metadata, and read_docs which perform different functions.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies use when validation errors are present with page content, but lacks explicit when-to-use or when-not-to-use guidance compared to sibling tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

edit_pageC

Proposes changes to the current Evidence markdown page.

Validates the proposed content for common Evidence syntax issues and returns the content with any warnings detected.

Returns: Dictionary with 'success', 'description', 'content', and 'warnings' list

ParametersJSON Schema
NameRequiredDescriptionDefault
editYes
descriptionYes

TDQS

C2.4/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations are absent, so the description must carry the full burden of behavioral disclosure. It mentions validation and warnings but does not clarify whether changes are persisted, if permissions are needed, or if the tool is a dry-run. The phrase 'Proposes changes' is ambiguous and the return dictionary's 'success' field implies a potential side effect, but no details are given.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is three sentences, relatively concise, and starts with the core action. However, the second sentence mixes validation and return details, and the third sentence lists return fields, which could be shortened. It is adequate but not optimally structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema, no annotations, and 0% schema coverage, the description is insufficient. It does not explain how the page to edit is identified (likely from context but not stated), what the edit should look like (markdown?), or what errors may occur. The return dictionary is mentioned but its fields are not described in context. Significant gaps remain.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, yet the description adds no explanation for the two parameters ('edit', 'description'). It only mentions a 'description' field in the return value, which could confuse with the input parameter. The description fails to clarify the format or purpose of the parameters beyond their names.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states it proposes changes to an Evidence markdown page and validates them, but it is ambiguous whether the changes are actually applied or if this is a dry-run. The verb 'proposes' suggests a suggestion, but the return of content implies modification. Purpose is vague and does not clearly distinguish from a simple validation tool.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus its siblings (debug_code, get_metadata, read_docs). There is no mention of prerequisites, context, or alternatives. The agent receives no help deciding whether to invoke this tool.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_metadataA

Returns database schema from Evidence's DuckDB connection.

Returns a JSON object with tables and their columns, including data types. Use this to understand what data is available for queries.

Returns: Dictionary with 'tables' array, each containing 'name' and 'columns'

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description carries full burden. Clearly describes return format (JSON with tables and columns). Does not explicitly state non-destructive nature, but read-only schema retrieval is implied. Lacks mention of side effects, but they are unlikely.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences, each purposeful. Front-loaded with main purpose, then return format, then usage guidance. No fluff.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with no parameters, no output schema, no annotations, description fully explains what the tool does and returns, with usage context. Complete for its complexity.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Zero parameters, so baseline is 4. Description adds meaning beyond empty schema by explaining output structure and use case.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states it returns database schema from Evidence's DuckDB connection, listing tables and columns. Verb 'returns' with specific resource 'database schema', distinct from sibling tools like debug_code or read_docs.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly says 'Use this to understand what data is available for queries.' Provides a clear use case but no when-not or alternatives, though context with siblings makes it clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

read_docsB

Retrieves Evidence documentation using hierarchical lookup.

Categories:

  • charts: LineChart, BarChart, AreaChart, Heatmap, SankeyDiagram, etc.

  • data: Value, BigValue, DataTable, Delta

  • inputs: Dropdown, Slider, DateInput, ButtonGroup, etc.

  • ui: Grid, Tabs, Modal, Alert, Accordion, etc.

  • maps: USMap, AreaMap, PointMap, BubbleMap, BaseMap

  • custom: CustomComponent, ComponentQueries

  • core-concepts: queries, syntax, loops, formatting, filters, etc.

  • data-sources: postgres, mysql, snowflake, bigquery, duckdb, etc.

  • deployment: vercel, netlify, cloudflare-pages, etc.

  • guides: best-practices, troubleshooting, chart-cheat-sheet

  • reference: cli, markdown, layouts

  • plugins: source-plugins, component-plugins

  • getting-started: install-evidence, build-your-first-app

Returns: Dictionary with 'title', 'content', and 'related_docs' for further exploration

ParametersJSON Schema
NameRequiredDescriptionDefault
doc_typeYes
componentNo

TDQS

B3.3/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, and the description does not disclose behavioral traits such as read-only nature, rate limits, or authentication needs. It only states what is returned, lacking full transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is moderately concise but includes a lengthy list of categories that could be summarized. It is structured with a clear purpose statement and a list, but the list is verbose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description covers the return format and doc_type options well but lacks details on the 'component' parameter. Given no output schema and no annotations, it is adequate but not fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description partially compensates by listing categories for the 'doc_type' parameter with examples. However, the 'component' parameter is not described at all, leaving its semantics ambiguous.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it retrieves Evidence documentation via hierarchical lookup. It lists categories and subcategories, and specifies the return structure with 'title', 'content', and 'related_docs'. The purpose is specific and distinct from siblings like debug_code or edit_page.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for looking up documentation but does not explicitly say when to use this tool vs alternatives or provide usage exclusions. Siblings are sufficiently different, so guidance is minimal but adequate.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 4 tool updatesv0.1.0
    • First observeddebug_code
    • First observededit_page
    • First observedget_metadata
    • First observedread_docs

TDQS

B3.2/5.0

Scored across 4 tools

Disambiguation4/5

Tools are mostly distinct: debug_code analyzes errors, edit_page modifies content, get_metadata queries schema, read_docs fetches documentation. Minor overlap between debug_code and edit_page as both involve page content, but their purposes are clear.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern in lowercase with underscores: debug_code, edit_page, get_metadata, read_docs. No deviation.

Tool Count5/5

Four tools is well-scoped for an Evidence MCP server, covering core needs like debugging, editing, schema discovery, and documentation. Not too few or too many.

Completeness2/5

Significant gaps: missing tools for creating, listing, or deleting pages, and no tool to run queries or fetch actual data from the database. The surface covers only partial workflows, likely causing agent failures in common tasks.

Maintenance

ActivityInactive
ResponsivenessNo issues

Related MCP Connectors

Related MCP Servers