Jump to content

Open Food Facts Search API Version 2: Difference between revisions

→‎Conditions on nutrients: added links to API examples
(→‎Features: add links to API to demonstrate the features)
(→‎Conditions on nutrients: added links to API examples)
Line 52: Line 52:


* Per 100g or per serving
* Per 100g or per serving
** energy-kj_100g < 200
** [https://world.openfoodfacts.org/api/v2/search?categories_tags=en:sodas&energy-kj_100g%3C200&fields=code,product_name,energy-kj_100g energy-kj_100g < 200]
** sugars_serving > 10
** [https://world.openfoodfacts.org/api/v2/search?categories_tags=en:sodas&sugars_serving%3E10g&fields=code,product_name,sugars_serving sugars_serving > 10]
* Per the product as sold, or prepared
* Per the product as sold, or prepared
** saturated-fat_100g (as sold)
** [https://world.openfoodfacts.org/api/v2/search?categories_tags=en:sodas&saturated-fat_100g=1&fields=code,product_name,saturated-fat_100g saturated-fat_100g=1 (as sold)]
** salt_prepared_serving (prepared, per serving)
** [https://world.openfoodfacts.org/api/v2/search?categories_tags=en:meals&salt_prepared_100g=1&fields=code,product_name,salt_prepared_100g salt_prepared_serving (prepared, per serving)]


== Development and deployment ==
== Development and deployment ==