Ejemplo n.º 1
0
 public ReqHubAttribute(string publicKey, string privateKey, string baseAddress = "https://api.reqhub.io")
 {
     if (this.httpClient == null)
     {
         this.httpClient             = HttpClientFactory.Create(new ReqHubMerchantHttpMessageHandler(publicKey, privateKey));
         this.httpClient.BaseAddress = new Uri(baseAddress);
     }
     this.merchantClient = new MerchantClient(this.httpClient);
 }
Ejemplo n.º 2
0
 public ReqHubMerchantMiddleware(RequestDelegate next, IMerchantClient merchantClient)
 {
     this.next           = next;
     this.merchantClient = merchantClient;
 }