Add get_json method to 3pid http client. Better logging for errors in 3pid requests