API Tokens

Create and manage personal API tokens for authenticating with the SecretStash API and CLI.

API tokens allow you to authenticate with the SecretStash API from the CLI or any third-party integration. Tokens are personal to your account and are used to identify and authorize your requests.

Creating a Token

Go to Settings > API Tokens from the sidebar navigation.

Enter a token name

Provide a descriptive name for your token (e.g., "CLI Token", "CI/CD Token"). This helps you identify the token's purpose later.

Generate the token

Click Create. A dialog will display your new API token.

Copy the token

Copy the token immediately and store it in a secure location.

Using Your Token

Add the token to your application's .env file for use with the SecretStash CLI:

SECRET_STASH_API_TOKEN=your_token_here

The CLI will use this token to authenticate all API requests. See the CLI Configuration for more details.

Managing Tokens

The API Tokens settings page lists all of your existing tokens, showing:

  • Token name
  • Last used date (or "Never used" if the token hasn't been used yet)
  • Created date

Deleting a Token

Click the Delete button next to any token to revoke it. You will be asked to confirm before the token is permanently removed.

Next Steps