Skip to content

Convenient extension to net/http for the creation of RESTful APIs.

License

Notifications You must be signed in to change notification settings

tideland/go-httpx

Repository files navigation

Tideland Go HTTP Extensions

GitHub release GitHub license Go Module GoDoc Workflow Go Report Card

Description

Tideland Go HTTP Extensions contains helper functions extending the standard net/http package for the daily work with HTTP.

Most important tasks are the wrapping of standard net/http handlers with non-functional tasks like logging, recovery, authorization, throttling, and adding of CORS and ETag headers. Additionally the package contains a convenient way to map the HTTP methods to individual handler methods, like a POST to the method ServerHTTPPost(). In case the handler does not implement the matching method, the error code http.ErrMethodNotAllowed will be returned to the client.

For RESTful APIs also the nesting of handlers and the parsing of paths for URIs like /api/v1/users/{user-id}/orders/{order-id} are supported. Additionally the work with different content types is simplified.

Contributors

About

Convenient extension to net/http for the creation of RESTful APIs.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published