pub struct Identity {
pub account_id: String,
pub email: String,
pub group: Option<String>,
}Expand description
Who a credential belongs to, as the tool’s own service understands it.
How this is learned is deliberately not part of the answer. Claude Code’s is a network call to Anthropic on every switch, because its local config can lag the credential by a day. Codex’s is a local decode of the ID token it already holds. Gemini’s is a local decode when the token carries one and a network call when it does not. The engine wants the answer, not the method.
Fields§
§account_id: StringStable for the life of the account. A UUID for Claude, a UUID for Codex’s
chatgpt_account_id, Google’s sub for Gemini.
email: String§group: Option<String>Claude’s organisation, Codex’s ChatGPT workspace, Gemini’s project. None where the
tool has no such concept or did not say, which is not the same as an empty one.
Trait Implementations§
impl Eq for Identity
impl StructuralPartialEq for Identity
Auto Trait Implementations§
impl Freeze for Identity
impl RefUnwindSafe for Identity
impl Send for Identity
impl Sync for Identity
impl Unpin for Identity
impl UnsafeUnpin for Identity
impl UnwindSafe for Identity
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.