astroctl auth apikey revoke
Revoke an API key
Synopsis
Revoke an API key so it stops authenticating.
The key record is kept and marked REVOKED, along with who revoked it and why, so the key stays accounted for. This is the option to reach for when a key may have leaked -- prefer it over 'delete', which removes the record entirely.
Pass the key's ID, not the key itself. Run 'astroctl auth apikey list' to find it.
astroctl auth apikey revoke <key-id> [flags]
Examples
# Revoke a key
astroctl auth apikey revoke 1ffd91a0-70c2-4592-b2db-8d9910817e58
# Record why it was revoked
astroctl auth apikey revoke <key-id> --reason "laptop lost"
# Skip the confirmation prompt
astroctl auth apikey revoke <key-id> --yes
Options
-h, --help help for revoke
--reason string Why the key is being revoked (recorded on the key)
--yes Skip confirmation
Options inherited from parent commands
-o, --output string Output format (json|yaml) (default "yaml")
SEE ALSO
- astroctl auth apikey - Inspect and retire the API keys issued to you