routes

package
v0.0.0-...-a114734 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 4, 2017 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EndpointAddUser = iota
	EndpointUpdateUser
	EndpointDeleteUser
	EndpointGetUser
)

Contains the index of all Endpoints

Variables

View Source
var UserEndpoints = router.Endpoints{
	EndpointAddUser: {
		Verb:    "POST",
		Path:    "/users",
		Auth:    nil,
		Handler: handlers.AddUser,
		Params:  &handlers.AddUserParams{},
	},
	EndpointUpdateUser: {
		Verb:    "PATCH",
		Path:    "/users/{id}",
		Auth:    router.LoggedUserAccess,
		Handler: handlers.UpdateUser,
		Params:  &handlers.UpdateUserParams{},
	},
	EndpointDeleteUser: {
		Verb:    "DELETE",
		Path:    "/users/{id}",
		Auth:    router.LoggedUserAccess,
		Handler: handlers.DeleteUser,
		Params:  &handlers.DeleteUserParams{},
	},
	EndpointGetUser: {
		Verb:    "GET",
		Path:    "/users/{id}",
		Auth:    nil,
		Handler: handlers.GetUser,
		Params:  &handlers.GetUserParams{},
	},
}

UserEndpoints is a list of endpoints for this components

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL