Easily extendible REST API Service boilerplate aiming to follow idiomatic go and best practice.
Any feedback and pull requests are welcome and highly appreciated. Feel free to open issues just for comments and discussions.
The following feature set is a minimal selection of typical Web API requirements:
- Configuration using viper
- CLI features using cobra
- Structured logging with zap
- Routing with Gin and middleware
- Request data validation using Go Validator
- Redis support using Go redis
- Enables request stats using Gin stats on endpoint
/request/stats
- Enables metrics and observability via Go metrics and Go gin Prometheus on endpoint
/metrics
- Postgres enabled using Go pg
- Http client support using Go resty
- Makefile setup
- Add email support
- Add Oauth support
- Clone this repository
- Rename
_config.yaml
toconfig.yaml
- Run the application to see available commands:
make run
- Run the application with command serve:
make server
- Go installed
- To have psql running and
test
db created