Overview
![qBraid-CLI](https://mintlify.s3-us-west-1.amazonaws.com/qbraidco/cli/_static/cli_banner.png)
Universal command line interface for interacting with all parts of the qBraid platform.
The qBraid CLI is a versatile command-line interface tool designed for seamless interaction with qBraid cloud services and quantum software management tools.Initially exclusive to the qBraid Lab platform, the CLI now supports local installations as well. This enhancement broadens access to features like qBraid Quantum Jobs, enabling direct access to QPU devices from leading providers like IonQ, Oxford Quantum Circuits, QuEra, Rigetti, and IQM, as well as on-demand simulators from qBraid and AWS, all using qBraid credits, with no additional access keys required.
Getting Started
The qBraid-CLI comes pre-installed and pre-configured in qBraid Lab:
For help, see qBraid Lab User Guide: Getting Started.
Local Setup
If you prefer to use qBraid-CLI on your local machine, you can install it from PyPI with:
pip install qbraid-cli
After installation, you must configure your account credentials to use the CLI locally:
- Create a qBraid account or log in to your existing account by visiting account.qbraid.com
- Copy your API Key token from the left side of your account page:
- Save your API key from step 2 in local configuration file
~/.qbraid/qbraidrc
using:
$ qbraid configure
Basic Commands
$ qbraid
----------------------------------
* Welcome to the qBraid CLI! *
----------------------------------
____ _ _
__ _| __ ) _ __ __ _(_) __| |
/ _` | _ \| '__/ _` | |/ _` |
| (_| | |_) | | | (_| | | (_| |
\__,_|____/|_| \__,_|_|\__,_|
|_|
- Use 'qbraid --help' to see available commands.
- Use 'qbraid --version' to see the current version.
Reference Docs: https://qbraidco.mintlify.app/cli/user-guide/overview
A qBraid CLI command has the following structure:
$ qbraid <command> <subcommand> [options and parameters]
For example, to list installed environments, the command would be:
$ qbraid envs list
To view help documentation, use one of the following:
$ qbraid --help
$ qbraid <command> --help
$ qbraid <command> <subcommand> --help
For example:
$ qbraid --help
Usage: qbraid [OPTIONS] COMMAND [ARGS]...
The qBraid CLI.
Options
--version Show the version and exit.
--install-completion Install completion for the current shell.
--show-completion Show completion for the current shell, to copy it or customize the installation.
--help Show this message and exit.
Commands
configure Configure qBraid CLI options.
credits Manage qBraid credits.
devices Manage qBraid quantum devices.
envs Manage qBraid environments.
jobs Manage qBraid quantum jobs.
kernels Manage qBraid kernels.
To get the version of the qBraid CLI:
$ qbraid --version