CEDAR

Provides access to CEDAR templates and instances via MCP, secured with API keys for CEDAR and BioPortal.
  • python

0

GitHub Stars

python

Language

4 months ago

First Indexed

3 weeks ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "bach-ai-tools-cedar-mcp": {
      "command": "uvx",
      "args": [
        "bach-cedar-mcp"
      ],
      "env": {
        "CEDAR_API_KEY": "YOUR_CEDAR_API_KEY",
        "BIOPORTAL_API_KEY": "YOUR_BIOPORTAL_API_KEY"
      }
    }
  }
}

The Cedar MCP Server lets you interact with the CEDAR metadata repository by exposing a Model Context Protocol (MCP) endpoint you can query from MCP clients. It supports quick setup with UVX, local development, and configuration in clients like Claude Code or Claude Desktop so you can fetch templates and template instances from CEDAR directly in your workflow.

How to use

You run the Cedar MCP Server locally or through a remote MCP endpoint and connect your MCP client to it. Start it with your API keys, then point your client (or Claude integration) to the provided command and environment variables. Use the server to fetch templates and the template instances you need from the CEDAR repository. When you configure your MCP client, specify the server details and pass your API keys so requests are authenticated.

Typical usage patterns include starting the MCP server with your CEDAR and BioPortal API keys, then configuring your MCP client to use the cedar_mcp server. You can also configure Claude Code or Claude Desktop to access the MCP server by supplying the same command and keys in their MCP sections.

How to install

Prerequisites you need before starting the Cedar MCP Server:

Choose one of the installation paths below and follow the steps for your setup.

Option A — Use UVX (recommended)

Run the MCP server directly with UVX and pass your API keys as arguments.

uvx bach-cedar-mcp \
  --cedar-api-key "your-cedar-key" \
  --bioportal-api-key "your-bioportal-key"

Option B — Install from PyPI

Install the MCP server from PyPI and then run it with your keys.

# Install from PyPI
pip install bach-cedar-mcp

# Run the server
bach-cedar-mcp \
  --cedar-api-key "your-cedar-key" \
  --bioportal-api-key "your-bioportal-key"

Option C — Use Environment Variables

Set your API keys as environment variables and start the server with the preferred runner.

# Set environment variables
export CEDAR_API_KEY="your-cedar-key"
export BIOPORTAL_API_KEY="your-bioportal-key"

# Run with UVX
uvx bach-cedar-mcp

# Or if installed with pip
bach-cedar-mcp

Option D — Local development

For local development, clone the project, install dependencies, and run the server directly from source.

# Clone the repository
git clone https://github.com/BACH-AI-Tools/cedar-mcp.git
cd cedar-mcp

# Install dependencies and run
uv run python -m cedar_mcp.server \
  --cedar-api-key "your-cedar-key" \
  --bioportal-api-key "your-bioportal-key"

Using with Claude Code

Add the Cedar MCP server to Claude Code so you can query CEDAR templates inside Claude projects.

# Add using UVX (from PyPI)
claude mcp add cedar-mcp --uvx bach-cedar-mcp \
  --cedar-api-key "your-cedar-key" \
  --bioportal-api-key "your-bioportal-key"

Using with Claude Desktop

Configure Claude Desktop to access the Cedar MCP Server by adding a new MCP server entry with the same command and keys.

{
  "mcpServers": {
    "cedar_mcp": {
      "command": "uvx",
      "args": ["bach-cedar-mcp"],
      "env": {
        "CEDAR_API_KEY": "your-cedar-key",
        "BIOPORTAL_API_KEY": "your-bioportal-key"
      }
    }
  }
}

Configurations and keys

The server requires your API keys to access CEDAR and BioPortal. Treat these keys as sensitive credentials. Pass them securely and avoid committing them to code repositories. You can provide keys via command-line arguments or environment variables as shown in the setup steps.

Available tools

The Cedar MCP Server provides focused capabilities to interact with the CEDAR metadata repository. The key tools are described here for quick reference.

Notes and security

Keep your API keys secure. Use environment variables or secret management to avoid exposing keys in command history or logs. When sharing configuration, replace keys with placeholders like YOUR_CEDAR_API_KEY and YOUR_BIOPORTAL_API_KEY.

Development and testing

Development dependencies and tests ensure the MCP server interacts correctly with CEDAR and BioPortal. Install development requirements, run tests, and follow integration guidelines to verify behavior against real APIs.

Available tools

get_template

Fetches a template from the CEDAR repository.

get_instances_based_on_template

Gets template instances that belong to a specific template with pagination support.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational