阅读背景:

从struct中删除字段或将它们隐藏在JSON响应中

来源:互联网 

I've created an API in Go that, upon being called, performs a query, creates an instance of a struct, and then encodes that struct as JSON before sending back to the caller. I'd now like to allow the caller to be able to select the specific fields they would like returned by passing in a "fields" GET parameter.I've created an API in Go that, upon being call




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: