An opinionated skeleton implementation of a Go http web server.
A very simple template for a golang web service.
It is opinionated and intended to act as an example of best practices.
Build
./build.sh
(recommended), OR
go build ./...
Run
go run main/skeleton.go
A web server, which:
Exposes one method (/api/answer), which allows GET and POST and responds with JSON
GET /api/answer // 'Hello!'
POST /api/answer 'Stefano' // 'Hello, Stefano!'
Has middleware to limit the type of HTTP request a method will allow
An example 3rd party service client library (skeleton/numbers)
Tests
Contributions are very welcome!
Submit a pull request with: