The DataStax Astra Command-Line Interface (Astra CLI) is a set of commands for creating and managing Astra resources. Astra CLI commands are available for Astra DB and Astra Streaming. They’re designed to get you working quickly, with an emphasis on automation.
Astra CLI provides a one-stop shop for managing your Astra resources through scripts or commands in your local terminal. The wide variety of capabilities include:
Creation and management of Astra DB and Astra Streaming artifacts
Querying & data loading
Organization and user management
Security and token configuration
The advantage for you: Astra CLI makes it possible to submit commands instead of or in addition to using Astra Portal and DataStax API calls.
Astra CLI features are provided especially for operators, Site Reliability Engineers (SREs), and developers who want the option of using commands when working with Astra DB databases and Astra Streaming tenants.
Two quick examples
Here are two quick Astra CLI command examples to demonstrate how Astra CLI manages resources across Astra DB databases and Astra Streaming tenants from your local terminal.
Let’s create an Astra DB database named
demo from the command line:
astra db create demo -k ks2 --if-not-exist --wait
[INFO] Database 'demo' does not exist. Creating database 'demo' with keyspace 'ks2' [INFO] Database 'demo' and keyspace 'ks2' are being created. [INFO] Database 'demo' has status 'PENDING' waiting to be 'ACTIVE' ... [INFO] Database 'demo' has status 'ACTIVE' (took 103513 millis) [OK] Database 'demo' is ready.
Now let’s create a Pulsar tenant:
See the Astra CLI documentation.
See the Astra CLI install instructions↗.