Splitrail MCP Server Guide

VerifiedSafe

Guide for working with Splitrail's MCP server, adding tools and resources.

Sby Skills Guide Bot
DevelopmentIntermediate
8/13/2026
Claude CodeCursorCodex
#mcp#rust#server-extension#api-design#tooling

Recommended for

Automated summary

Guide for working on Splitrail's MCP server: adding tools, resources, and modifying the MCP interface in the Rust codebase.

Strengths

  • Points to the exact source files involved (src/mcp/server.rs, types.rs, mod.rs)
  • Documents the MCP tools and resources the project already exposes
  • Gives a step-by-step procedure for adding a new tool or resource

Limitations

  • Does not cover the underlying analytics queries, only the MCP wiring
  • Assumes familiarity with Rust and the #[tool] macro
  • Does not describe testing or input validation for tools
When to use it

Use when adding or changing a tool, resource, or the MCP interface of Splitrail's server.

When not to use it

Avoid it when implementing the statistics themselves or working on parts of the project unrelated to MCP.

Security analysis

Safe
Quality score78/100

The skill is documentation for a specific project's MCP server. It includes a 'cargo run -- mcp' command and file path references, but no destructive, exfiltrating, or obfuscated actions. The instructions are limited to adding tools/resources and understanding the codebase, presenting no meaningful execution risk.

No concerns found

How this analysis is made

Examples

Add a new MCP tool
Add a new MCP tool to Splitrail called get_weekly_trends that returns usage aggregated by week, following the existing tool pattern in src/mcp/server.rs.
Expose a new resource
Add an MCP resource at splitrail://projects that lists per-project cost breakdown, updating resource_uris, list_resources() and read_resource().
Inspect existing tools
Show me how the compare_tools MCP tool is implemented in src/mcp/server.rs and what request/response types it uses.

name: mcp description: Guide for working with Splitrail's MCP server. Use when adding tools, resources, or modifying the MCP interface.

MCP Server

Splitrail can run as an MCP server, allowing AI assistants to query usage statistics programmatically.

cargo run -- mcp

Source Files

  • src/mcp/mod.rs - Module exports
  • src/mcp/server.rs - Server implementation and tool handlers
  • src/mcp/types.rs - Request/response types

Available Tools

  • get_daily_stats - Query usage statistics with date filtering
  • get_model_usage - Analyze model usage distribution
  • get_cost_breakdown - Get cost breakdown over a date range
  • get_file_operations - Get file operation statistics
  • compare_tools - Compare usage across different AI coding tools
  • list_analyzers - List available analyzers

Resources

  • splitrail://summary - Daily summaries across all dates
  • splitrail://models - Model usage breakdown

Adding a New Tool

  1. Define the tool handler in src/mcp/server.rs using the #[tool] macro
  2. Add request/response types to src/mcp/types.rs if needed

See existing tools in src/mcp/server.rs for the pattern.

Adding a New Resource

  1. Add URI constant to resource_uris module in src/mcp/server.rs
  2. Add to list_resources() method
  3. Handle in read_resource() method

From the file to a first result

The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.

View the source and supporting files

This download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.

1. Download the file

Download SKILL.md

From the root of a test project, save the file as .skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.

Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.

mkdir -p '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/splitrail-mcp-server-guide-msr1u7f1/download' --output '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md.part' && mv '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md.part' '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md'

2. Check prerequisites

Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.

No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.

The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.

3. Load the skill

After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.

Claude Code
test -f '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md' && test -s '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/mcp' && cp -R '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1' '.claude/skills/mcp'

Cursor
test -f '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md' && test -s '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md' && mkdir -p '.cursor/skills' && test ! -e '.cursor/skills/mcp' && cp -R '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1' '.cursor/skills/mcp'

Codex
test -f '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md' && test -s '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md' && mkdir -p '.agents/skills' && test ! -e '.agents/skills/mcp' && cp -R '.skill-downloads/splitrail-mcp-server-guide-msr1u7f1' '.agents/skills/mcp'

OpenSkills

OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.

Official OpenSkills installation
openskills install './.skill-downloads/splitrail-mcp-server-guide-msr1u7f1'

openskills read 'splitrail-mcp-server-guide-msr1u7f1'

Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.

For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.

openskills sync

Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.

4. Try a first task

Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:

Read .skill-downloads/splitrail-mcp-server-guide-msr1u7f1/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.

Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.

Related skills