/// <summary>
        /// Retrieve time series data
        /// </summary>
        public async Task <IEnumerable <dynamic> > GetTimeSeriesAsync(GetTimeSeriesRequest request)
        {
            string uri = GetUriForGetTimeSeries(request);

            string response = await HttpActionAsync(HttpMethod.Get, uri);

            var timeSeries = JsonConvert.DeserializeObject <IEnumerable <dynamic> >(response);

            return(timeSeries);
        }
        /// <summary>
        /// Generate specific URI for get request
        /// </summary>
        private string GetUriForGetTimeSeries(GetTimeSeriesRequest request)
        {
            // prepare query string
            string queryString = "?";

            queryString += request.From != null ? $"from={Helper.GetDateTimeUtcString(request.From.Value)}& " : "";
            queryString += request.To != null ? $"to={Helper.GetDateTimeUtcString(request.To.Value)}&" : "";
            queryString += request.Limit != null ? $"limit={request.Limit.Value}&" : "";
            queryString += request.Select != null ? $"select={request.Select}&" : "";
            queryString += request.Sort != null ? $"sort={request.Sort}&" : "";
            queryString += request.LatestValue != null ? $"latestValue={request.LatestValue.Value}&" : "";

            string pathString = $"/{request.EntityId}/{request.PropertySetName}";
            string uri        = _baseUri + "/timeseries" + pathString + queryString;

            return(uri);
        }