Getting Started with the Sindri CLI
Build your first ZKP circuit with the Sindri CLI
The Sindri CLI provides a streamlined and intuitive way to access the Sindri platform's features. In this guide, we'll walk through the process of installing the Sindri CLI, verifying that it's working, and using it to create your first ZKP circuit on the Sindri platform. For a comprehensive overview of all available commands, refer to our CLI Reference Documentation.
Watch the entire process in the terminal recording below, or follow the detailed step-by-step guide that follows.
Install the Sindri CLI​
The Sindri CLI is written in TypeScript and can be installed using npm with Node.JS v18 or later. We recommend that you use a node version manager such as nvm, fnm, n, or asdf to manage your node installation. This approach makes it easy to ensure that you have a recent version of node available and enables easy global installation of npm packages.
# Install or update the Sindri CLI to the latest version.
npm install -g sindri@latest
You can rerun the above command anytime to update the Sindri CLI to the latest version.
If you encounter an EACCES: permission denied
error during installation, it signifies a misconfiguration in your Node.js environment for global package installations.
To fix this, see Resolving EACCES permissions errors when installing packages globally.
Verify Your Installation​
Verify the installation and version of the Sindri CLI by executing the sindri --version
command.
# Check that the Sindri CLI is installed and using the latest version.
sindri --version
v0.0.1-alpha.71
In case of an error message or an older version number, refer back to the steps in Install the Sindri CLI for troubleshooting.
Authenticate the Client​
If you're a first-time user of the Sindri CLI, authenticate your Sindri account with the sindri login
command.
Follow the prompts to input your Sindri credentials, select the appropriate organization, and name the API key for CLI usage.
# Authenticate with your Sindri account.
sindri login
? Username: my-username
? Password: ****************************
? New API Key Name: my-machine-cli
? Select an Organization: my-organization
[10:26:55.504] INFO: You have successfully authorized the client with your Sindri account.
This process saves your credentials in a local configuration file (e.g., ~/.config/sindri/sindri.conf.json
on Linux) for future Sindri CLI commands.
See sindri config
for more information about interacting with this configuration file and its location on other operating systems.