MCP BMI

by oscarrenalias

166 downloads
Not rated
GitHub

Description

# MCP BMI This is a simple MCP server that exposes a tool to calculate the BMI of a person given their weight and height. ## calculate_bmi Calculates the BMI based on weight and height. Input parameters: - weight - height Response: - bmi_index: a number representing the BMI…

About

# MCP BMI This is a simple MCP server that exposes a tool to calculate the BMI of a person given their weight and height. ## calculate_bmi Calculates the BMI based on weight and height. Input parameters: - weight - height Response: - bmi_index: a number representing the BMI index ## bmi_category Returns the category…

Details

Author
oscarrenalias
Downloads
166
Categories
Other

- calculate_bmi tool: returns a numeric BMI index from weight and height.
- bmi_category tool: returns a string category based on the BMI value.
- Built with Python and FastMCP for easy MCP integration.
- Packaged as a Docker image and available on the GitHub Container Registry.
- Ready‑to‑use DevContainer for development in VS Code.
- Includes a test script (test_bmi.py) that can be run with uv run test_bmi.py.

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name MCP BMI
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

The server can be used in two ways. In Visual Studio Code, add a Docker run command to your settings.json. Locally, run uv sync && uv run bmi_server.py or build and run the Docker image with docker build -t mcp-bmi . followed by docker run --rm -it mcp-bmi. The server provides two tools: calculate_bmi (requires weight and height as float inputs) and bmi_category (requires bmi as a float input).

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "mcp bmi": {
            "mcp-bmi": {
                "command": "docker",
                "args": [
                    "run",
                    "-i",
                    "--rm",
                    "ghcr.io/oscarrenalias/mcp-server-bmi:latest"
                ]
            }
        }
    }
}

McpServers

{
    "mcp-bmi": {
        "command": "docker",
        "args": [
            "run",
            "-i",
            "--rm",
            "ghcr.io/oscarrenalias/mcp-server-bmi:latest"
        ]
    }
}

MCP BMI

This is a simple MCP server that exposes a tool to calculate the BMI of a person given their weight and height.

calculate_bmi

Calculates the BMI based on weight and height.

Input parameters:
- weight
- height

Response:
- bmi_index: a number representing the BMI index

bmi_category

Returns the category that the BMI corresponds to:

Input parameters:
- bmi (float)

Response:
- bmi_category: a string representing the category, as per the established values:
- Underweight (Less than 18.5)
- Healthy Weight (18.5 to less than 25)
- Overweight (25 to less than 30)
- Obesity (30 or greater)
- Class 1 Obesity (30 to less than 35)
- Class 2 Obesity (35 to less than 40)
- Class 3 Severe obesity (40 or greater)

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.