Documentation ¶
Index ¶
- func CopyURL(base *url.URL, path string) *url.URL
- func DecodeJSONRequest(r *http.Request, into interface{}) error
- func DecodeJSONResponse(r *http.Response, into interface{}) error
- func EncodeJSONResponse(ctx context.Context, w http.ResponseWriter, response interface{}) error
- func EncodeRequestWithToken(token string, next httptransport.EncodeRequestFunc) httptransport.EncodeRequestFunc
- func ErrorEncoder(_ context.Context, err error, w http.ResponseWriter)
- func JSONErrorDecoder(r *http.Response) error
- func NewRouter(logger log.Logger) (*mux.Router, []httptransport.ServerOption)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecodeJSONRequest ¶
func DecodeJSONResponse ¶
func EncodeJSONResponse ¶
func EncodeJSONResponse(ctx context.Context, w http.ResponseWriter, response interface{}) error
func EncodeRequestWithToken ¶
func EncodeRequestWithToken(token string, next httptransport.EncodeRequestFunc) httptransport.EncodeRequestFunc
func ErrorEncoder ¶
func ErrorEncoder(_ context.Context, err error, w http.ResponseWriter)
func JSONErrorDecoder ¶
func NewRouter ¶
func NewRouter(logger log.Logger) (*mux.Router, []httptransport.ServerOption)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.