Represents an authenticated user in KeenAuth.
This struct is the normalized representation of a user after being processed by a mapper. All OAuth providers are mapped to this common structure.
Fields
:user_id- Unique identifier from the OAuth provider:username- Username (may be nil for some providers):display_name- Human-readable name:email- Email address:roles- List of role strings (populated by processor):permissions- List of permission strings (populated by processor):groups- List of group strings (populated by processor)
Example
%KeenAuth.User{
user_id: "abc123",
username: "jdoe",
display_name: "John Doe",
email: "john@example.com",
roles: ["admin"],
permissions: ["read", "write"],
groups: ["engineering"]
}
Summary
Functions
Creates a new User struct from a map of attributes.