code: def check_token(self, respond):
          
          if respond.status_code == 401:
              self.credential.obtain_token(config=self.config)
              return False
          return True
docs: Check is the user's token is valid