/// <summary> /// Method to retrieve HTTP get response for an api call with path level throttling for API calls /// </summary> /// <param name="url">The exact path to be used in the call</param> /// <param name="urlPattern">the pattern that serves as key for the throttling mechanism</param> /// <param name="callsPerIntervalAllowed">The number of calls that can be sent out in a second without throttling (0 = no throttling)</param> /// <returns></returns> private string GetStringResponse(string url, string urlPattern, int callsPerIntervalAllowed, int intervalLenghtInSeconds = 1) { try { if (!RequestThrottling) { callsPerIntervalAllowed = 0; } return(GetRequest.DownloadResult(url, urlPattern, intervalLenghtInSeconds, callsPerIntervalAllowed)); } catch (Exception ex) { throw new BinanceHTTPApiRequestException(string.Format("An error occured during an API a GET call to {0}", url), ex); } }