Documentation ¶
Index ¶
Constants ¶
View Source
const ( PathPing = "/ping" PathConnect = "/connect/auth" PathSuccess = "/success" PathFailure = "/failure" PathHello = "/hello" DataUriImagePng = "data:image/png;base64," )
Variables ¶
View Source
var ( ErrorAnotherServerOnline = errors.New("another server is online") MCallback = app_msg.Apply(&MsgCallback{}).(*MsgCallback) )
Functions ¶
This section is empty.
Types ¶
type Callback ¶
type Callback interface { // Auth redirect url Url() string // Execute OAuth2 flow. This is blocking operation. Flow() error // Startup the server, this is blocking operation. Start() error // Shutdown the server Shutdown() // Wait for the server readiness WaitServerReady() bool // Handler for web server status check Ping(g *gin.Context) // Handler for callback Connect(g *gin.Context) // Handler for Authentication success Success(g *gin.Context) // Handler for Authentication failure Failure(g *gin.Context) }
func NewWithOpener ¶
type MsgCallback ¶
type MsgCallback struct { MsgOpenUrlOnYourBrowser app_msg.Message MsgErrorOpenUrlOnYourBrowser app_msg.Message MsgHitEnterToProceed app_msg.Message MsgResultSuccessHeader app_msg.Message MsgResultSuccessBody app_msg.Message MsgResultFailureHeader app_msg.Message MsgResultFailureBody app_msg.Message MsgHelloHeader app_msg.Message MsgHelloBody app_msg.Message }
type ServerStatus ¶
Click to show internal directories.
Click to hide internal directories.