I am trying to get data similar to what is shown on https://www.fda.gov/Safety/Recalls/default.htm using the api, but I am seeing a lot of discrepancies.

For example when I use the following api call: https://api.fda.gov/food/enforcement.json?search=recalling_firm:%22safeway%22&limit=100 then I see a total of 10 results returned. If I do the same search on the recall website using "Safeway" as the keyword, I only see 5 results returned. What am I missing to get these data sets to match up?

I also see in the food api endpoint searchable fields that the openfda object is listed as searchable, but it always returns empty when when using the food api. Is there another way to get the brand name for food items using this api?

Thank you for your help!!!

bumped to the homepage by Community 2 days ago

This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.


Since you are querying the Food Enforcement endpoint in openFDA, you would have to look at the Enforcement Reports page at the FDA available at https://www.accessdata.fda.gov/scripts/ires/index.cfm in order for the data to match up. Enforcement Reports at the FDA is where openFDA Enforcement endpoints get their data from.

Unfortunately, none of the Food Enforcement query results will have an openfda section populated. There is no harmonization information for foods available to us. Thus the recalling_firm field is your best bet.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.