Fiber Calculator API¶
Calculate recommended daily fiber target and fiber-per-kg context from user profile and activity level.
Endpoint¶
GET /api/v1/fiber-calculatorPOST /api/v1/fiber-calculator/post
Parameters¶
| Name | Type | Required | In | Description |
|---|---|---|---|---|
sex | string (male,female) | Yes | Query/Body | Biological sex. |
age | number | Yes | Query/Body | Age in years. |
height | number | Yes | Query/Body | Height (cm metric, in imperial). |
weight | number | Yes | Query/Body | Weight (kg metric, lb imperial). |
unit | string (metric,imperial) | No | Query/Body | Input mode. Default metric. |
activity_level | string | Yes | Query/Body | sedentary,lightly_active,moderately_active,very_active,extra_active. |
lang | string | No | Query | Response language (en,es,de,fr,pt,ja,hi,ar). |
Why Use This Endpoint¶
- Integrate practical fiber recommendations into meal planning.
- Detect under-target fiber profiles automatically.
- Improve gut-health and satiety guidance in coaching flows.
Request Example¶
curl -X GET "https://api.hefitapi.com/api/v1/fiber-calculator?sex=female&age=30&height=165&weight=66&unit=metric&activity_level=moderately_active&lang=en" \
-H "X-API-Key: YOUR_API_KEY"
curl -X POST "https://api.hefitapi.com/api/v1/fiber-calculator/post?lang=en" \
-H "Content-Type: application/json" \
-H "X-API-Key: YOUR_API_KEY" \
-d '{"sex":"female","age":30,"height":165,"weight":66,"unit":"metric","activity_level":"moderately_active"}'
Response Example¶
Info
The response example below is for demonstration purposes only. Make a live request to this endpoint to receive the full, real-time, and potentially richer JSON structure.
{
"sex": "female",
"age": 30.0,
"height_cm": 165.0,
"weight_kg": 66.0,
"unit": "metric",
"activity_level": "moderately_active",
"tdee_kcal_per_day": 2335.03,
"fiber_intake_g": 32.69,
"fiber_per_kg_g": 0.495,
"fiber_band": "moderate",
"fiber_band_label": "Moderate",
"intake_context": "Current activity supports standard fiber target.",
"action_plan": ["Increase whole-food fiber sources"],
"food_focus": ["Legumes", "Whole grains", "Vegetables"],
"monitoring_plan": "Track intake consistency weekly.",
"_enterprise": {
"client": "Acme Health",
"plan": "pro",
"request_id": "3c5f53bd0712bb3d",
"quota": 120,
"usage_tracking": true
},
"_api_metadata_": {
"endpoint_name": "fiber_calculator",
"response_language": "en"
}
}
Market Positioning¶
Useful in nutrition SaaS, gut-health tools, and preventive wellness products.
Note
Positive numeric values are required for age, height, and weight.
Recommended Endpoints¶
GET /api/v1/6mwt-calculator- 6Mwt Calculator APIGET /api/v1/abi-calculator- Abi Calculator APIGET /api/v1/ava-calculator- Ava Calculator APIGET /api/v1/bri-calculator- Bri Calculator APIGET /api/v1/bsa-calculator- Bsa Calculator APIGET /api/v1/carbs-calculator- Carbs Calculator API