public async Task <RequestResult> Query(Expr query) { var json = JsonConvert.SerializeObject(query, Settings); var result = await _clientIo.DoRequest(HttpMethod.Post, "", json); RaiseForStatusCode(result); return(result); }
async Task <Value> Execute(HttpMethodKind action, string path, Expr data = null, IReadOnlyDictionary <string, string> query = null, TimeSpan?queryTimeout = null) { var dataString = data == null ? null : JsonConvert.SerializeObject(data, Formatting.None); var responseHttp = await clientIO.DoRequest(action, path, dataString, query, queryTimeout).ConfigureAwait(false); RaiseForStatusCode(responseHttp); var responseContent = FromJson(responseHttp.ResponseContent); return(responseContent["resource"]); }