mohnishs1975 / Food-Tracker

0 stars 0 forks source link

FDA API #1

Open TingruLian opened 2 years ago

TingruLian commented 2 years ago

When scanning the bar code labels with our app, an id number of the food will be given. Then the id is to be used to get the nutrient value from FDA. The API we use for FDA will show the information. A sample of using this API is: https://api.nal.usda.gov/fdc/v1/foods/search?api_key=DEMO_KEY&query=0190646641016 And here is a picture of what this sample of the website looks like. "nutrientNumber" is what is used in our code.

Screen Shot 2021-09-16 at 10 25 01

Reference of FDA API: https://fdc.nal.usda.gov/api-guide.html This is from the SW Mini Project ppt.