delete

Description

Delete a specific version of a secret. This action permanently removes the version and cannot be undone.

Synopsis

$ abeja secret-version delete [--help]
Usage: abeja secret-version delete [OPTIONS]

  Delete a secret version

Options:
  -s, --secret_id, --secret-id TEXT
                                  Secret ID  [required]
  -v, --version_id, --version-id TEXT
                                  Version ID  [required]
  --organization_id, --organization-id TEXT
                                  Organization ID. If not specified, the current
                                  organization ID is used.
  -y, --yes                       Skip confirmation prompt
  --help                          Show this message and exit.

Options

-s, --secret_id, --secret-id

Specify the ID of the secret that contains the version you want to delete. This option is required.

-v, --version_id, --version-id

Specify the ID of the specific version you want to delete. This option is required.

--organization_id, --organization-id

Specify the organization ID. If not specified, the current organization ID from the configuration is used.

-y, --yes

Skip the confirmation prompt and proceed with deletion immediately. Use with caution.

Example

Delete a secret version with confirmation

Command:

$ abeja secret-version delete --secret-id secret-abcdef123456 --version-id version-123456789012

Output:

Are you sure you want to delete the following secret version?
  - ID: version-123456789012
  - Secret ID: secret-abcdef123456
  - Version: 2
  - Status: active
  - Created at: 2023-05-12T10:30:00.000000Z
[Y/n]: Y
Secret version deleted successfully
{
  "message": "Secret version deleted"
}

Delete a secret version without confirmation

Command:

$ abeja secret-version delete --secret-id secret-abcdef123456 --version-id version-098765432109 --yes

Output:

Secret version deleted successfully
{
  "message": "Secret version deleted"
}