← All tool references

Health · execute

BMI Calculator

Calculate adult BMI, CDC screening category, and the healthy-weight range for your height in metric or US units.

Open public tool

Overview

Category
Health
API mode
execute
Processing
client-side
Privacy
no-data-stored

Public descriptor

The descriptor is available without an API key and supplies this tool’s metadata, schemas, modes, and examples.

GET /api/v1/tools/bmi-calculator

View this descriptor as JSON

Execute availability

This tool has an execute route defined by its descriptor. Server-side execution is currently unavailable, so requests return api_not_launched.

POST /api/v1/tools/bmi-calculator/execute

Authentication is not issued during the preview. A bearer API key is planned for execution after launch.

Input schema

object object; additional properties are not accepted.

unit_system · string · required
Choose metric when entering kilograms and centimeters, or imperial when entering pounds and inches. Accepted values: metric, imperial.
weight · number · required
Enter body weight in kilograms for metric mode or pounds for imperial mode.
height · number · required
Enter height in centimeters for metric mode or inches for imperial mode.
{
    "type": "object",
    "properties": {
        "unit_system": {
            "type": "string",
            "enum": [
                "metric",
                "imperial"
            ],
            "description": "Choose metric when entering kilograms and centimeters, or imperial when entering pounds and inches."
        },
        "weight": {
            "type": "number",
            "description": "Enter body weight in kilograms for metric mode or pounds for imperial mode."
        },
        "height": {
            "type": "number",
            "description": "Enter height in centimeters for metric mode or inches for imperial mode."
        }
    },
    "required": [
        "unit_system",
        "weight",
        "height"
    ],
    "additionalProperties": false
}

Output schema

On a successful execution, schema values appear in data.result.values.

bmi · number
Body mass index.
category · string
CDC adult BMI screening category.
healthy_weight_min · number
Weight corresponding to BMI 18.5 at the entered height.
healthy_weight_max · number
Weight corresponding to BMI 24.9 at the entered height.
weight_unit · string
Kilograms or pounds, matching the selected unit system.
{
    "type": "object",
    "properties": {
        "bmi": {
            "type": "number",
            "description": "Body mass index."
        },
        "category": {
            "type": "string",
            "description": "CDC adult BMI screening category."
        },
        "healthy_weight_min": {
            "type": "number",
            "description": "Weight corresponding to BMI 18.5 at the entered height."
        },
        "healthy_weight_max": {
            "type": "number",
            "description": "Weight corresponding to BMI 24.9 at the entered height."
        },
        "weight_unit": {
            "type": "string",
            "description": "Kilograms or pounds, matching the selected unit system."
        }
    },
    "additionalProperties": false
}

BMI Calculator: Metric BMI

The request body follows the published input schema. The response below shows the success-envelope shape returned after execution is available.

curl -X POST "https://utilitypages.org/api/v1/tools/bmi-calculator/execute" \
  -H "Content-Type: application/json" \
  -d '{
    "unit_system": "metric",
    "weight": 70,
    "height": 175
}'
{
    "ok": true,
    "data": {
        "slug": "bmi-calculator",
        "result": {
            "values": {
                "bmi": 22.8599999999999994315658113919198513031005859375,
                "category": "Healthy weight",
                "healthy_weight_min": 56.7000000000000028421709430404007434844970703125,
                "healthy_weight_max": 76.2999999999999971578290569595992565155029296875,
                "weight_unit": "kg"
            },
            "display": {
                "display": "22.86"
            },
            "warnings": [],
            "assumptions": [],
            "steps": []
        }
    },
    "meta": [],
    "request_id": "req_example_123"
}

Errors

api_not_launched · 503
Returned by the current launch gate for every execute request.
invalid_json · 400
Returned when an enabled execute request does not contain valid JSON.
validation_failed · 422
Returned when a request does not satisfy the input schema.
browser_interaction_required · 422
Returned for browser capability tools instead of inventing a server-side result.
tool_not_found · 404
Returned when a requested descriptor slug does not exist.
execution_failed · 503
Returned when an enabled server-side execution cannot complete.