{"openapi":"3.1.0","info":{"title":"Plate API","version":"1","description":"Indian home food, with sources: dishes, recipes, symptom cards, stage plans and photos."},"servers":[{"url":"https://plate.rachnalabs.com/v1"}],"components":{"securitySchemes":{"appKey":{"type":"apiKey","in":"header","name":"X-Plate-Key"}}},"paths":{"/foods":{"get":{"operationId":"foods","summary":"Search foods","description":"Search nearly 30,000 foods by name, in English or Hindi words (roti, dahi, bhindi, chana). Typo tolerant. Everyday Indian food ranks first. Each result has energy, protein, carbs, fat and fibre per 100 g, and its portions. Caching: ETag, max-age 300.","security":[{"appKey":[]}],"parameters":[{"name":"q","in":"query","required":false,"description":"Words to search for. Empty lists popular foods.","schema":{"type":"string"},"example":"moong dal"},{"name":"kind","in":"query","required":false,"description":"generic, dish or packaged.","schema":{"type":"string"}},{"name":"diet","in":"query","required":false,"description":"veg, egg, non_veg or vegan. Only foods whose diet is known.","schema":{"type":"string"}},{"name":"indian","in":"query","required":false,"description":"true for Indian foods and brands only.","schema":{"type":"string"}},{"name":"source","in":"query","required":false,"description":"usda_foundation, usda_sr, usda_fndds, cnf, cofid, in_pkg or off.","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"1 to 100. Default 20.","schema":{"type":"integer"},"example":5},{"name":"offset","in":"query","required":false,"description":"For paging. Default 0.","schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"query":"roti","total":54,"limit":20,"offset":0,"items":[{"id":"usda-2707713","name":"Bread, chappatti or roti","brand":null,"kind":"dish","basis":"100g","nutrients":{"energy_kcal":299,"protein_g":7.85,"carb_g":46.1,"fat_g":9.2,"fibre_g":9.7},"servings":[{"label":"1 medium chappatti or roti (7\")","grams":40}],"source":{"id":"usda_fndds","name":"USDA FoodData Central, FNDDS (Survey Foods)","licence":"CC0 1.0"}}]}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/foods/{id}":{"get":{"operationId":"food","summary":"One food, every nutrient","description":"Up to 30 nutrients per 100 g (or 100 ml), its portions including Indian katori and spoon measures, and where the data comes from with its licence and attribution. Caching: ETag, max-age 3600.","security":[{"appKey":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"A food id from search.","schema":{"type":"string"},"example":"usda-2707713"}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"usda-2707713","name":"Bread, chappatti or roti","basis":"100g","nutrients":{"energy_kcal":299,"protein_g":7.85,"carb_g":46.1,"fat_g":9.2,"fibre_g":9.7,"iron_mg":2.2,"calcium_mg":36},"servings":[{"label":"1 large chappatti or roti (8\")","grams":52},{"label":"1 medium chappatti or roti (7\")","grams":40}],"source":{"id":"usda_fndds","licence":"CC0 1.0","attribution":"U.S. Department of Agriculture, Agricultural Research Service. FoodData Central.","source_id":"2707713","quality":"calculated from recipe"}}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/foods/barcode/{code}":{"get":{"operationId":"barcode","summary":"A packaged food by barcode","description":"Look up a packaged food by its EAN or UPC barcode, for scanning. Coverage of Indian products grows as Open Food Facts grows. Caching: ETag, max-age 3600.","security":[{"appKey":[]}],"parameters":[{"name":"code","in":"path","required":true,"description":"6 to 14 digits.","schema":{"type":"string"},"example":"8901719134845"}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"off-8901719134845","name":"Parle-G Biscuit","brand":"Parle","barcode":"8901719134845","...":"..."}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/nutrition":{"post":{"operationId":"nutrition","summary":"Nutrition for portions","description":"Send up to 100 foods with grams, or a serving label and a count, and get the nutrition for each and the total. Use it to show a meal or a day. Nothing is stored. Caching: no-store.","security":[{"appKey":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["items"],"properties":{"items":{"description":"object[]. Each item: food_id, and either grams, or serving (a label from the food's servings) with an optional count."}}},"example":{"items":[{"food_id":"usda-2707713","serving":"1 medium chappatti or roti (7\")","count":2},{"food_id":"usda-2708264","grams":150}]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"items":[{"food_id":"usda-2707713","name":"Bread, chappatti or roti","grams":80,"nutrients":{"energy_kcal":239.2,"protein_g":6.28}}],"total":{"energy_kcal":456.7,"protein_g":19.2},"missing":{}}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/meta":{"get":{"operationId":"meta","summary":"Nutrients and data sources","description":"The nutrient keys with names and units, and every data source with its licence and how many foods it gives. Open without a key. Caching: max-age 3600.","security":[],"parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"basis":"Nutrients are per 100 g of edible food, or per 100 ml where a food's basis says 100ml.","nutrients":[{"key":"energy_kcal","name":"Energy","unit":"kcal","group":"energy"}],"sources":[{"id":"usda_sr","name":"USDA FoodData Central, SR Legacy","licence":"CC0 1.0","foods":7793}]}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/health":{"get":{"operationId":"health","summary":"Is Plate up","description":"For uptime monitors. Open without a key and never cached; it checks that the database answers. Caching: no-store.","security":[],"parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"status":"ok","catalog_version":"2026.10.04","db_ms":4,"time":"2026-10-04T10:00:00.000Z"}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/catalog/version":{"get":{"operationId":"version","summary":"Current catalog version","description":"The latest published version, its notes and what changed. Cheap and cached: call it before anything else. Caching: ETag, max-age 60.","security":[{"appKey":[]}],"parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"version":"2026.10.04","published_at":"2026-10-04T08:08:16.528Z","previous_version":null,"notes":"First catalog.","changes":[{"type":"dishes","id":"moong-dal-chilla","op":"upsert"}],"counts":{"dishes":110,"recipes":110}}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/catalog":{"get":{"operationId":"catalog","summary":"The whole catalog, or what changed","description":"Every published item grouped by type. With since, only what changed after that version, deleted items as tombstones. Caching: ETag, If-None-Match, max-age 300.","security":[{"appKey":[]}],"parameters":[{"name":"since","in":"query","required":false,"description":"A catalog version you already have. Only items changed after it are returned, deleted ones as tombstones.","schema":{"type":"string"},"example":"2026.10.04"}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"version":"2026.10.04.2","since":"2026.10.04","full":false,"dishes":[{"id":"moong-dal-chilla","name":"Moong dal chilla","...":"..."},{"id":"boiled-egg","deleted":true}],"recipes":[]}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/{type}":{"get":{"operationId":"type","summary":"All items of one type","description":"One type of content: dishes, recipes, symptom-cards, stages, nutrients, ingredients, tips, conditions, myths, sources, photos. Supports since. Dishes also take search filters. Caching: ETag, If-None-Match, max-age 300.","security":[{"appKey":[]}],"parameters":[{"name":"type","in":"path","required":true,"description":"One of the content types.","schema":{"type":"string"},"example":"dishes"},{"name":"since","in":"query","required":false,"description":"A catalog version you already have. Only items changed after it are returned, deleted ones as tombstones.","schema":{"type":"string"},"example":"2026.10.04"},{"name":"stage","in":"query","required":false,"description":"Dishes only. One of period, follicular, ovulation, luteal, everyday, vrat.","schema":{"type":"string"}},{"name":"meal","in":"query","required":false,"description":"Dishes only. One of breakfast, lunch, snack, dinner.","schema":{"type":"string"}},{"name":"preference","in":"query","required":false,"description":"Dishes only. One of veg, egg, non_veg, jain, vegan.","schema":{"type":"string"}},{"name":"region","in":"query","required":false,"description":"Dishes only. One of north, south, east, west, any.","schema":{"type":"string"}},{"name":"avoid","in":"query","required":false,"description":"Dishes only. Comma separated: dairy, gluten, nuts.","schema":{"type":"string"}},{"name":"nutrient","in":"query","required":false,"description":"Dishes only. One of iron, protein, calcium, slowCarbs, omega3, b6, vitaminC.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"description":"Dishes only. Words in the name or detail.","schema":{"type":"string"},"example":"ragi"}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"version":"2026.10.04","since":null,"items":[{"id":"ragi-dosa","name":"Ragi dosa","...":"..."}]}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/{type}/{id}":{"get":{"operationId":"item","summary":"One item","description":"One published item by its id. Caching: ETag, If-None-Match, max-age 300.","security":[{"appKey":[]}],"parameters":[{"name":"type","in":"path","required":true,"description":"The content type.","schema":{"type":"string"},"example":"symptom-cards"},{"name":"id","in":"path","required":true,"description":"The item's stable id.","schema":{"type":"string"},"example":"cramps"}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"cramps","title":"Cramps","line":"Warm, gentle food and ginger","dish_ids":["adrak-nimbu-pani","saunth-wala-doodh"],"source_ids":["ginger","omega-3"],"food_can_help":true}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/photos/{id}":{"get":{"operationId":"photo","summary":"A photo, resized","description":"Square food photos, resized on request and never enlarged. Public, so they load straight into an image view. WebP or JPEG. Caching: max-age one year, immutable.","security":[],"parameters":[{"name":"id","in":"path","required":true,"description":"A photo id from any item's photo_id.","schema":{"type":"string"},"example":"photo-moong-dal-chilla"},{"name":"w","in":"query","required":false,"description":"Width in pixels, 64 to 2400. Default 900.","schema":{"type":"integer"},"example":600},{"name":"format","in":"query","required":false,"description":"webp (default) or jpeg.","schema":{"type":"string"},"example":"webp"}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":"image/webp"}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}},"/recommendations":{"post":{"operationId":"recommendations","summary":"A day's food for an anonymous context","description":"Send where someone is in their cycle, what they logged and how they eat; get the day's cards, meals or picks, and key nutrients. Only the fields below are accepted. Anything else, like a name or an id, is refused. Plate does not store the request. Caching: no-store.","security":[{"appKey":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["phase","local_date"],"properties":{"phase":{"description":"string. menstrual, follicular, ovulation, luteal, delayed, unknown"},"local_date":{"description":"string. YYYY-MM-DD, only to rotate dishes by day."},"period_day":{"description":"integer. Day of the period, 0 when not on it."},"cycle_day":{"description":"integer. 0 if unknown."},"days_until_period":{"description":"integer | null. When known."},"days_late":{"description":"integer. When the period is late."},"symptoms":{"description":"string[]. cramps, backPain, pelvisPain, breastTenderness, headache, migraine, severePain, bloating, nausea, vomiting, diarrhea, constipation, fatigue, dizziness, fever, chills, waterRetention, acne, moodSwings, irritability, anxiety, sadnessLowMood, brainFog, cryingSpells, lowMotivation, insomnia, restlessSleep, unusualDischargeSmell, vaginalItching"},"moods":{"description":"string[]. happy, calm, energetic, tired, sad, anxious, irritated, angry"},"flow":{"description":"string | null. none, spotting, light, medium, heavy, veryHeavy"},"conditions":{"description":"string[]. pcos, endometriosis, thyroid, anemia, pmdd, fibroids, diabetes"},"preference":{"description":"string. veg, egg, non_veg, jain, vegan"},"region":{"description":"string. north, south, east, west, any"},"goals":{"description":"string[]. easeCramps, moreEnergy, steadyMood, buildIron, pcosFriendly"},"avoid":{"description":"string[]. dairy, gluten, nuts"},"catalog_version":{"description":"string. The version the client has cached, so answers match its photos."}}},"example":{"phase":"luteal","cycle_day":24,"symptoms":["bloating"],"moods":["tired"],"preference":"veg","region":"north","local_date":"2026-10-04"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"stage":"luteal","logged":[{"card_id":"bloating","because":["bloating"],"dish_ids":["saunf-pani","lauki-chana-dal"]}],"food":[{"dish_id":"moong-dal-and-ragi-roti","brings":["luteal-calcium","luteal-slow-carbs"]}],"key_nutrients":["luteal-calcium","luteal-b6","luteal-slow-carbs"],"notes":[],"catalog_version":"2026.10.04"}}}},"400":{"description":"unknown_version: The since version does not exist. Fetch without since."},"401":{"description":"unauthorized: No key, or the key is revoked."},"404":{"description":"not_found: No such type, item or photo in the published catalog."},"413":{"description":"too_large: A request body over 8 KB."},"429":{"description":"rate_limited: Too many requests for this key this minute."},"500":{"description":"server_error: Something went wrong on Plate's side. Retry with backoff."}}}}}}