Coder Social home page Coder Social logo

Comments (7)

patzly avatar patzly commented on May 18, 2024 1

Also calories could be used when the calories field is implemented in the product edit page.

from grocy-android.

prohand avatar prohand commented on May 18, 2024

Hello,
Great enhancement 👋😊

from grocy-android.

patzly avatar patzly commented on May 18, 2024

From the Open Food Facts API Documentation

READ requests allow you to retrieve the nutritional data of a product with a barcode.

GET https://[countrycode].openfoodfacts.org/api/v0/product/[barcode].json

Example:
GET https://world.openfoodfacts.org/api/v0/product/737628064502.json

Authentication
No authentication is required for READ operations.
However, you have to add a User-Agent HTTP Header with the name of your app, the version, system and a url (if any), not to be blocked by mistake.

Example: User-Agent: NameOfYourApp - Android - Version 1.0 - www.yourappwebsite.com

from grocy-android.

patzly avatar patzly commented on May 18, 2024

Json format to get product name:

https://world.openfoodfacts.org/api/v0/product/42100454.json

User-Agent: Grocy Android - v1.2.0 - https://github.com/patzly/grocy-android

{
    "product":{
        "product_name":"Alnatura Mandelschnitte, Mandel"
    }
}

from grocy-android.

patzly avatar patzly commented on May 18, 2024

We'll leave it at the product name for now.

from grocy-android.

ovz93br43v7 avatar ovz93br43v7 commented on May 18, 2024

@patzly Probably is it possible to add also:
https://github.com/openfoodfacts/openbeautyfacts and
https://www.codecheck.info/
?

from grocy-android.

dominiczedler avatar dominiczedler commented on May 18, 2024

https://www.codecheck.info/ is not possible because the API is not open – and it is also protected via Google Captcha.
But maybe we can implement https://world.openbeautyfacts.org/, I will open a new issue for that.

from grocy-android.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.