Skip to main content

Caruna Plus API library and CLI

Project description

Caruna Plus Client

Donate "Buy Me A Coffee"

Overview

Caruna Plus is a service provided by Caruna, a Finnish electricity distribution company. The service offers customers access to detailed information about their electricity consumption, contracts, and other related data through an online portal and API. The Caruna Plus Client project in your workspace is designed to interact with the Caruna Plus API, allowing users to retrieve and manage their electricity data programmatically.

How to install and use

Install from pypi and run:

pip install caruna-plus-cli
caruna-plus-cli

Then just enter you Caruna Plus credentials and start entering commands.

Tip: in order to list all the commands within the CLI, enter ?

Available functions

Function name What it does
get_api_access_token Get the access token to the Caruna Plus API. With the token, you can make manual curl requests to the API

Installing from sources and running the project for local development

First clone this repo.

Use virtual env to keep the project isolated. Developed using Python 3.9.9

  1. In the project root folder run python -m venv .venv
  2. Activate the venv with source .venv/bin/activate
  3. Install requirements pip install -r requirements.txt
  4. Launch the CLI as a python module python -m carunaservice.cli
  5. Enter your username and password as they are prompted
  6. Type ? into the CLI prompt to see all available functions

Deactivate venv when not needed: deactivate

Thanks and relatad

This project, Caruna Plus Client, is built upon work from the following repositories and projects:

  • oma-helen-cli: An interactive CLI that logs into Oma Helen and offers functions to get contract data or electricity measurement data in JSON format.
  • pycaruna: Caruna API for Python.
  • Caruna API client in Go: Go library for interfacing with Caruna API

I appreciate the work of the contributors and maintainers of these projects, as their efforts provided the foundation for my work.

Attribution

This project uses code, ideas, or assets from the aforementioned repositories under the terms of their respective licenses:

  1. oma-helen-cli

  2. pycaruna

  3. gocaruna

License

This project is licensed under the MIT license. See the LICENSE file for details.

When using this project, you are also bound by the terms of the licenses of the referenced repositories and projects. Please ensure compliance with their requirements.

Acknowledgments

If you have questions or concerns regarding the usage of code from other repositories, please contact us.

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

caruna_plus_cli-0.0.6a0.tar.gz (13.4 kB view details)

Uploaded Source

Built Distribution

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

caruna_plus_cli-0.0.6a0-py3-none-any.whl (17.1 kB view details)

Uploaded Python 3

File details

Details for the file caruna_plus_cli-0.0.6a0.tar.gz.

File metadata

  • Download URL: caruna_plus_cli-0.0.6a0.tar.gz
  • Upload date:
  • Size: 13.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for caruna_plus_cli-0.0.6a0.tar.gz
Algorithm Hash digest
SHA256 99c93ab0615098bb0b5713b4201a114f0a153e05280ba14217f1897513406876
MD5 85a925115cc5eb6b53a4a9a2736733dd
BLAKE2b-256 e56fd277b1946d00d187d5d19b12fb50876f8e96c5393440820a8b115a562cf0

See more details on using hashes here.

File details

Details for the file caruna_plus_cli-0.0.6a0-py3-none-any.whl.

File metadata

File hashes

Hashes for caruna_plus_cli-0.0.6a0-py3-none-any.whl
Algorithm Hash digest
SHA256 3343f81f3a8970fb98674290dd3b3654c6becfdb7dc9790072c1bd749b24616a
MD5 36255ad1d6eeca7b65aafe5324a9a8e7
BLAKE2b-256 f484f7841139267b8b446e082194c2b5982eb4100b0b7b37a1564c82eb449b43

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