Wednesday, September 21, 2016

A handy tool for writing RESTful API in golang. It enables you to exchange data between client and server through a uniform JSON format

A handy tool for writing RESTful API in golang. It enables you to exchange data between client and server through a uniform JSON format

iojson provides a convenient way to exchange data between your client and server through a uniform JSON format. It helps you to encode data from Go structs to a JSON string and to decode data from a JSON string to Go structs. iojson supports storing Go objects to a slice or to a map, which means you could reference your object either by a slice index or by a map key according to your preference. After populating data from JSON to Go objects, the methods of the objects remained working.

iojson also provides a HTTP middleware function, which works with Alice (a famous middleware chainer).

https://github.com/junhsieh/iojson

No comments: