GeneratedApiKey
AgentPrism.Core.dllThe generated raw API key value and its derived forms.
public sealed record GeneratedApiKey : IEquatable<GeneratedApiKey>Inheritance
Section titled “Inheritance”Implements
Section titled “Implements”Inherited Members
Section titled “Inherited Members”object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Constructors
Section titled “Constructors”GeneratedApiKey()
Section titled “ GeneratedApiKey()”public GeneratedApiKey()Properties
Section titled “Properties”KeyHash
Section titled “ KeyHash”The SHA-256 hash of the raw value. The only form written to the store.
public required byte[] KeyHash { get; init; }Property Value
Section titled “Property Value”byte[]
KeyPrefix
Section titled “ KeyPrefix”The first characters of the raw value; used to distinguish it in a list.
public required string KeyPrefix { get; init; }Property Value
Section titled “Property Value”PlaintextKey
Section titled “ PlaintextKey”The raw value. Visible only at creation time.
public required string PlaintextKey { get; init; }Property Value
Section titled “Property Value”Methods
Section titled “Methods”Equals(object?)
Section titled “ Equals(object?)”public override bool Equals(object? obj)Parameters
Section titled “Parameters”obj object?
Returns
Section titled “Returns”Equals(GeneratedApiKey?)
Section titled “ Equals(GeneratedApiKey?)”public bool Equals(GeneratedApiKey? other)Parameters
Section titled “Parameters”other GeneratedApiKey?
Returns
Section titled “Returns”GetHashCode()
Section titled “ GetHashCode()”public override int GetHashCode()Returns
Section titled “Returns”ToString()
Section titled “ ToString()”Returns a description that carries no raw key.
public override string ToString()Returns
Section titled “Returns”The type name and the prefix; never the raw value.
Remarks
Section titled “Remarks”A record’s compiler-generated ToString prints every property. The
prefix is safe to show - it is what the list view displays - but the raw
value is not.
Operators
Section titled “Operators”operator ==(GeneratedApiKey?, GeneratedApiKey?)
Section titled “ operator ==(GeneratedApiKey?, GeneratedApiKey?)”public static bool operator ==(GeneratedApiKey? left, GeneratedApiKey? right)Parameters
Section titled “Parameters”left GeneratedApiKey?
right GeneratedApiKey?
Returns
Section titled “Returns”operator !=(GeneratedApiKey?, GeneratedApiKey?)
Section titled “ operator !=(GeneratedApiKey?, GeneratedApiKey?)”public static bool operator !=(GeneratedApiKey? left, GeneratedApiKey? right)Parameters
Section titled “Parameters”left GeneratedApiKey?
right GeneratedApiKey?