Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ServeIndex ¶
func ServeIndex(w http.ResponseWriter, r *http.Request)
ServeIndex responds with index.html view
Types ¶
type EndpointHandler ¶
type EndpointHandler interface { // Serve is called by the `handler` struct defined in this file (handlers.go) // Given application context and an http request. // Returns an interface to serve back to the client (Cannot contain the "error" key) and a point to an models.APIError // both can be nil Serve(ctx *models.AppContext, r *http.Request) (interface{}, *models.APIError) }
Custom handler type for our web app. Provides a models.AppContext struct which allows the handler to interact with the state of the application.
type ExchangeTokenHandler ¶
type ExchangeTokenHandler struct{}
func (ExchangeTokenHandler) Serve ¶
func (h ExchangeTokenHandler) Serve(ctx *models.AppContext, r *http.Request) (interface{}, *models.APIError)
Exchange users Google Id Token for a Squad Up API token, essentially the "login" endpoint.
type HandlerLoader ¶
type HandlerLoader interface {
Load()
}
HandlerLoader interface provides methods useful for loading large numbers of http handlers
Click to show internal directories.
Click to hide internal directories.