Skip to content

nb user

nb user provides user account management commands. Currently supports API key rotation for the local authentication adapter.

nb user <action> [args]
ActionDescription
rotate-key <email>Rotate the API key for a user, revoking all existing keys

Generate a new API key for a user and revoke all previous keys:

Terminal window
nb user rotate-key alice@example.com
Key rotated for alice@example.com (user_abc123).
New API key: nb_sk_a1b2c3d4e5f6...
Warning: all previous keys for this user are now invalid.
  • The instance must be configured with the local auth adapter (see Authentication)
  • The user must exist (identified by email address)