Skip to content

Latest commit

 

History

History
28 lines (15 loc) · 755 Bytes

README.md

File metadata and controls

28 lines (15 loc) · 755 Bytes

go-revel-rest

Example of REST API to create and retrieve users with Go and Revel framework

Install dependencies

This project uses Revel framework. You can install it by:

go get github.com/revel/revel

go get github.com/revel/cmd/revel

Run

Once Revel framework is installed, you can run the server by:

revel run go-revel-rest

Note that the project must be located under $GOPATH/src/go-revel-rest

Routes

The API routes are defined in conf/routes file:

GET /users Retrieve all the users

GET /users/{id} Retrieve user with id {id}

PUT /users/ Save a new user. id and nickname must be provided as form params.