vault binary includes command-line completion for subcommands, flags, and path arguments where supported for the Bash, Fish, or ZSH shell. Other shells are not currently supported.
vault command to install command-line completions like this:
The command is expected to return no output upon successful execution.
This installs the helpers in your shell configuration file depending on the type of shell you use:
Once you have installed the completions, you should restart your terminal session or reload the shell to begin using them.
Now when you type
vault followed by pressing tab, Vault will suggest command options:
agent auth delete lease login operator plugin print secrets ssh token write audit debug kv list namespace path-help policy read server status unwrap
This extends into sub-commands as well; for example, here is what typing
vault operator followed by pressing tab suggests as sub-commands:
generate-root key-status raft rotate step-down init migrate rekey seal unseal
These completions are helpful for beginners to discover commands and also handy for advanced Vault users who frequently need to quickly and accurately execute more complex commands.
If you visited this page from the Install Vault section of the Getting Started guide, then your installation of Vault is complete. Please proceed to Starting the Server to continue getting started with Vault.