pub struct MintedCredentials {Show 13 fields
pub account_id: Option<u64>,
pub email: Option<String>,
pub api_key: String,
pub api_secret: String,
pub api_url: String,
pub refresh_token: Option<String>,
pub capi_key_name: String,
pub redisctl_key_count: usize,
pub account_name: Option<String>,
pub superseded_revoked: Option<bool>,
pub superseded_key_name: Option<String>,
pub capi_newly_enabled: bool,
pub accounts: Vec<LoginAccount>,
}Expand description
Result of a completed login: a Redis Cloud CAPI key pair plus context, ready to persist.
Secret fields are redacted from Debug.
Fields§
§account_id: Option<u64>Numeric account id, matching the id of the matching entry in accounts, so the two can
be compared directly by a caller reading the JSON output.
email: Option<String>§api_key: StringAccount-level CAPI key (x-api-key).
api_secret: StringMinted user secret (x-api-secret-key).
api_url: StringCAPI base URL to record in the resulting cloud profile.
refresh_token: Option<String>Okta refresh token (rotating) to persist for silent re-auth, if the IdP issued one.
capi_key_name: StringName of the minted redisctl-* CAPI key (visible/revocable in the console).
redisctl_key_count: usizeHow many redisctl-* CAPI keys the account has after this mint (best-effort; 0 if the
listing failed). The CLI warns when this grows, since each login mints a new key (D5).
account_name: Option<String>Name of the account the key was minted for, when the API reports one.
superseded_revoked: Option<bool>Whether the key this switch replaced was revoked. None when there was none to revoke.
superseded_key_name: Option<String>The name of that key, so a failed revocation can say which one is left behind.
capi_newly_enabled: boolWhether this login is what switched account-wide programmatic access on. Reported so an account-level change is not made silently.
accounts: Vec<LoginAccount>Every account the signed-in user belongs to. The key is scoped to exactly one of them — the session’s current account — so the CLI can both name the one it used and list the alternatives, which are otherwise only discoverable in the console.
Implementations§
Source§impl MintedCredentials
impl MintedCredentials
Sourcepub fn account_count(&self) -> usize
pub fn account_count(&self) -> usize
How many accounts the signed-in user belongs to.
Sourcepub fn account_label(&self) -> String
pub fn account_label(&self) -> String
The account the key is for, rendered like the listing (Acme (#316941)).
Shared so every place that names the account spells it the same way. account_id is always
one of accounts — both come from the same /accounts response — so the lookup only
misses for a hand-built value.