Skip to main content

Introduction

Konnectors are scripts that import data from a web service and put those data into cozy. Each konnector is an independent application managed by the cozy home application.

Ecolyo uses data from 3 web services :

  • Enedis
  • Grdf
  • Eau du grand Lyon (EGL)

All the konnectors are configured to retrieve user's data as far as 3 years back. Some variation have to be considered :

  • When the user launches the konnector manually, it fetches 1 year of data (in order to reduce running time).
  • When a konnector is launched by the cozy stack (at a random time between 7am and 10am), it fetches 3 years of data.
  • When a konnector retrieves a load at the half-hour timeline (ex: enedis), it fetches back to 4 weeks.

All the konnectors can update previously imported data if it has changed since last execution.

info

Since version 3.1.0 of the app, the konnectors are now also handling the prices.

info

Starting with version 3.2.0, the EGL konnector has been updated to fetch only one month of data daily, instead of retrieving three years’ worth. This change reflects the understanding that data from the past 18 days may still be subject to updates, whereas older data is rarely modified. Adopting this approach aligns with best practices for eco-design, and similar adjustments will be implemented for other konnectors as well.

Documentation

  • Checkout the konnector doc from cozy
  • Error mapping messages displayed to users here

gitlab Repositories

Working with konnectors locally

Cozy resources

Please see also the official cozy documentation.

Run a konnector locally

To develop a konnector or test it, you will need to be able to run a konnector without the constraints imposed by the cozy stack.

To help you, cozy developed a standalone mode for konnectors. Simply launch it by typing:

yarn standalone

This command will create a konnector-dev-config.json file if it was not in your project folder before. This file needs to hold all the information transmitted by the cozy stack when the konnector runs by default

  • baseUrl
  • apiAuthKey
  • login
  • password and so on...

Type them all in the fields object.

All data recovered by the standalone konnector will be stored in the data folder.