Tokens

Store your applications' tokens

Discord Tokens

You can store Discord bot application tokens in the CLI to use later in other features. For example:

  • When generating a Discord bot project, if you have saved tokens, an option to select one of those tokens will appear. If you choose one, it will be automatically inserted into the .env file.
  • Selecting an application to manage emojis in the CLI emoji tool

Your tokens are safe! The CLI does not send any data to the internet — all data saved by the CLI remains on your system only. But be cautious when using this feature in public cloud environments like Replit, for example, as CLI data is publicly exposed to everyone.

Getting Started

Run the CLI:

npx constatic@latest

Then access the presets menu:

Main menu Init discord bot project Manage discord emojis Manage presets Settings Quit

Next, access the Token Presets menu:

Presets🗐 Scripts Tokens Back

New Token

Select the New token option to store a bot application token.

Manage tokens New token List tokens Edit token Delete tokens Back

When you enter your application’s token, the CLI will query the Discord API to retrieve the application’s data. If successful, the token will be stored.

List Tokens

You can list all stored tokens using the List tokens option.

Manage tokens New token List tokens Edit token Delete tokens Back

For security reasons, only the application names will be displayed in the terminal.

Edit Tokens

You can edit a token using the Edit token option.

Manage tokens New token List tokens Edit token Delete tokens Back

If you’ve regenerated a token in the Discord Developer Portal, you can update it in the CLI with this option — just re-enter the token.

Delete Tokens

You can delete multiple tokens at once using the Delete tokens option.

Manage tokens New token List tokens Edit token Delete tokens Back

You can delete saved tokens if you’ve regenerated them in the Discord Portal or simply don’t want them stored in the CLI anymore. With the Delete tokens option, just select the tokens you want to remove (press space to select individually or press A to select all) and delete them.

On this page