Documentation ¶
Index ¶
- Constants
- Variables
- func InitEventSystem(address string)
- type Authorization
- type Response
- func (w Response) ClientError(message string, err error)
- func (w Response) Created(body interface{})
- func (w Response) DirectiveError()
- func (w Response) Forbidden(msg string)
- func (w Response) Location(loc string) Response
- func (w Response) Ok(body interface{})
- func (w Response) ServerError(message string, err error)
- func (w Response) ServerNewError(message string)
- func (w Response) Unauthorized()
- type Server
Constants ¶
View Source
const ( // ServiceName is used for HTTP API ServiceName = "GEF" // Version defines the api version Version = "0.3.0" )
Variables ¶
View Source
var ( AccessTokenQueryParam = "access_token" AccessTokenCookieKey = "UIAccessToken" )
Functions ¶
func InitEventSystem ¶
func InitEventSystem(address string)
InitEventSystem initializes the event system, or disables it if the address is empty
Types ¶
type Authorization ¶
type Authorization struct {
// contains filtered or unexported fields
}
type Response ¶
type Response struct {
http.ResponseWriter
}
Response encapsulates a http ResponseWriter
func (Response) ClientError ¶
ClientError sets a 400 error
func (Response) Created ¶
func (w Response) Created(body interface{})
Created sets 201/created response code and body
func (Response) ServerError ¶
ServerError sets a 500/server error
func (Response) ServerNewError ¶
ServerNewError sets a 500/server error
Click to show internal directories.
Click to hide internal directories.