Skip to content

Commit 4c59c3d

Browse files
ErickRamirezDSErickRamirezAUeric-schneider
authored
DOC-4558 Updated setup steps instructing users to supply token (#16)
* DOC-4558 Updated setup steps instructing users to supply token * Clarify application token --------- Co-authored-by: Erick Ramirez <[email protected]> Co-authored-by: Eric Schneider <[email protected]>
1 parent 85ba0a6 commit 4c59c3d

File tree

1 file changed

+32
-29
lines changed

1 file changed

+32
-29
lines changed

docs-src/astra-cli-core/modules/ROOT/pages/getting-started.adoc

Lines changed: 32 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,54 +1,58 @@
1-
= Getting Started with {astra_cli}
1+
= Getting started with {astra_cli}
22

3-
Read this topic to learn how to get started with {astra_cli}.
3+
Initialize the Astra CLI and run your first commands.
44

5-
== Setup
5+
[#get-credentials]
6+
== Retrieve your application token
67

7-
Before issuing CLI `astra` commands, initialize the configuration file `~/.astrarc`.
8-
Run the following command.
9-
You will be asked to provide your token, which begins with `AstraCS:\...`.
10-
The token will be saved so that you're authorized to run the CLI commands.
8+
The Astra CLI requires an _application token_ to authenticate with Astra.
9+
For instructions on how to create an application token, see xref:astra-db-serverless:administration:manage-application-tokens.adoc[].
1110

12-
[source,bash]
11+
To increase the security of your Astra account, DataStax recommends that you grant your application token only the bare minimum xref:astra-db-serverless:administration:manage-database-access.adoc[permissions] required to perform the tasks you'll be running in Astra.
12+
13+
== Set up a new configuration
14+
15+
Use the `astra setup` command to initialize the Astra CLI:
16+
17+
[source,bash,subs="verbatim,quotes"]
1318
----
14-
astra setup
19+
astra setup --token *APPLICATION_TOKEN*
1520
----
1621

17-
Output:
22+
Replace `*APPLICATION_TOKEN*` with your <<get-credentials,application token>>.
23+
The token format is `AstraCS:` followed by a unique token string.
1824

25+
.Result
26+
[%collapsible]
27+
====
1928
[source,bash]
2029
----
21-
_____ __
22-
/ _ \ _______/ |_____________
23-
/ /_\ \ / ___/\ __\_ __ \__ \
24-
/ | \\___ \ | | | | \// __ \_
25-
\____|__ /____ > |__| |__| (____ /
26-
\/ \/ \/
27-
28-
------------------------
29-
--- SETUP ---
30-
------------------------
31-
32-
🔑 Enter token (starting with AstraCS...):
30+
[OK] Configuration has been saved.
31+
[OK] Setup completed.
32+
[INFO] Enter 'astra help' to list available commands.
3333
----
34+
====
35+
36+
The Astra CLI is now initialized and ready to use.
3437

35-
You are all set.
36-
The configuration (mainly your token) is stored in file `~/.astrarc`.
38+
The Astra CLI configuration, including your application token, is stored in `~/.astrarc`.
39+
The information in this file is used whenever you run the `astra` command.
3740

41+
[#first-commands]
3842
== First commands
3943

40-
* Display current version of the cli, validating setup is complete.
44+
* Display the current version of the CLI.
4145

4246
[source,bash]
4347
----
4448
astra --version
4549
----
4650

47-
* Display your configuration list.
51+
* Display your configuration list, validating setup is complete.
4852

4953
[source,bash]
5054
----
51-
bash astra config list
55+
astra config list
5256
----
5357

5458
Output:
@@ -58,8 +62,7 @@ Output:
5862
+-----------------------------------------+
5963
| configuration |
6064
+-----------------------------------------+
61-
| default ([email protected]) |
62-
65+
6366
+-----------------------------------------+
6467
----
6568

0 commit comments

Comments
 (0)