[go-nuts] How to use thrifter.ToJSON() function

2022-06-08 Thread Vaishnavi Singh
Hi all! I'm working on a project in golang, where I have to convert a thrift string into json. I came across thrifter package. thrift-iterator . Please help me write 1) How to import? 2) Import external dependencies using bazel 3) Also

[go-nuts] Unmarshal semi-structured json data

2022-06-16 Thread Vaishnavi Singh
hi, input: { "birds": { "pigeon":{ "id": 1, "name": "a" }, "eagle":{ "id": 2, "name": "b" } }, "animals": "none" } let us say this is the json data that we have. I want write code to unmarshal data for input.birds[pigeon].name I should get a. Please can someone help me out with structure of thi