This is a template for a Go API project. It includes the following features:
- Clean Architecture
- Swagger Documentation
- Dockerized
- Makefile for easy setup
- API Security
- API Logging
- API Testing
- Git - Git CLI
- Code Editor - Basic code editor
- Golang - Golang
- Docker - For containerization and local environment (if you're not using Makefile)
- GoSec & Golang-Lint - Go Validators
- GoFumpt - Stricter GoFMT
- Redoc-CLI - For generating API Documentation (npm install -g @redocly/cli)
Download all necessary modules and run the application
go mod download
make run
make docker
After first setup you can use docker-compose to start and stop / restart the application
docker-compose up
docker-compose down
Swagger documentation is available at http://localhost:8080/docs
To generate the Swagger documentation, you can run the following command:
make swagger
You can find the detailed contributing guidelines by navigating to the CONTRIBUTE.md
file in the repository.
- Swagger - Swagger Documentation, available after running the application