Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

ToucanToco/toucan-client

Repository files navigation

Pypi-v Pypi-pyversions Pypi-l Pypi-wheel GitHub Actions codecov

Installation

pip install toucan_client

Usage

# Initialize client
auth = ('<username>', '<password>')
client = ToucanClient('https://api.some.project.com/my_small_app', auth=auth)

# Retrieve ETL config
etl_config = client.config.etl.get()  # -> GET 'https://api.some.project.com/config/etl'
client.config.etl.get(stage='staging')  # -> GET 'https://api.some.project.com/config/etl?stage=staging'

# Operations control, start a preprocess
client.data.preprocess.post(stage='staging', json={'async': True})

# Operations control, release to prod
client.data.release.post(stage='staging')

Development

You need to install poetry either globally or in a virtualenv. Then run make install