Interface IApiKey
Represents an API key with associated metadata.
public interface IApiKey
Properties
AccessLevel
Access level assigned to this API key. Null defaults to Administrator.
AccessLevel? AccessLevel { get; }
Property Value
ApiKey
The raw API key value (only populated on creation; otherwise empty).
string ApiKey { get; }
Property Value
CreatedAt
When the key was created. Reset when the key is recycled (refreshed).
DateTime? CreatedAt { get; }
Property Value
CreatedBy
User who created this key (identity/display name). Null if not recorded.
string CreatedBy { get; }
Property Value
ExpiryDate
Expiry date, or null if no expiry.
DateTime? ExpiryDate { get; }
Property Value
Key
Unique identifier for this API key entry.
string Key { get; }
Property Value
LastUsedAt
When the key was last used to authenticate, or null if never used. Reset when the key is recycled (refreshed).
DateTime? LastUsedAt { get; }
Property Value
Name
Human-readable name for this API key.
string Name { get; }
Property Value
Roles
Roles assigned to this API key.
string[] Roles { get; }
Property Value
- string[]
ScopeOverrides
Scope overrides for this API key.
string[] ScopeOverrides { get; }
Property Value
- string[]
SystemScopes
Explicit scopes granted to a system key at creation time. Null/empty for team keys.
string[] SystemScopes { get; }
Property Value
- string[]
Tags
System-set key-value tags on this API key. A list (not a map), so a key may repeat.
Set only at creation via the service; immutable thereafter and not editable from the UI.
Each tag is surfaced as a tag.{Key} claim on the authenticated principal.
IReadOnlyList<Tag> Tags { get; }
Property Value
TeamKey
Team that owns this API key. Null for system keys (not bound to a team).
string TeamKey { get; }