Using kolena-client

Testing on Kolena is conducted using the kolena-client Python package. You use the client to create and run tests from your infrastructure that can be explored in our web platform.


The first step to start testing with Kolena is to install kolena-client. From the developer page (</>) on Kolena, generate an API token and set the KOLENA_TOKEN environment variable:
export KOLENA_TOKEN="********"
Client builds can be installed with any Python package manager such as pip and poetry:
pip3 install --extra-index-url "https://$" kolena-client
  1. 1.
    Configure the kolena repository in Poetry:
    poetry config repositories.kolena
    poetry config http-basic.kolena "$KOLENA_TOKEN" ""
  2. 2.
    Add the kolena source to your project by adding this block to your pyproject.toml:
    name = "kolena"
    url = ""
    secondary = true
  3. 3.
    poetry add kolena-client
Seeing authentication issues (401 client error)?
Poetry overhauled its credential handling in 1.2 to fix various issues with private repositories. Consider updating your Poetry installation to the latest stable release.


Before using the kolena-client to create or run tests, initialize a client session:
import os
import kolena
kolena.initialize(os.environ["KOLENA_TOKEN"], verbose=True)
By default, sessions have static scope and persist until the interpreter is exited.
Additional logging can be configured by specifying initialize(..., verbose=True). All logging events are emitted as Python standard library logging events from the "kolena" logger as well as to stdout/stderr directly.

Supported Python Versions

kolena-client is compatible with all active Python versions.
Python Version
Compatible Client Versions
All Versions
All Versions
All Versions
All Versions
3.6 (EOL: December 2021)
≥0.22, ≤0.46