Skip to content

Commit

Permalink
SP-803 PHP SDK - Proxy
Browse files Browse the repository at this point in the history
  • Loading branch information
mwarzybok-sumoheavy committed Feb 6, 2024
1 parent da1b9d4 commit 4de29cf
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 35 deletions.
65 changes: 31 additions & 34 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion src/BitPaySDK/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,9 @@ public static function createWithFile(string $configFilePath): Client
$config = $configData["BitPayConfiguration"]["EnvConfig"][$env];

$key = self::initKeys($config['PrivateKeyPath'], $config['PrivateKeySecret']);
$proxy = $config['proxy'] ?? null;

$restCli = new RESTcli($env, $key, $config['proxy']);
$restCli = new RESTcli($env, $key, $proxy);
$tokenCache = new Tokens($config['ApiTokens']['merchant'], $config['ApiTokens']['payout']);

return new Client($restCli, $tokenCache);
Expand Down

0 comments on commit 4de29cf

Please sign in to comment.