Versions in this module Expand all Collapse all v0 v0.3.1 Aug 1, 2022 Changes in this version + func HistoryHandler(w http.ResponseWriter, r *http.Request) + func HomeHandler(w http.ResponseWriter, r *http.Request) + func RegisterHandler(w http.ResponseWriter, r *http.Request) + func ResetHandler(w http.ResponseWriter, r *http.Request) type API + Any *Response + Exactly []Response + type RegexpHandler struct + func (h *RegexpHandler) HandleFunc(pattern *regexp.Regexp, handler func(http.ResponseWriter, *http.Request)) + func (h *RegexpHandler) Handler(pattern *regexp.Regexp, handler http.Handler) + func (h *RegexpHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) + type Response struct + Code int + Payload interface{} v0.3.0 Apr 10, 2018 Changes in this version + const Version + var ErrTagNotFound = errors.New("apidemic: Tag not found") + func DynamicEndpoint(w http.ResponseWriter, r *http.Request) + func FindResponseCode(responseCodeProbabilities map[int]int, method string) int + func Home(w http.ResponseWriter, r *http.Request) + func NewResponse(message string) interface + func NewServer() *mux.Router + func RegisterEndpoint(w http.ResponseWriter, r *http.Request) + func RenderJSON(w http.ResponseWriter, code int, value interface{}) + type API struct + Endpoint string + HTTPMethod string + Payload map[string]interface{} + ResponseCodeProbabilities map[int]int + type Object struct + Data map[string]Value + func NewObject() *Object + func (o *Object) Load(src map[string]interface{}) error + func (o *Object) Set(key string, val Value) + func (v *Object) MarshalJSON() ([]byte, error) + type Tags map[string]string + func (t Tags) Bool(key string) (bool, error) + func (t Tags) Get(key string) (string, bool) + func (t Tags) Int(key string) (int, error) + func (t Tags) Load(src string) + type Value struct + Data interface{} + Tags Tags + func NewValue(val interface{}) Value + func (v Value) MarshalJSON() ([]byte, error) + func (v Value) Update() Value