File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11unofficial_token = # Replace this with your BrawlAPI Token
2- official_token = # Replace this with your Official API token
2+ official_token = # Replace this with your Official API token
3+ official_api_url = # Proxy server to handle requests to API due to IP limitations
Original file line number Diff line number Diff line change 88load_dotenv (find_dotenv ('../.env' ))
99
1010TOKEN = os .getenv ('official_token' )
11+ URL = os .getenv ('official_api_url' )
1112
1213
1314class TestAsyncClient (asynctest .TestCase ):
@@ -20,6 +21,7 @@ async def setUp(self):
2021 self .client = brawlstats .OfficialAPI (
2122 TOKEN ,
2223 is_async = True ,
24+ base_url = URL ,
2325 timeout = 30
2426 )
2527
Original file line number Diff line number Diff line change 88load_dotenv (find_dotenv ('../.env' ))
99
1010TOKEN = os .getenv ('official_token' )
11+ URL = os .getenv ('official_api_url' )
1112
1213
1314class TestBlockingClient (unittest .TestCase ):
@@ -21,6 +22,7 @@ def setUp(self):
2122 self .client = brawlstats .OfficialAPI (
2223 TOKEN ,
2324 is_async = False ,
25+ base_url = URL ,
2426 timeout = 30
2527 )
2628
You can’t perform that action at this time.
0 commit comments