Tggl python client
Project description
Tggl Python Client
Install
Intall the package using the package manager of your choice:
pip install tggl
Quick Start
from tggl import TgglClient
client = TgglClient('<Your API key>')
flags = client.eval_context({
'user_id': 123,
'email': 'foo@gmail.com',
'plan': 'PRO'
})
# On/Off flags
if (flags.is_active('feature_1')):
print('Feature 1 is active')
# A/B tests
if (flags.get('feature_2') == 'Variation A'):
print('Should display variation A to user')
# A/B test with default value
if (flags.get('feature_2', 'Variation A') == 'Variation B'):
print('Should display variation B to user')
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
tggl-1.1.2.tar.gz
(1.9 kB
view details)
File details
Details for the file tggl-1.1.2.tar.gz.
File metadata
- Download URL: tggl-1.1.2.tar.gz
- Upload date:
- Size: 1.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
560c304e4ddec2d8530d559a4aec3434e831d7e140bc3d925a62f5934d94877d
|
|
| MD5 |
b743c390388e995555695a6127c8ea6a
|
|
| BLAKE2b-256 |
53a95442d3c68e148dd93c285b57579c3e5e532356798d9bd16527a45357b8d6
|