Sign in | Sign up

USDA results in V2 search?

Tagged:

Currently contains 2 posts

Avatar

November 29, 2017 17:18

millerkl9

Is it possible to get USDA foods (NOT common foods, the actual USDA foods) in the search results from /v2/search/instant?

The proposed solution of adding the “filters” parameter (https://gist.github.com/sourcec0de/4c83722ded432c1d161a) doesn’t work, I get the message ""filters" is not allowed".

Avatar

November 29, 2017 17:56

varun

The gist provided above is an outdated doc to an older version of the api.

Here are the correct docs for the instant endpoint https://docs.google.com/document/d/1_q-K-ObMTZvO0qUEAxROrN3bwMujwAN25sLHwJzliK0/edit#heading=h.h3vlpu5rgxy0

In this case, you will only want to set the common query parameter to true. The Nutritionix common foods database contains all of the USDA foods in addition to other foods that USDA does not provide (ex. guacamole).

Reply to thread