cucinellclark/bvbrc-mcp-server
If you are the rightful owner of bvbrc-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
The BV-BRC MCP Server is a minimal Model Context Protocol server designed for bioinformatics applications, providing tools for sequence analysis.
BV-BRC MCP Server
A Model Context Protocol (MCP) server for the Bacterial-Viral Bioinformatics resource Center:
- Data Tools: Query BV-BRC Solr collections for genome, feature, and other biological data
- Service Tools: Submit and manage BV-BRC analysis jobs (assembly, annotation, BLAST, etc.)
- Workspace Tools: Manage BV-BRC workspace files, folders, and groups
Features
Data Tools
query_collection: Query any BV-BRC Solr collection with flexible filteringsolr_collection_parameters: Get schema information for collectionssolr_query_instructions: Get help on query syntaxsolr_collections: List all available collections
Service Tools
list_service_apps: List all available BV-BRC analysis servicesget_job_details: Query the status of submitted jobs- Submit jobs for various analyses:
- Genome Assembly
- Genome Annotation
- Comprehensive Genome Analysis
- BLAST
- Primer Design
- Variation Analysis
- TnSeq
- Phylogenetic Trees (Bacterial Genome Tree, Gene Tree)
- SNP Analysis (Whole Genome, MSA)
- Metagenomics (Taxonomic Classification, Binning, Read Mapping)
- RNA-Seq
- Viral Services (SARS-CoV-2 Analysis, Sequence Submission)
- And many more...
Workspace Tools
workspace_ls_tool: List workspace contentsworkspace_search_tool: Search workspace for filesworkspace_get_file_metadata_tool: Get file metadataworkspace_download_file_tool: Download workspace filesworkspace_upload: Upload files to workspacecreate_genome_group: Create genome groupscreate_feature_group: Create feature groupsget_genome_group_ids: Get genome IDs from a groupget_feature_group_ids: Get feature IDs from a group
Connecting the Remote BV-BRC MCP Server to ChatGPT
Step 1: Enable Developer Mode
- Click the plus next to "Ask me anything"
- Click "Add sources"
- You should now see "Sources" and "Add" below your chat box
- Click the down arrow next to "Add"
- Click "Connect more"
- Scroll down to Advanced Settings
- Click the toggle next to Developer Mode (must be "on")
- Click Back
Step 2: Create MCP Server Connection
- In the upper right-hand corner, click "Create"
- Fill in the following:
- Icon: Optional
- Name: BV-BRC MCP
- Description: ''
- MCP Server URL: https://dev-7.bv-brc.org/mcp
- Authentication:
- Leave authentication on OAuth
- Check the box if you Trust this application
- Click "Create"
Step 3: Connect to Your Server
- You should now see 'BV-BRC MCP' under "Enabled apps & connectors"
- Click the 'X' in the top left to go back to the chat screen
- In a New Chat, click the '+' button and hover over More
- You should see BV-BRC MCP as an option under Canvas
- Select BV-BRC MCP
Connecting the Remote BV-BRC MCP Server to Claude
-
Click account in bottom left and go to settings
-
Click 'Connectors'
-
Click 'Add custom connector'
-
Fill in the following:
- Name: BV-BRC MCP
- Remote MCP server URL: https://dev-7.bv-brc.org/mcp
-
Click 'Add'
-
Then click 'Connect'
-
Log into BV-BRC
-
It's now available to use in a new chat
Installing as a Claude Extension
Open your terminal
-
Clone Github Repository
git clone https://github.com/cucinellclark/bvbrc-mcp-server cd bvbrc-mcp-server -
Install the requirements:
./install.sh -
Activate the environment:
source mcp_env/bin/activate -
Install the MCP Builder CLI:
npm install -g @anthropic-ai/mcpb -
Generate the MCP configuration file (if you haven't already):
python3 bvbrc_login_and_setup.py -
Pack the extension:
mcpb pack -
In Claude, Go to Settings, then Extensions
-
Click Advanced settings, then Install Extension
-
Select the file 'bvbrc-mcp-server.mcpb' then click Preview
-
It should pull up a preview page, then click Install
MCP Development
Note
Local server development is recommended for working on MCP tools
Installation
Run the installation script, which will create the virtual python environment and install a data api and remaining requirements
# clone the repository and enter it
./install.sh
Local server development
Generate mcp config file:
python3 bvbrc_login_and_setup.py
Creates mcp_config.json
Paste its contents into your chatbots mcp config file
Remote server development
Configure the server (for remote servers):
Edit config.json to set:
- API URLs (workspace, service, data)
- Server host and port
- Authentication URL
Configuration
The config.json file contains:
{
"base_url": "https://www.bv-brc.org/api-bulk",
"workspace_url": "https://p3.theseed.org/services/Workspace",
"service_api_url": "https://p3.theseed.org/services/app_service",
"similar_genome_finder_api_url": "https://p3.theseed.org/services/minhash_service",
"authentication_url": "https://user.patricbrc.org/authenticate",
"mcp_url": "127.0.0.1",
"port": 12010
}
Running the Server
HTTP Mode (for web clients, ChatGPT, etc.)
Start the HTTP server:
./start_http_server.sh
The server will start on the configured host and port (default: 127.0.0.1:12010).
STDIO Mode (for Claude Desktop, etc.)
Start the STDIO server: Set it up in your MCP client configuration (e.g., Claude Desktop): See installation section
{
"mcpServers": {
"bvbrc": {
"command": "python",
"args": ["/path/to/bvbrc-mcp/stdio_server.py"],
"env": {
"KB_AUTH_TOKEN": "your_token_here"
}
}
}
}
Instructions for MCP configuration Setup
Architecture
Directory Structure
bvbrc-mcp-server/
├── __init__.py # Package initialization
├── __main__.py # Entry point for module execution
├── http_server.py # HTTP server (for web clients, ChatGPT)
├── install.sh # Installation script
├── mcp_config.json # Generated MCP configuration
├── mcp_example.json # Example MCP configuration
├── mcp.pm2.config.js # PM2 process manager configuration
├── README.md # This file
├── requirements.txt # Python dependencies
├── start_server.sh # Server startup script
├── stdio_server.py # STDIO server (for Claude Desktop, etc.)
├── bvbrc_login_and_setup.py # Script to login and generate MCP config file
├── common/ # Common utility modules
│ ├── __init__.py
│ ├── auth.py # OAuth2 authentication endpoints (HTTP only)
│ ├── json_rpc.py # JSON-RPC client for API calls
│ └── token_provider.py # Unified authentication token handling
├── config/ # Configuration files
│ ├── config.json # Main configuration file
│ └── ...
├── bvbrc-python-api/ # BV-BRC Python API dependency
│ ├── bvbrc_solr_api/ # Solr API implementation
│ ├── pyproject.toml
│ └── README.md
├── functions/ # Function implementation modules
│ ├── __init__.py
│ ├── data_functions.py # Data query implementations
│ ├── service_functions.py # Service job implementations
│ └── workspace_functions.py # Workspace implementations
├── images/ # Image assets
│ └── bvbrc_logo_base64.txt
├── prompts/ # Collection schema documentation
│ ├── antibiotics.txt
│ ├── bacterial_genome_tree.txt
│ ├── bioset.txt
│ ├── bioset_result.txt
│ ├── blast.txt
│ ...
└── tools/ # Tool registration modules
├── __init__.py
├── data_tools.py # Data query tools registration
├── service_tools.py # Service job tools registration
└── workspace_tools.py # Workspace management tools registration
Possible Future Endeavours/Features
NCBI MCP Server Integration (SRA DB Search)
Integrate this into the current BV-BRC MCP Server so we do not need to re-invent the wheel for SRA searching. Requires NCBI account with API key. Follow instructions on GitHub repo to install and run locally. Tested on Cursor and working.