Fast mock data in Rest API server.
$ go build .
# ouput: mapi
# move `mapi` to local bin or use directly
- json file
data.json
{
"data": "message"
}
- Mock data.json on API
$ cat data.json | mapi serve
- Test
$ curl localhost:8080/mock
# ---- response
# {
# "data": "message"
# }