Skip to main content

No project description provided

Project description

pygrocy

Development Build Status PyPI Coverage Status CodeFactor pre-commit

Documentation

Installation

pip install pygrocy

Usage

Import the package:

from pygrocy import Grocy

Obtain a grocy instance:

grocy = Grocy("https://example.com", "GROCY_API_KEY")

or

grocy = Grocy("https://example.com", "GROCY_API_KEY", port = 9192, verify_ssl = True)

Get current stock:

for entry in grocy.stock():
    print("{} in stock for product id {}".format(entry.available_amount, entry.id))

Development testing

You need a Grocy instance running in demo mode at localhost with https (docker or a php server) You can setup url, port and ssl in test/test_const.py

  curl -L https://github.com/grocy/grocy-docker/raw/master/Dockerfile-grocy > Dockerfile-grocy
  docker-compose build grocy
  docker pull grocy/grocy-docker:nginx
  docker-compose up -d
  curl -kX GET https://localhost

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pygrocy-ext-1.0.6.tar.gz (15.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pygrocy_ext-1.0.6-py3-none-any.whl (22.0 kB view details)

Uploaded Python 3

File details

Details for the file pygrocy-ext-1.0.6.tar.gz.

File metadata

  • Download URL: pygrocy-ext-1.0.6.tar.gz
  • Upload date:
  • Size: 15.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.56.2 CPython/3.9.1

File hashes

Hashes for pygrocy-ext-1.0.6.tar.gz
Algorithm Hash digest
SHA256 883d519c2d9e1a573f4b9146c55fda7f5fc78fec698ad573438d6089f067e7b5
MD5 3039477a50f372ee4ce57688a822686c
BLAKE2b-256 9515bb45afe1ac2c47704ca4d547eaaa5f5df6b5536a33796fc0d01eca2d993e

See more details on using hashes here.

File details

Details for the file pygrocy_ext-1.0.6-py3-none-any.whl.

File metadata

  • Download URL: pygrocy_ext-1.0.6-py3-none-any.whl
  • Upload date:
  • Size: 22.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.56.2 CPython/3.9.1

File hashes

Hashes for pygrocy_ext-1.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 b9531e5478a96eb63cb4ef5f8957d631e7a97f29358ef873f6e97cb0d7a91395
MD5 1a091f3e08640549ac8f048317988acc
BLAKE2b-256 13e4633903339c8f762e2ada319d410c94227c150c2f453bed48dc9236a61807

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page