upsert_custom_food
Save or update a custom food with user-confirmed nutrition data and a real source when official search lacks a suitable match; include a unique key for updates.
Instructions
Save a custom food after user confirmation. Use a custom food when official search has no suitable match or the user requests one. For updates, supply its existing uniquekey.
Provide a real nutrition source and known kcal, protein, fat and carbohydrate per 100 g. The source is shown to the user. Omit portion units for gram-based tracking. Use food from the result when recording that food.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"name": "<name>",
"ntr": "<ntr>",
"nutrition_source": "<nutrition_source>"
},
"name": "upsert_custom_food"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ntr | Yes | ||
| name | Yes | ||
| units | No | ||
| uniquekey | No | ||
| nutrition_source | Yes | ||
| client_request_id | No |