add_custom_food
Create a custom food in Cronometer with specified nutrients, returning a food ID for logging.
Instructions
Create a custom food in Cronometer with specified nutrition.
Nutrient amounts should be for the full serving size specified. After creation, use the returned food_id with add_food_entry to log it.
Args: name: Food name. calories: Calories per serving (kcal). protein_g: Protein per serving (g). fat_g: Fat per serving (g). carbs_g: Carbs per serving (g). fiber_g: Fiber per serving (g, default 0). sugar_g: Sugar per serving (g, default 0). sodium_mg: Sodium per serving (mg, default 0). saturated_fat_g: Saturated fat per serving (g, default 0). serving_name: Name for the serving size (default "1 serving"). serving_grams: Weight of one serving in grams (default 100).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | ||
| calories | Yes | ||
| protein_g | Yes | ||
| fat_g | Yes | ||
| carbs_g | Yes | ||
| fiber_g | No | ||
| sugar_g | No | ||
| sodium_mg | No | ||
| saturated_fat_g | No | ||
| serving_name | No | 1 serving | |
| serving_grams | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |