Get the FREE Ultimate OpenClaw Setup Guide →

uniprot

MCP server for UniProt protein data access

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio takumiy235-uniprot-mcp-server uv --directory path/to/uniprot-mcp-server run uniprot-mcp-server

How to use

This MCP server provides programmatic access to UniProt protein information via the MCP interface. It exposes two tools: get_protein_info for retrieving information about a single UniProt entry, and get_batch_protein_info for fetching details on multiple entries in one request. Each protein entry includes the protein name, a description of function, the full amino acid sequence, its length, and the organism of origin. The server is designed with a 24-hour TTL cache to improve performance and reduce repeated calls to the UniProt API, while also handling errors and retrying requests as needed. To use it, configure your MCP client (for example via Claude Desktop) to point to the server and call the tools with the appropriate parameters. Typical usage involves supplying an accession like P12345 to get_protein_info, or a list of accessions to get_batch_protein_info. The project is built with the MCP Python SDK and uses httpx for asynchronous HTTP requests, with caching and robust error handling to return structured results.

How to install

Prerequisites:

  • Python 3.10 or higher
  • Git
  • Internet access to install dependencies

Step-by-step:

  1. Clone the repository git clone https://github.com/TakumiY235/uniprot-mcp-server.git cd uniprot-mcp-server

  2. (Optional) Create and activate a Python virtual environment python -m venv .venv

    macOS/Linux

    source .venv/bin/activate

    Windows

    .venv\Scripts\activate

  3. Install dependencies (using uv recommended): uv pip install -r requirements.txt

    Or with plain pip:

    pip install -r requirements.txt

  4. Run the server with UV uv run uniprot-mcp-server

  5. Verify the server is running by issuing a test request to the MCP endpoint (as configured by your environment). You can also configure Claude Desktop or another MCP client to connect to this server using the provided mcp_config example.

Notes:

  • If you plan to run in a development environment, you can install with editable mode: pip install -e ".[dev]" (as described in the Development section of the README).
  • Ensure network access to UniProt services for initial data fetch and caching functionality.

Additional notes

Tips and considerations:

  • The server uses a 24-hour TTL cache to speed up responses and reduce load on the UniProt API. If you need fresh data, you can clear or bypass the cache via configuration or by restarting the server.
  • It includes error handling for common scenarios: invalid accession numbers, network/API issues, rate limiting (429), and malformed responses.
  • When integrating with Claude Desktop, the configuration example shows how to expose the uniprot MCP server so that Claude can send queries like get_protein_info for a single accession or get_batch_protein_info for multiple accessions.
  • If you customize the path to the repository or need to run multiple instances, adjust the --directory argument accordingly and ensure each instance uses a distinct run target.
  • The server is built with the MCP Python SDK and relies on httpx for asynchronous HTTP calls; ensure your environment allows outbound HTTP(S) requests.

Related MCP Servers

Sponsor this space

Reach thousands of developers