The Sifflet CLI is a tool that enables you to interact with the Sifflet application using commands in your command line shell.
With minimal configuration the Sifflet CLI enables you to run commands that implement functionality equivalent to that provided by the browser-based Sifflet application from the command prompt in your terminal program.
To see all available commands of Sifflet's CLI, please refer to this page.
In order to configure your CLI, you will need an API token. You can see here how to generate one .
- Python 3.7 or greater
- Your tenant name: if you access to Sifflet with
<https://abcdef.siffletdata.com>, then your tenant would be
- A Sifflet API access token
Open a terminal and verify you have installed Python correctly via
python -V. Ensure you have v3.7 or greater.
Install sifflet CLI
pip install sifflet
Confirm the installation with the following command
$ sifflet --version sifflet, version x.x.x
Upgrade your existing Sifflet CLI installation using
pip install sifflet --upgrade
Before using the Sifflet CLI, you need to set your tenant and credentials. You can do it in several ways:
- Sifflet command line
sifflet configure(which will persists configuration in a file)
- Or with environment variables
You can input the tenant and credentials directly with the
sifflet configure command
$ sifflet configure Your tenant name [None]: <my_tenant> Your API access token [None]: <my_secret_token>
The use of sifflet configure will persist the configuration in a file located at
~/.sifflet/config.ini (or in
%UserProfile%\.sifflet/config.ini on Windows).
To use environment variables, you can do the following:
$ export SIFFLET_TENANT=<my_tenant> $ export SIFFLET_TOKEN=<my_secret_token>
You can check that setup is done correctly with
$ sifflet status Sifflet version = x.x.x Tenant = my_tenant Tenant is up and reachable Token expiration date = 2024-01-01 00:00:00 Token is valid with scope API Status = OK
If you encounter any error at this step, please check your tenant and token configurations.
The --help option is available for any command.
Or for a specific command:
sifflet rules list --help.
Updated 4 months ago