Documentation ¶
Index ¶
Constants ¶
View Source
const ( // APIv1 denotes the v1 endpoint. APIv1 = "/api/v1" // HealthEndpoint denotes the 'health' endpoint. HealthEndpoint = "health" // HealthPath denotes the 'health' endpoint. HealthPath = "/" + HealthEndpoint // LoginEndpoint denotes the 'login' endpoint. LoginEndpoint = "login" // LoginPath denotes the 'login' endpoint. LoginPath = "/" + LoginEndpoint // SignupEndpoint denotes the 'signup' endpoint. SignupEndpoint = "signup" // SignupPath denotes the 'signup' endpoint. SignupPath = "/" + SignupEndpoint )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
Endpoints map[string]*EndpointConfig `json:"endpoints" binding:"optional"`
}
Config denotes the configuration of the server controller.
func NewDefaultConfig ¶
func NewDefaultConfig() *Config
NewDefaultConfig creates a default configuration.
type EndpointConfig ¶
type EndpointConfig struct { // IsDisabled denotes it the Endpoint should be enabled. No value denotes false. IsDisabled bool `json:"isDisabled" binding:"required"` }
EndpointConfig defines the configurations of an Endpoint.
Click to show internal directories.
Click to hide internal directories.