VeganCheck.me API Documentation
The VeganCheck.me API is currently in it's early alpha-phase.
The API combines parts of the OpenFoodFacts Database, the OpenBeautyFacts Database, the Brocade.io Database and the Open EAN/GTIN Database. It gives out the following information about a product through the products EAN/UPC/GTIN code:
- Name of the product
- Is it vegan?
- Is it vegetarian?
- Does it contain palmoil?
- The nutriscore of the product
- If it has been tested on animals
- Where this data comes from
There is also a VeganCheck.me Ingredients API, documented here.
How to use
The APIs base path is https://api.vegancheck.me/v0/product and gives out a JSON response.
You can find the monitoring status page here.
To use the API, you currently have to authenticate using the non-standard HTTP-Header AUTH-KEY.
You can use the key "alpha".
The following parameters are available as of now:
|product||transmit the barcode of the product||GET (as URL-param)|
|product||transmit the barcode of the product||POST (as JSON)|
The URL-parameter product can be passed directly through the url of the request as in:
The post-parameter ean can be passed through the request together with a form-encoded header:
Both requests get you the exact same results and you can use the one you like more. At least one of those methods is required, otherwise the API will throw an error.
We use standardized HTTP status codes as responses. Depending on which language you want to use to implement the API in, you may have to disable error-handling or ignore errors.
A successful request will throw a result like this:
- The field nutriscore will always return n/a when data_source→database is OpenBeautyFacts, Brocade.io or Open EAN Database.
- The field not_tested_on_animals will always return n/a if data_source→database is not OpenBeautyFacts.
- The field contains_palmoil will always return n/a if data_source→database is not OpenBeautyFacts or OpenFoodFacts.
- The field is_vegan may return likely if data_source→database is Open EAN Database.
- n/a is not an error but just means that we don't have any data about the field.
The following error responses can be expected:
- 400 - Missing required parameter, please make sure you sent at least one of the parameters mentioned in Parameters:
- 400 - Required parameter is empty, please make sure the parameter you sent wasn't empty:
- 401 - Please make sure you sent the AUTH-KEY as a header:
- 401 - The AUTH-KEY you sent is unknown:
- 404 - We couldn't find that product in the databases:
- 429 - Your rate limit has exceeded. Please try again later/try another AUTH-KEY:
- 504 - The database server took to long to respond, please try again later (Timeout after 5 seconds):