I'm not sure about the structure of `result` dict, but in general it should be ok.