hepdata-mcp
OfficialClick on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@hepdata-mcp search for records containing 'top quark cross-section'"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
HEPData MCP
This is an MCP server for discovering HEPData records, listing tables, fetching table data, and exposing HEPData export links. This is an early MVP implementation, focused on read-only access to public HEPData content.
Local stdio is the default and recommended mode. HTTP support exists for local testing and hardened central deployments, but remote HTTP is also supported for multiple clients support.
Run From PyPI
HEPData MCP is published on PyPI as hepdata-mcp.
The easiest way to run it is with uvx:
uvx hepdata-mcpIf you want to avoid package resolution during MCP client startup, install the tool once:
uv tool install hepdata-mcp
hepdata-mcpUpgrade that installed tool with uv tool upgrade hepdata-mcp.
For MCP client configs in this mode, use hepdata-mcp as the command with no arguments.
Related MCP server: mcp-inspire-hep
Install From Source
For development, install this checkout in editable mode:
git clone https://github.com/HEPData/hepdata-mcp ~/.local/uv/hepdata-mcp-src
cd ~/.local/uv/hepdata-mcp-src
uv sync --all-groupsFor development checks:
uv run pytest
uv run ruff check .
uv run ruff format --check .
uv run mypyDocker
The Docker image is published on Docker Hub as hepdata/hepdata-mcp.
Pull the latest release:
docker pull hepdata/hepdata-mcp:latestFor reproducible deployments, pin a release tag such as hepdata/hepdata-mcp:0.1.0.
Run over stdio for clients that can launch Docker commands:
docker run --rm -i hepdata/hepdata-mcp:latestExample stdio client command:
{
"mcpServers": {
"hepdata": {
"command": "docker",
"args": ["run", "--rm", "-i", "hepdata/hepdata-mcp:latest"]
}
}
}Run local streamable HTTP:
docker run --rm \
-p 127.0.0.1:8000:8000 \
-e HEPDATA_MCP_ALLOW_REMOTE_HTTP=1 \
-e HEPDATA_MCP_TRUST_PROXY_AUTH=1 \
hepdata/hepdata-mcp:latest \
--transport streamable-http --host 0.0.0.0 --port 8000The container runs as a non-root user. For remote HTTP deployment, keep the same reverse-proxy, TLS, authentication, and rate-limit requirements described below.
Build the image from this checkout for local development:
docker build -t hepdata-mcp:local .Tools
search_recordsget_recordlist_tablesdescribe_tableget_tableget_record_exportsget_record_versionsget_jsonldserver_info
Resources:
hepdata://record/{identifier}hepdata://record/{identifier}/tables
Local MCP Client Setup
Most MCP clients launch commands directly, without a shell. Use uvx as the command and pass the package name as an argument.
Warm the uvx cache once before configuring a client, especially on machines with slow or restricted network access:
uvx hepdata-mcp --helpUseful variants:
uvx hepdata-mcp==0.1.0
uvx --refresh hepdata-mcpIf a GUI-launched client cannot find uvx, check where uvx is installed with command -v uvx and use that path as the command.
On macOS this is commonly needed for clients such as Claude Code; Homebrew installs often use /opt/homebrew/bin/uvx, while standalone uv installs may use /Users/<you>/.local/bin/uvx.
Use the expanded absolute path because MCP clients usually do not expand ~ or $HOME.
GitHub Copilot In VS Code
Create or edit .vscode/mcp.json:
{
"servers": {
"hepdata": {
"command": "uvx",
"args": ["hepdata-mcp"]
}
}
}Then run MCP: List Servers from the VS Code command palette and start hepdata.
For GitHub Copilot CLI:
copilot mcp add hepdata --type stdio -- uvx hepdata-mcpCodex
Add to ~/.codex/config.toml:
[mcp_servers.hepdata]
command = "uvx"
args = ["hepdata-mcp"]
supports_parallel_tool_calls = trueOr, if using a local HTTP server:
codex mcp add hepdata --url http://127.0.0.1:8000/mcpClaude Code
Project .mcp.json example:
{
"mcpServers": {
"hepdata": {
"type": "stdio",
"command": "uvx",
"args": ["hepdata-mcp"]
}
}
}On macOS, if Claude Code cannot find uvx, expand the command:
{
"mcpServers": {
"hepdata": {
"type": "stdio",
"command": "/opt/homebrew/bin/uvx",
"args": ["hepdata-mcp"]
}
}
}CLI alternative:
claude mcp add-json hepdata '{"type":"stdio","command":"uvx","args":["hepdata-mcp"]}'Qwen Code
Add to ~/.qwen/settings.json or .qwen/settings.json:
{
"mcpServers": {
"hepdata": {
"command": "uvx",
"args": ["hepdata-mcp"],
"timeout": 30000,
"trust": false
}
}
}Other MCP Clients
Most stdio MCP clients support a similar shape:
{
"mcpServers": {
"hepdata": {
"command": "uvx",
"args": ["hepdata-mcp"]
}
}
}HTTP Mode
Start local streamable HTTP:
uvx hepdata-mcp --transport streamable-http --host 127.0.0.1 --port 8000Local URL:
http://127.0.0.1:8000/mcpExample VS Code / GitHub Copilot HTTP config:
{
"servers": {
"hepdata": {
"type": "http",
"url": "http://127.0.0.1:8000/mcp"
}
}
}Example Qwen Code HTTP config:
{
"mcpServers": {
"hepdata": {
"httpUrl": "http://127.0.0.1:8000/mcp",
"timeout": 30000
}
}
}Central Deployment
Remote HTTP binds are intentionally blocked unless both deployment opt-ins are set:
HEPDATA_MCP_ALLOW_REMOTE_HTTP=1 \
HEPDATA_MCP_TRUST_PROXY_AUTH=1 \
uvx hepdata-mcp --transport streamable-http --host 0.0.0.0 --port 8000Only use this behind hardened ingress:
TLS at the edge.
Authentication and authorization before requests reach this process.
Per-user or per-token rate limits.
No request-body or table-payload logging.
Notes
HEPData upstream access is public and read-only.
Large tool payloads are truncated before being returned to agents.
Whole-record download exports are returned as HEPData URLs, not downloaded by default.
Live integration tests are opt-in:
HEPDATA_MCP_LIVE_TESTS=1 uv run pytest tests/test_live_client.pyLicense
This project follows the main HEPData project license: GNU General Public License version 2 or later (GPL-2.0-or-later). See LICENSE.
Available Tools
9 toolsdescribe_tableDescribe TableCRead-onlyIdempotent
Describe one HEPData table's metadata, variables, qualifiers, and size.
Inputs: table (required), identifier (required), version. Returns: object
get_jsonldGet JSON-LDBRead-onlyIdempotent
Fetch JSON-LD metadata for a HEPData record.
Inputs: identifier (required). Returns: object
get_recordGet RecordBRead-onlyIdempotent
Fetch HEPData record metadata or full record JSON.
Inputs: identifier (required), light, version. Returns: object
get_record_exportsGet Record ExportsBRead-onlyIdempotent
Return supported HEPData export URLs without downloading files.
Inputs: identifier (required), version. Returns: object
get_record_versionsGet Record VersionsBRead-onlyIdempotent
Return available HEPData record versions and version-specific record URLs.
Inputs: identifier (required). Returns: object
get_tableGet TableCRead-onlyIdempotent
Fetch one HEPData table in JSON, YAML, or CSV format.
Inputs: table (required), identifier (required), format, version. Returns: object
list_tablesList TablesBRead-onlyIdempotent
List tables advertised by a HEPData record.
Inputs: identifier (required), version. Returns: object
search_recordsSearch RecordsBRead-onlyIdempotent
Search HEPData records using HEPData's native search syntax.
Inputs: query (required), page, size. Returns: object
server_infoServer InfoARead-onlyIdempotent
Return server health, version, and capability metadata.
Inputs: no named parameters. Returns: Structured health and capability metadata for the MCP server.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 9 tools
Each tool targets a distinct resource and action: searching records, fetching metadata, listing tables, describing a table, fetching table data, getting exports, versions, JSON-LD, and server info. There is no ambiguity between them.
All tools follow a consistent verb_noun pattern (e.g., search_records, get_record, list_tables, describe_table, get_table). Even server_info follows this structure, and there is no mixing of conventions.
With 9 tools, the set is well-scoped for a HEPData MCP server. Each tool serves a clear purpose in navigating and retrieving data, and none feel redundant or missing.
The tool surface covers the core workflows of searching, retrieving, and exploring HEPData records and tables, including versions, exports, and metadata formats. Minor gaps exist, such as no tool for uploading or modifying data, but these are out of scope for a typical read-only data access server.
Maintenance
Related MCP Connectors
Search CERN Open Data, fetch records, files, analysis environments, CMS good-run lists, HLT paths.
Search INSPIRE-HEP papers, authors, experiments, HEPData records; get citation metrics and BibTeX.
Read-only search and retrieval of published books, articles and authors, with public catalog links.
Read-only U.S. healthcare dataset metadata, schemas, immutable downloads, and checksums.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceProvides access to DataCite DOIs for research datasets, enabling searching and retrieval of dataset metadata.99 npmMIT
- AlicenseNot gradedqualityCmaintenanceEnables searching and retrieving high-energy physics literature, authors, institutions, and conferences from INSPIRE-HEP.150 npmMIT
- FlicenseNot gradedqualityCmaintenanceEnables discovery and querying of public OpenBind structure-affinity datasets, experimental binding events, benchmark results, and live Fragalysis targets and observations through read-only REST endpoints without requiring an API key.-
- AlicenseNot gradedqualityBmaintenanceEnables researchers to query DigitalBrain data catalogs, brain region profiles, gene expression summaries, and paper evidence, and download approved results through MCP-compatible clients.MIT