比如我在命令行实现
curl --data '{"jsonrpc":"1.0","id":"curltest","method":"getwalletinfo","params":[]}' http://user:123456@127.0.0.1:18332/
返回内容如
{"result":{"walletname":"","walletversion":169900,"balance":0.00652964,"unconfirmed_balance":0.00000000,"immature_balance":0.00000000,"txcount":9,"keypoololdest":1541586836,"keypoolsize":1000,"keypoolsize_hd_internal":1000,"paytxfee":0.00000000,"hdseedid":"903b49b210bd3ef7e36326b34acdadff831ea1e0","hdmasterkeyid":"903b49b210bd3ef7e36326b34acdadff831ea1e0","private_keys_enabled":true},"error":null,"id":"curltest"}
我如何通过go语言来返回相同的内容?http.post函数能否完成,如果能完成需要怎么做?