A fork of pygov focused on USDA nutritional database API
Project description
python-usda
⚠️ Since October 1, 2019, the APIs this package relies on have been
deprecated. python-usda 1.x will remove those APIs and rely on the new
Food Data Central
_ APIs.
python-usda is a fork of pygov
_ focused on
USDA's Food Composition Database API <usda>
.
Have a look at the documentation
!
Setup
::
pip install python-usda
Usage
.. code:: python
from usda.client import UsdaClient
client = UsdaClient("YOUR_API_KEY") foods = client.list_foods(5)
for food in foods: print(food.name)
Result::
Abiyuch, raw Acerola juice, raw Acerola, (west indian cherry), raw Acorn stew (Apache) Agave, cooked (Southwest)
.. _Food Data Central: https://fdc.nal.usda.gov/api-guide.html .. _pygov: https://pypi.org/project/pygov/ .. _usda: http://ndb.nal.usda.gov/ndb/doc/ .. _documentation: https://lucidiot.gitlab.io/python-usda/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file python-usda-0.4.6.tar.gz
.
File metadata
- Download URL: python-usda-0.4.6.tar.gz
- Upload date:
- Size: 10.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 12e13e98683fef130bf63f3d6504c2630dbf99645244dfe657ea0f5827d5a7f4 |
|
MD5 | db570ac8e147bf125a0fff470a9c2128 |
|
BLAKE2b-256 | aa753ed7d6cd441231e0b8f32b67c65bd0c579b8f8ebb013c57de5ac9d000f3e |
File details
Details for the file python_usda-0.4.6-py3-none-any.whl
.
File metadata
- Download URL: python_usda-0.4.6-py3-none-any.whl
- Upload date:
- Size: 24.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2945d455631b047584e17e7ce2b5e4a9406b6efe21df1ce09c2ea6f68a39bc31 |
|
MD5 | f673ec756be4eafb5d6c2cebc82e8e66 |
|
BLAKE2b-256 | 142c60c0d274f24fd1cce89c71cf319271ed9565e8e69dabf3fc323b47df68cf |