Skip to content
Healthy plant-based meals representing nutrition and food data for the Calorie API

Meal tracking

Meal Tracking API

A meal tracker lives or dies by its logging flow: type a few letters, pick a food, adjust the portion, done. The meal tracking API is built around that flow, a fast suggest endpoint for typeahead, full nutrition on selection, and barcode scanning for packaged foods.

3
endpoints for a full log flow
250ms
typical debounce budget
stable
food IDs for favorites
per 100g
normalized macros

Stable food IDs make re-logging favorites instant, and per-100g normalized macros keep portion math consistent across generic foods, branded products, and scanned items.

Full parameters and response shapes live in the API documentation, and you can try every endpoint in the playground without signing up.

Typeahead → details flow
# 1. Typeahead while the user types
curl "https://calorieapiadmin.com/api/v1/search/suggest?q=oatm&limit=10" \
  -H "X-API-Key: your_api_key_here"

# 2. Full nutrition when they pick a result
curl "https://calorieapiadmin.com/api/v1/foods/8172" \
  -H "X-API-Key: your_api_key_here"

What the meal tracking api gives you

Typeahead-first design

Suggest returns lightweight id/name/brand payloads sized for keystroke-level latency.

Serving metadata

Foods carry serving information so users can log “1 cup” instead of grams.

Barcode logging

Packaged foods log in one scan via UPC/EAN lookup with Open Food Facts fallback.

Favorites-friendly IDs

Stable IDs let you cache details and rebuild recent/favorite lists without re-searching.

Macro math that adds up

Per-100g normalization means portion scaling is one multiplication, for every food.

Per-account rate limits

Limits apply per account, not per IP, safe for mobile fleets behind NAT.

Meal Tracking API: frequently asked questions

Does the API store my users’ meal logs?

No, you own your users’ data. The API provides food search and nutrition data; your app stores logs with the stable food ID and the logged amount.

How do I keep quota usage low in a tracking app?

Debounce suggest calls, cache food details by ID (favorites and recents then cost zero requests), and batch any analytics server-side.

Can users log foods that are not in the database?

Barcode misses return 404 so you can fall back to search, and your app can always support custom user foods alongside API-sourced ones.

Which plan do I need for a consumer meal tracker?

Development fits the free tier. A monetized app is commercial use and needs Plus or Enterprise with the X-API-Usage-Type: commercial header.

Start building today

Create a free account, generate an API key, and make your first request in minutes.