kli is a terminal REPL for querying Azure Data Explorer clusters using KQL (Kusto Query Language). It provides syntax highlighting, schema-aware autocomplete, and multi-cluster profile management — all from your terminal.
- .NET 8 SDK or newer
dotnet tool install -g klidotnet tool update -g klidotnet tool uninstall -g kli-
Add a cluster profile:
kli config add-cluster my-cluster https://<your-cluster>.kusto.windows.net --database <database>
-
Activate the profile:
kli config use my-cluster
-
Start the REPL:
kli
-
Run a query:
MyTable | take 10
| Command | Description |
|---|---|
kli config add-cluster <name> <url> --database <db> |
Add a new cluster profile |
kli config use <name> |
Switch to a cluster profile |
kli config set-database <database> |
Change the active database |
kli config list |
List all configured profiles |
kli config remove <name> |
Remove a cluster profile |
kli uses Azure.Identity and authenticates via your local Azure credentials. Make sure you are logged in:
az loginMIT