how to go to form a multi-level structure of the json:
[{ status: 200, body: { user: 'Bravis' }]
That is, trying to do so:
jsonResp := map[string]string { "status" : "200", }, body : map[string]string { "user" : u.Value "hand" : "Right", }, } jsonResponse, _ := json.Marshal(jsonResp) fmt.Fprintf(w, string(jsonResponse))
But this trick does not work