Jump to content

API/Read: Difference between revisions

m (Vaiton moved page Read API to API/Read over redirect)
 
(10 intermediate revisions by 6 users not shown)
Line 4: Line 4:
[[API|← Back to API]] (required read)
[[API|← Back to API]] (required read)


'''Please send a UserAgent HTTP Header with the name of the app/service querying, the version, system and an URL if you have one''', so that you are not blocked by mistake.
== Use the API ==
 
To use the read API, please check out the [https://openfoodfacts.github.io/openfoodfacts-server/api/ API documentation] and [https://openfoodfacts.github.io/openfoodfacts-server/api/ref-v2/#get-/api/v2/product/-barcode- how to read product data]
Example: <code>UserAgent: CoolFoodApp - Android - Version 1.0 - https://coolfoodapp.com</code>


== Downloading static data ==
== Downloading static data ==
Line 18: Line 17:


The character that separates fields is  (tabulation).
The character that separates fields is  (tabulation).
For an example on how to import it in postgres, see https://iderr.github.io/p/week-1-new-project-on-openfoodfacts/


==== Encoding ====
==== Encoding ====
Line 85: Line 86:
== Viewing a product ==
== Viewing a product ==


[[API/Read/Product]]
Have a look at: [[API/Read/Product]]


== Searching for products ==
== Searching for products ==


[[API/Read/Search]]
Have a look at: [[API/Read/Search]]