Starting off, i wanted to admire the project, It helped many of my customers and users having better service.
Great work ๐๐.
Force refresh option for the JWT token isn't accessible from the other functions calling it from the _request or validate_device_token methods etc.
it should inherit the *args and **kwargs from it when it is called in line 335 in the init.py file
def _request(self, url, endpoint, payload, retrying_env=False, *args, **kwargs):
log.debug(f'Sending request to {url}/{endpoint} with data {payload}')
result = self._session.post(f"{url}/{endpoint}", json=payload, auth=BearerAuth(self.generate_token()))
def _request(self, url, endpoint, payload, retrying_env=False, *args, **kwargs):
log.debug(f'Sending request to {url}/{endpoint} with data {payload}')
result = self._session.post(f"{url}/{endpoint}", json=payload, auth=BearerAuth(self.generate_token(*args, **kwargs)))
so in the case when using validate_device_token i can call it like this validate_device_token(token=token, force_refresh=True)
and that would validate the device token and force refresh it on every request.