package auth // Role represents a user's role in the system. type Role string // Predefined roles. const ( RoleAdmin Role = "admin" // Full access to all features RoleUser Role = "user" // Limited access (not currently used) ) // Context holds the authenticated user's information. // This is stored in the request context during authentication. type Context struct { UserID uint // The user's database ID Username string // The user's username for display Role Role // The user's role (admin or user) } // IsAdmin checks if the user has admin privileges. func (c *Context) IsAdmin() bool { return c.Role == RoleAdmin }