TokenEvents table
The TokenEvents table in the FitStack - V2 schema has 9 columns, keyed by Id, with 1 foreign key to UserTokens.
Append-only audit of a token lifecycle. Entity base, no audit columns.
Columns (9)
| Column | Type | Constraints | Description |
|---|---|---|---|
| Id | uuid | primary key, not null | |
| TokenId | uuid | not null, references UserTokens.Id | CASCADE. |
| EventType | character varying(50) | not null | |
| OccurredAt | timestamp with time zone | not null | |
| Details | character varying(1000) | ||
| EventIpAddress | character varying(45) | ||
| EventUserAgent | character varying(512) | ||
| EventDeviceId | character varying(128) | ||
| EventCustomClaims | character varying(4000) |
Indexes (3)
(TokenId)(IX_TokenEvents_TokenId)(OccurredAt)(IX_TokenEvents_OccurredAt)(TokenId, EventType)(IX_TokenEvents_TokenId_EventType)
Relationships
TokenEvents.TokenIdreferencesUserTokens.Id