Beispiel #1
0
        public async Task <QueryResponse> GetQueryAsync(QueryRequest request)
        {
            using (var httpClient = HttpClientFactory.Create(AccessToken))
            {
                var uri = new Uri($"{BaseUrl}/{request.ToHttpGetQueryString()}");

                var httpResponseMessage = await httpClient.GetAsync(uri);

                var content = await httpResponseMessage.ToStringContentAsync();

                return(ApiAiJson <QueryResponse> .Deserialize(content));
            }
        }