diff --git a/pyclearpass/common.py b/pyclearpass/common.py index 41de070..0099f65 100644 --- a/pyclearpass/common.py +++ b/pyclearpass/common.py @@ -57,7 +57,7 @@ def _send_request(self, url, method, query=""): full_url_path = self.server + url if len(self.api_token) == 0: - cred = _get_api_key(self) + cred = _new_api_token(self) try: self.api_token = cred["access_token"] except TypeError: @@ -116,7 +116,7 @@ def _send_request(self, url, method, query=""): return cred -def _get_api_key(self): +def _new_api_token(self): """ Operation: Obtain an OAuth2 access token for making API calls HTTP Status Response Codes: 200 OK, 400 Bad Request, 406 Not Acceptable, 415 Unsupported Media Type, 200 OK, 400 Bad Request, 406 Not Acceptable, 415 Unsupported Media Type