コード例 #1
0
        public RestClient(
            ApiRetrySettings apiRetrySettings,
            ILogFactory logFactory,
            ApiCredentials credentials = null)
        {
            _apiRetrySettings = apiRetrySettings;

            var loggingHandler = new LoggingHandler(logFactory.CreateLog(this), new HttpClientHandler(),
                                                    "/0/public/Depth");

            _client = new HttpClient(new AuthenticationHandler(credentials, loggingHandler))
            {
                BaseAddress = new Uri(ApiUrl)
            };
        }
コード例 #2
0
 public AuthenticationHandler(ApiCredentials credentials, HttpMessageHandler next)
     : base(next)
 {
     _credentials = credentials;
 }