Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type API ¶
type API struct { Version string Description string PackageName string Auth api.Auth EndpointGroups []*EndpointGroup }
API represents specific API's configuration.
func (*API) Group ¶
func (a *API) Group(name, prefix string) *EndpointGroup
Group adds new endpoints group to API.
type Endpoint ¶
type Endpoint struct { Name string Description string MethodName string NoCookieAuth bool NoAPIAuth bool Request interface{} Response interface{} Params []Param }
Endpoint represents endpoint's configuration.
func (*Endpoint) CookieAuth ¶
CookieAuth returns endpoint's cookie auth status.
type EndpointGroup ¶
type EndpointGroup struct { Name string Prefix string Endpoints map[PathMethod]*Endpoint }
EndpointGroup represents endpoints group.
func (*EndpointGroup) Get ¶
func (eg *EndpointGroup) Get(path string, endpoint *Endpoint)
Get adds new GET endpoint to endpoints group.
type PathMethod ¶
PathMethod represents endpoint's path and method type.
Click to show internal directories.
Click to hide internal directories.