From ffcf34eb2443b868f09ad35819badf8600e5b6ac Mon Sep 17 00:00:00 2001 From: antonioturdo Date: Mon, 9 Dec 2024 17:49:11 +0100 Subject: [PATCH] feat: add support to force rest endpoint --- src/Braze.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Braze.php b/src/Braze.php index ac8abdb..80f6393 100644 --- a/src/Braze.php +++ b/src/Braze.php @@ -34,9 +34,9 @@ class Braze private bool $strictValidation = true; - public function __construct(ClientAdapterInterface $clientAdapter, string $apiKey, ?string $restEndpoint = null) + public function __construct(ClientAdapterInterface $clientAdapter, string $apiKey, ?string $restEndpoint = null, bool $forceRestEndpoint = false) { - $this->client = new Client($clientAdapter, $apiKey, new Region($restEndpoint ?? Region::US01)); + $this->client = new Client($clientAdapter, $apiKey, new Region($restEndpoint ?? Region::US01, $forceRestEndpoint)); } public function getClient(): Client