Set up your development environment to use Kusto client libraries
Article
Learn how to set up your environment to use Kusto client libraries. You can use these libraries to create apps that connect with a cluster and run queries or ingest data.
In this article, you learn how to install client library packages for your preferred language.
Prerequisites
Select the prerequisites for the programming language used to create your app.
Note
Kusto client libraries are compatible with JavaScript and TypeScript. To convert TypeScript examples to JavaScript, simply remove the type annotations used for variables, parameters, and return values.
Verify installation: In a command shell, run node --version to check that the version is 3.7 or later
A Node.js app or a browser-based web app, such as a React app.
For browser-based web apps:
If your app has a login experience, you can use the @auzre/identity library to issue an authorization token and use withTokenProvider to feed this token to the Kusto client:
If your app doesn't have a login experience, or you prefer to use the Kusto client library to prompt authentication, you need to set up an application registration with the necessary permissions:
In the Authentication tab, select + Add a platform. Then, select Single-page application.
Enter the desired Redirect URIs, select the boxes for Access tokens and ID tokens, and select Configure. For more information on redirect URIs, see Desktop app that calls web APIs.
In the Overview tab, copy the Application (client) ID.
The examples throughout the following tutorials use the Kusto client library to prompt authentication.
Note
If you belong to an organization, restrictions based on organization configurations might prevent you from authenticating. Ask for access from an organization admin or try again on a personal account.
JDK 8 or later
Ensure the java executable is in your PATH
Verify installation: In a command shell, run java -version to check that the version is 8 or later
Maven 3.6.3 or later
Ensure the mvn executable is in your PATH
Verify installation: In a command shell, run mvn -version to check that the version is 3.6.3 or later
Install the package
This section walks you through installing the Kusto client library in your environment.
The following table lists the client libraries and the corresponding package names.
Provides a client for ingesting data into clusters. For more information, see ingest data into your cluster.
Add the Kusto client libraries for your preferred language to your project, or use the package manager appropriate for your language to install the client libraries.
Then add the following dependencies to your pom.xml, replacing the artifact versions with the latest available on Maven Central for kusto-data and kusto-ingest.
The Kusto SDKs contain quick start sample applications. These applications showcase how to authenticate, administer, query, and ingest data using the Kusto client libraries. You can use them as a starting point for your own application by modifying the code or incorporating specific sections into your project.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see: https://aka.ms/ContentUserFeedback.