---
title: "Look up a food by barcode (local cache first, then provider)"
method: GET
path: "/api/meals/foods/barcode/{code}"
tags: ["Meals"]
---

# Look up a food by barcode (local cache first, then provider)

`GET /api/meals/foods/barcode/{code}`

## Request

- Base URL: `https://api.hiyd.ai`
- URL: `https://api.hiyd.ai/api/meals/foods/barcode/{code}`
- Auth: HTTP bearer

## Path parameters

- `code` string, required

## Response `200`

Food found

## Other responses

- `404`: Not found. `barcode_lookup_supported` is false when the provider does not offer barcode lookup (FatSecret premier tier) or no provider is configured.

---

[API](https://skmtc.dev/hiyd/apis/hiyd-backend-api.md) - [All operations](https://skmtc.dev/hiyd/apis/hiyd-backend-api/llms.txt) - [OpenAPI document](https://skmtc.dev/hiyd/apis/hiyd-backend-api/revisions/23598d347e1b?raw)
