Documentation ¶
Index ¶
Constants ¶
View Source
const ( // UserKey is the context name for user credential. UserKey = "user_id" // ApiKey is the context name for user api key. ApiKey = "api_key" // RoleKey is the context name for user's role RoleKey = "role" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type API ¶
type API interface { // LogoutHandler deletes session. LogoutHandler() gin.HandlerFunc // LoginHandler authenticates user and starts sessions. LoginHandler() gin.HandlerFunc // GetSessionsCount returns active sessions count. GetSessionsCount() gin.HandlerFunc }
Click to show internal directories.
Click to hide internal directories.