Skip to main content
Glama
LeelaissakAttota

toolbridge-mcp-server

ToolBridge MCP Server

Model Context Protocol (MCP) Server for ToolBridge โ€” bridging tools and AI agents through a standardized protocol.

Python 3.10+ License: MIT MCP Compatible

Overview

ToolBridge MCP Server implements the Model Context Protocol (MCP) to expose tools, resources, and prompts to AI agents in a standardized way. It acts as a bridge between AI agents and external tools, APIs, databases, and services.

Features

  • ๐Ÿ”Œ MCP 1.0+ Compatible โ€” Full implementation of the Model Context Protocol

  • ๐Ÿ”ง Tool Registration โ€” Decorator-based tool registration with schema validation

  • ๐Ÿ“ฆ Resource Management โ€” Expose files, databases, and APIs as MCP resources

  • ๐Ÿ’ฌ Prompt Templates โ€” Reusable prompt templates for common workflows

  • ๐Ÿ” Authentication & Authorization โ€” Built-in auth with API keys, OAuth, and JWT

  • ๐Ÿ“Š Observability โ€” Structured logging, metrics, and tracing

  • ๐Ÿณ Docker Ready โ€” Production-ready containerization

  • ๐Ÿงช Well Tested โ€” Comprehensive test suite with pytest

Quick Start

Prerequisites

  • Python 3.10+

  • pip / uv / poetry

Installation

# Clone the repository
git clone https://github.com/toolbridge/mcp-server.git
cd mcp-server

# Install dependencies
pip install -e ".[dev]"

# Or with uv (recommended)
uv pip install -e ".[dev]"

Configuration

Copy the example environment file and configure:

cp .env.example .env
# Edit .env with your settings

Running the Server

# Development mode with auto-reload
python -m mcp_server

# Or using the CLI
mcp-server run --reload

# Production mode
mcp-server run --host 0.0.0.0 --port 8000

Using with MCP Clients

{
  "mcpServers": {
    "toolbridge": {
      "command": "python",
      "args": ["-m", "mcp_server"],
      "env": {
        "MCP_SERVER_HOST": "localhost",
        "MCP_SERVER_PORT": "8000"
      }
    }
  }
}

Project Structure

toolbridge-mcp-server/
โ”œโ”€โ”€ mcp_server/           # Main MCP server package
โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ”œโ”€โ”€ server.py         # Core MCP server implementation
โ”‚   โ”œโ”€โ”€ tools/            # Built-in tools
โ”‚   โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ”‚   โ”œโ”€โ”€ filesystem.py
โ”‚   โ”‚   โ”œโ”€โ”€ web_search.py
โ”‚   โ”‚   โ”œโ”€โ”€ code_execution.py
โ”‚   โ”‚   โ””โ”€โ”€ api_client.py
โ”‚   โ”œโ”€โ”€ resources/        # Resource providers
โ”‚   โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ”‚   โ”œโ”€โ”€ filesystem.py
โ”‚   โ”‚   โ””โ”€โ”€ database.py
โ”‚   โ”œโ”€โ”€ prompts/          # Prompt templates
โ”‚   โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ”‚   โ””โ”€โ”€ templates.py
โ”‚   โ”œโ”€โ”€ auth/             # Authentication
โ”‚   โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ”‚   โ”œโ”€โ”€ api_key.py
โ”‚   โ”‚   โ””โ”€โ”€ jwt.py
โ”‚   โ”œโ”€โ”€ config.py         # Configuration management
โ”‚   โ”œโ”€โ”€ logging.py        # Structured logging
โ”‚   โ””โ”€โ”€ middleware/       # MCP middleware
โ”‚       โ”œโ”€โ”€ __init__.py
โ”‚       โ”œโ”€โ”€ auth.py
โ”‚       โ””โ”€โ”€ logging.py
โ”œโ”€โ”€ agent/                # Agent integration layer
โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ”œโ”€โ”€ base.py
โ”‚   โ”œโ”€โ”€ orchestrator.py
โ”‚   โ””โ”€โ”€ tools.py
โ”œโ”€โ”€ tests/                # Test suite
โ”‚   โ”œโ”€โ”€ unit/
โ”‚   โ”œโ”€โ”€ integration/
โ”‚   โ”œโ”€โ”€ fixtures/
โ”‚   โ””โ”€โ”€ conftest.py
โ”œโ”€โ”€ docs/                 # Documentation
โ”‚   โ”œโ”€โ”€ index.md
โ”‚   โ”œโ”€โ”€ getting-started.md
โ”‚   โ”œโ”€โ”€ tools.md
โ”‚   โ”œโ”€โ”€ resources.md
โ”‚   โ””โ”€โ”€ deployment.md
โ”œโ”€โ”€ docker/               # Docker configuration
โ”‚   โ”œโ”€โ”€ Dockerfile
โ”‚   โ”œโ”€โ”€ docker-compose.yml
โ”‚   โ””โ”€โ”€ docker-compose.dev.yml
โ”œโ”€โ”€ sample_data/          # Sample data for testing
โ”œโ”€โ”€ scripts/              # Utility scripts
โ”œโ”€โ”€ .env.example          # Environment template
โ”œโ”€โ”€ requirements.txt      # Production dependencies
โ”œโ”€โ”€ pyproject.toml        # Build configuration
โ”œโ”€โ”€ LICENSE               # MIT License
โ””โ”€โ”€ README.md             # This file

Development

Running Tests

# Run all tests
pytest

# Run with coverage
pytest --cov=mcp_server --cov-report=html

# Run specific test file
pytest tests/unit/test_tools.py -v

Code Quality

# Format code
ruff format .

# Lint
ruff check .

# Type check
mypy mcp_server

# Pre-commit hooks
pre-commit install
pre-commit run --all-files

Adding Tools

# mcp_server/tools/my_tool.py
from mcp_server.tools import tool
from pydantic import BaseModel

class MyToolInput(BaseModel):
    query: str
    limit: int = 10

@tool(
    name="my_tool",
    description="Description of what this tool does",
)
async def my_tool(input: MyToolInput) -> str:
    # Implementation here
    return f"Result for: {input.query}"

Configuration

Environment variables (see .env.example):

Variable

Description

Default

MCP_SERVER_HOST

Server host

localhost

MCP_SERVER_PORT

Server port

8000

MCP_SERVER_LOG_LEVEL

Log level

INFO

MCP_API_KEY

API key for auth

-

MCP_JWT_SECRET

JWT secret

-

Deployment

Docker

# Build
docker build -t toolbridge/mcp-server .

# Run
docker run -p 8000:8000 --env-file .env toolbridge/mcp-server

# Docker Compose
docker-compose up -d

Kubernetes

kubectl apply -f k8s/

Contributing

  1. Fork the repository

  2. Create a feature branch

  3. Make your changes

  4. Run tests and linting

  5. Submit a PR

License

MIT License โ€” see LICENSE for details.

-
license - not tested
-
quality - not tested
C
maintenance

Maintenance

โ€“Maintainers
โ€“Response time
โ€“Release cycle
โ€“Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/LeelaissakAttota/toolbridge-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server