trackup food analyze
by @trackup
analyze a food image with AISpark TrackUp production APIs, using AnalyzeWholeFood for full analysis and dedicated endpoints for macros, ingredients, health i...
clawhub install trackup-food-analyzeπ About This Skill
name: trackup-food-analyze description: analyze a food image with AISpark TrackUp production APIs, using AnalyzeWholeFood for full analysis and dedicated endpoints for macros, ingredients, health insight, and keyword-based food search.
TrackUp Food Analyze
Use this skill to analyze a food image with:
https://deepeat.ai/step.aispark.api.API/AnalyzeWholeFoodhttps://deepeat.ai/step.aispark.api.API/ExtractFoodMacroshttps://deepeat.ai/step.aispark.api.API/AnalyzeIngredientshttps://deepeat.ai/step.aispark.api.API/GetHealthInsighthttps://deepeat.ai/step.aispark.api.API/SearchFoodRules
POSTContent-Type: application/jsonimage_url or image_base64image_base64 winsimage_base64 must be raw base64 without data:image/...;base64,AnalyzeWholeFood directlyExtractFoodMacros for basic macro extractionAnalyzeIngredients for deep ingredient and metabolic analysisGetHealthInsight for professional health insightSearchFood request body must contain keywordSearchFood returns at most the first 20 resultsAPI Selection
Choose the API based on the user's intent:
1. Full food analysis: AnalyzeWholeFood
2. Basic macro extraction only: ExtractFoodMacros
3. Deep ingredient and metabolic analysis only: AnalyzeIngredients
4. Professional health insight only: GetHealthInsight
5. Keyword-based lookup without image analysis: SearchFood
Food Search
Use SearchFood when the user wants keyword-based food lookup instead of image analysis.
Request example:
curl --silent --show-error --location \
'https://deepeat.ai/step.aispark.api.API/SearchFood' \
--header 'Content-Type: application/json' \
--data '{
"keyword": "banana"
}'
Expected response shape:
{
"foods": [
{
"food_name": "Banana",
"calories_cal": "89000",
"weight_g": "100",
"carbs_g": "22.8",
"proteins_g": "1.1",
"fats_g": "0.3",
"display_gi": 51,
"brand": ""
}
],
"pagination": {
"size": 20,
"page": 1,
"total": 123
}
}
Local Image Workflow
Convert local image to base64:
base64 < /absolute/path/to/image.jpg | tr -d '\n' > /tmp/food_image.b64
Build payload:
printf '{"image_base64":"' > /tmp/food_image.json
cat /tmp/food_image.b64 >> /tmp/food_image.json
printf '"}' >> /tmp/food_image.json
Call full food analysis directly:
curl --silent --show-error --location \
'https://deepeat.ai/step.aispark.api.API/AnalyzeWholeFood' \
--header 'Content-Type: application/json' \
--data-binary @/tmp/food_image.json
Proxy Fix
If curl incorrectly tries a local proxy like 127.0.0.1:7890, retry with:
env -u http_proxy -u https_proxy -u HTTP_PROXY -u HTTPS_PROXY -u ALL_PROXY curl ...
Response Fields
AnalyzeWholeFood:
food_nametotal_weight_gtotal_calories_kcalcarbs_gproteins_gfats_gdisplay_gidietary_fiber_gsugar_gingredients[]health_scorehealth_profileExtractFoodMacros:
food_nametotal_weight_gtotal_calories_kcalcarbs_gproteins_gfats_gAnalyzeIngredients:
display_gidietary_fiber_gsugar_gingredients[]GetHealthInsight:
health_scorehealth_profileSearchFood:
foods[]pagination.pagepagination.sizepagination.totalhealth_score meaning:
1-5 score generated by AI food evaluation5 is the highest scoreOutput Rules
AnalyzeWholeFood as the default APISearchFood, return the foods in API order and do not claim more than 20 items unless the response actually contains themCommon Errors
400 invalid_request422 food_not_recognized422 barcode_only_result429 rate_limit_exceeded500 internal_error502 upstream_flow_errorπ Constraints
POSTContent-Type: application/jsonimage_url or image_base64image_base64 winsimage_base64 must be raw base64 without data:image/...;base64,AnalyzeWholeFood directlyExtractFoodMacros for basic macro extractionAnalyzeIngredients for deep ingredient and metabolic analysisGetHealthInsight for professional health insightSearchFood request body must contain keywordSearchFood returns at most the first 20 results