Kabelwerk’s SDK for Python
Welcome to the documentation of the Kabelwerk SDK for Python!
Installation
The SDK is available at the Cheese Shop:
# usually inside a virtual environment
pip install kabelwerk
Releases follow semantic versioning. Make sure to check the CHANGELOG.rst whenever upgrading to a newer version.
Configuration
You will need:
The URL of the Kabelwerk backend you will make requests to.
A valid API token for authenticating the requests.
You can set this in the SDK’s config at runtime:
import kabelwerk.api
import kabelwerk.config
kabelwerk.config.KABELWERK_URL = 'example.kabelwerk.io'
kabelwerk.config.KABELWERK_API_TOKEN = '<secret>'
# once the config is set you can use the API functions
kabelwerk.api.update_user(key='test-1234', name='Test user')
Alternatively, you can set the environment variables KABELWERK_URL
and
KABELWERK_API_TOKEN
— these will be read when you first import the SDK.
If you have a Django project, you can also configure the SDK in your settings. Check the Django integration page for more details.