Podaci
Conditions for reuse
Baza podataka Open Food Facts dostupna je pod licencom Open Database License.
Pojedinačni sadržaji baze podataka dostupni su pod licencom Database Contents License.
Slike proizvoda dostupne su pod licencom Creative Commons Attribution ShareAlike.
Mogu sadržavati grafičke elemente zaštićene autorskim pravima ili drugim pravima, koji se u nekim slučajevima mogu reproducirati (prava citiranja ili poštena uporaba).
Please read Terms and conditions of use and re-use before re-using the data.
Recite nam o svojoj ponovnoj upotrebi
Jako nas zanima za što se koriste podaci Open Food Facts. It is not mandatory, but we would very much appreciate it if you tell us about your re-uses so that we can share them with the Open Food Facts community. Također možete ispuniti ovaj obrazac kako biste dobili priliku da vaša aplikacija bude predstavljena.
Open Food Facts data exports
Database dumps and exports are generated nightly. The database is very big, so you can find different ways to use the data, depending on the export flavor.
Informacije o različitim poljima za MongoDB dump i CSV izvoze dostupne su na https://world.openfoodfacts.org/data/data-fields.txt
MongoDB dump
Podaci za sve proizvode dostupni su u dumpu MongoDB baze podataka.
- Poveznica
- https://static.openfoodfacts.org/data/openfoodfacts-mongodbdump.gz
- sha256sum
- https://static.openfoodfacts.org/data/gz-sha256sum
- md5sum
- https://static.openfoodfacts.org/data/gz-md5sum
Delta Export
Daily delta exports are provided for the previous 14 days. The list of currently available delta files can be found at https://static.openfoodfacts.org/data/delta/index.txt.
Each line represents a file that is available at https://static.openfoodfacts.org/data/delta/{filename}.
The filename contains UNIX timestamp of the first and the last change contained in the JSON file, so that the delta files can be imported (after extraction) with mongoimport in alphabetical order.
Please note that due to the nature of mongoexport, the delta files cannot tell you about deleted products. Da biste uklonili izbrisane proizvode iz svoje baze podataka, morat ćete uvesti cjeloviti MongoDB dump.
JSONL data export
The whole database is also available in JSONL format (sometimes called LDJSON or NDJSON) where each line is a JSON object. It represents the same data as the MongoDB export. Datoteka je komprimirana pomoću gzip-a.
Pogodan način iskorištavanja baze podataka je korištenje DuckDB-a, analitičkog alata u procesu dizajniranog za obradu velikih količina podataka u djeliću sekunde. You can read our blog post where we walk you through exploring and processing the Open Food Facts database with DuckDB
Izvoz podataka za parkete na Hugging Faceu
Pojednostavljena verzija JSONL dumpa također je dostupna u Parquet formatu. During the conversion, we filtered columns that contains duplicated information, are used for internal debugging, or are simply irrelevant for users.
Parquet format se pokazao praktičnim:
- Podaci su organizirani po stupcima, a ne po redovima, što štedi prostor za pohranu i ubrzava analitičke upite, tj. možete odabrati samo one stupce koji su vam važni, optimizirajući izvedbu upita, čak i na računalima početne razine.
- Highly efficient data compression and decompression, making it good for storing and sharing big datasets of any kind,
- Supports complex data types and advanced nested data structures.
The dataset is available on Hugging Face, a collaborative Machine Learning ecosystem where developers and researchers can share models and datasets.
Find more information in the Wiki, including guidelines for data reuse and example queries to get started.
Izvoz CSV podataka
Data for all products, or some of the products, can be downloaded in the CSV format (readable with LibreOffice, Excel and many other spreadsheet software) through the advanced search form.
- Poveznice
- Food: https://static.openfoodfacts.org/data/en.openfoodfacts.org.products.csv.gz (compressed CSV in GZIP format: ~ 0.9 Gb, uncompressed: ~ 9 Gb)
- Kozmetika: https://static.openbeautyfacts.org/data/en.openbeautyfacts.org.products.csv.gz
- Pet Food: https://static.openpetfoodfacts.org/data/en.openpetfoodfacts.org.products.csv.gz
- All other products: https://static.openproductsfacts.org/data/en.openproductsfacts.org.products.csv.gz
The file encoding is Unicode UTF-8. The character that separates fields is <tab> (tabulation).
Izvoz RDF podataka
Baza podataka je također dostupna u RDF formatu (ovo je eksperiment, više se ne održava). You can read the announcement in French.
Izvoz podataka slike
Sve slike i rezultati OCR-a mogu se preuzeti s našeg poslužitelja ili s AWS-a (putem AWS Open Data programa). Check out our documentation to learn more about how to download images
OpenAPI Documentation for the JSON API
JSON API je također dostupan za čitanje podataka o proizvodu. Ovaj API se posebno koristi u mobilnoj aplikaciji Open Food Facts.
S vremenom poboljšavamo API, ali pazimo da zadržimo kompatibilnost unatrag. Molimo vas da nas kontaktirate ako ga koristite, kako bismo vam mogli javiti o mogućim promjenama.
Otkrijte naš APIBenefiting from our API? Support the infrastructure that powers your project
Open Food Facts is an independent, non-profit digital commons built for public benefit. We provide our database and API 100% free of charge and open to all, without commercial paywalls or advertising.
Serving millions of real-time queries daily incurs real costs in servers, database clusters, bandwidth, and maintenance. If your application, startup, research project, or company saves time and builds value with our API, please consider supporting Open Food Facts financially. Your contribution keeps our open infrastructure fast, resilient, and freely accessible to everyone worldwide.
Contributing to improving our API and OpenAPI documentation
We're eager to finish the documentation of the API, add use-cases, and automate SDK generation. If you are an OpenAPI connoisseur, you are very welcome to help.
You are very welcome to use the API for production cases, as long as 1 API call = 1 real scan by a user. Any attempt to scrape the database using the API will very likely be blocked, as full daily exports are available on this very page.
Also, sending an HTTP header with your API call is a good way we can get in touch, should any issue arise.
XML API (nije podržano)
You can also get the result in XML by using .xml
Example: https://world.openfoodfacts.org/api/v2/product/737628064502.xml
Ovaj API se ne održava aktivno i nije službeno dokumentiran.Omotači i SDK-ovi
Vjerojatno imamo omotač za vaš omiljeni programski jezik. Ako to učinimo, možeš ga koristiti i poboljšati. Ako to ne učinimo, možete pomoći u njegovom stvaranju.
Omogućit će vam konzumaciju podataka, kao i korisnicima da doprinose novim podacima.
Opća načela za zadovoljstvo vaših korisnika
- Možete pretraživati informacije o proizvodima, uključujući mnoge korisne izračunate vrijednosti.
- Ako ne možete dobiti informacije o određenom proizvodu, možete zatražiti od korisnika da pošalje fotografije i podatke, koje će zatim obraditi Open Food Facts AI i suradnici kako bi dobili izračunati rezultat koji želite prikazati.
- Također možete implementirati cjelokupan tijek tako da odmah dobiju rezultat uz određeni napor s njihove strane.
Ako vaši korisnici ne očekuju rezultat odmah (npr. aplikacije za inventar)
- Pošaljite fotografije (prednja strana/nutritivna vrijednost/sastojci): najmanje bolno za vaše korisnike
- AI Open Food Facts – Robotoff – generirat će neke izvedene podatke iz fotografija.
- S vremenom će druge aplikacije i zajednica Open Food Facts popuniti praznine u podacima.
Android/iPhone/Flutter mobile app
- Pošaljite nutritivne podatke + kategoriju > dobijte Nutri-Score
- Pošalji sastojke > dobi NOVA grupu (o ultra-prerađivanju hrane), aditive, alergene, normalizirane sastojke, vegane, vegetarijance…
- Pošalji kategoriju + oznake > uskoro dobij Eco-Score (o utjecaju na okoliš)
Android/iPhone/Flutter mobile app
The code for the official Open Food Facts mobile apps is available on GitHub Flutter Kotlin Android Swift iOS
We look to turn the deprecated Kotlin and Swift codebases into Kotlin and Swift SDKs, help welcome :-)
Aplikacija omogućuje korisnicima skeniranje barkoda proizvoda, pregledavanje informacija o proizvodima te slanje fotografija i podataka za proizvode koji nedostaju.
Slobodno ponovno koristite kod (otvoreni je kod) i pomozite nam da ga poboljšamo za sve na cijelom planetu.
SDK-ovi
| Ikona | Language / Framework | Resursi | Rasprava |
|---|---|---|---|
| Cordova (stara aplikacija) | GitHub | Ne primjenjivo | |
| DART | GitHub pub.dev | Ne primjenjivo | |
| Elixir | GitHub | Slack kanal | |
| Go | GitHub | Slack kanal | |
| Java | GitHub | Slack kanal | |
| Spring Boot | GitHub | Slack kanal | |
| Kotlin | GitHub | Slack kanal | |
| JavaScript | GitHub | Slack kanal | |
| PHP | GitHub | Slack kanal | |
| PHP (Laravel) | GitHub | Slack kanal | |
| Python | GitHub | Slack kanal | |
| React Native | GitHub | Slack kanal | |
| Ruby | GitHub | Slack kanal | |
| Rđa | GitHub | Slack kanal | |
| R | GitHub | Slack kanal | |
| Brzo | GitHub | Slack kanal | |
| .NET/C# | GitHub | Slack kanal |
Discussing data, API and exports
You can look at common FAQ questions about the API and Data Exports and common Open Food Facts questions
You can join the Open Food Facts Slack chatroom which is the preferred way to ask questions and discuss the API. Please ask your questions in the #api channel
You can open a thread on our API documentation repository
Za sva pitanja u vezi s podacima možete nas kontaktirati na reuse@openfoodfacts.org