Skip to main content

Victron python api

Project description

OCF VRMAPI

ease of contribution: easy

Python client for interacting with the Victron VRM portal (http://vrm.victronenergy.com)

This repo is being maintained by OCF because the original was not being maintained by Victron.

Installation

$ pip install ocf_vrmapi

Examples

>> from ocf_vrmapi.vrm import VRM_API
>> api = VRM_API(username='vrm_username', password='vrm_password')
>> api.get_user_sites(api.user_id)

>>{u'records':
      [{u'accessLevel': 1,
      u'device_icon': u'solar',
      u'geofence': None,
      u'geofenceEnabled': False,
      u'idSite': 4470,
      u'idUser': 5155,
      u'identifier': u'6cecebc2d7de',
      u'name': u'Mukuyu HC',
      u'owner': True,
      u'pvMax': 1458,
      u'reports_enabled': True,
      u'timezone': u'Africa/Kigali'}],
  u'success': True}


>> api.get_consumption_stats(inst_id=4470) 

>>{u'records': {u'Bc': [[1473681210000, 0.018203735351562],
   [1473692010000, 0.018211364746094],
   [1473695610000, 0.036407470703125],
   [1473699210000, 0.054611206054688],
   [1473702810000, 0.054611206054688],
   [1473706410000, 0.054611206054688],
   [1473710010000, 0.054618835449219],
   [1473713610000, 0.054611206054688],
   [1473717210000, 0.036415100097656],
   [1473720810000, 0.054603576660156],
   [1473724410000, 0.054618835449219],
   [1473728010000, 0.054611206054688],
   [1473731610000, 0.054618835449219],
   [1473735210000, 0.018203735351562],
   [1473738810000, 0.018203735351562]],
  u'Gc': False,
  u'Pc': [[1473681210000, 0.018218994140625],
   [1473684810000, 0.018203735351562],
   [1473688410000, 0.036376953125],
   [1473692010000, 0.018218994140625],
   [1473742410000, 0.054641723632812],
   [1473746010000, 0.0181884765625]],
  u'gc': False},
 u'success': True,
 u'totals': {u'Bc': 0.63716125488281,
  u'Gc': False,
  u'Pc': 0.16384887695312,
  u'gc': False}}

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

ocf_vrmapi-0.1.4.tar.gz (6.8 kB view details)

Uploaded Source

Built Distribution

ocf_vrmapi-0.1.4-py3-none-any.whl (6.7 kB view details)

Uploaded Python 3

File details

Details for the file ocf_vrmapi-0.1.4.tar.gz.

File metadata

  • Download URL: ocf_vrmapi-0.1.4.tar.gz
  • Upload date:
  • Size: 6.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for ocf_vrmapi-0.1.4.tar.gz
Algorithm Hash digest
SHA256 712edc7d5fad0e4436605ccb87ede659e25b99459adace20053707336f100748
MD5 788491fb16f5c100d77bfb8b63b998de
BLAKE2b-256 f180a348cc9d2a1602020d2caebdf6830b317c64ec206d9a4a646f557d0df6da

See more details on using hashes here.

File details

Details for the file ocf_vrmapi-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: ocf_vrmapi-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 6.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for ocf_vrmapi-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 0fe723cd107aee5fa968f271ab66aeb52aaeeab406546dad6151344d962ca73f
MD5 5f195fd219f728a991e2e0e19e27e5e6
BLAKE2b-256 f577d2916f51b07466d905b5369dec45ce8600cde7c2c33473d144f9ec587f69

See more details on using hashes here.

Supported by

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