rest

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Sep 25, 2018 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func E

func E(err error, message string, code int) error

E constructs an Error and should be used as a shorthand.

func NewServer

func NewServer(auth monban.AuthService) http.Handler

NewServer initializes and returns a new HTTP server.

Types

type Error

type Error struct {
	Message string `json:"message"`
	Code    int    `json:"code"`
	// contains filtered or unexported fields
}

Error is the HTTP error returned from the Monban API.

func (*Error) Error

func (e *Error) Error() string

func (*Error) Internal

func (e *Error) Internal() bool

Internal implements the Internal interface and allows to inspect if the error is internal.

Jump to

Keyboard shortcuts

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