def _initialize_credentials(self, auth_token_resp):
    '\n        The auth_token_resp body is of the form:\n        {\n          "access_token": "foo",\n          "refresh_token": "bar",\n          "token_type": "Bearer"\n        }\n        '
    response_body = auth_token_resp.json()
    if ('access_token' not in response_body):
        raise ValueError('Expected "access_token" in response from oauth server')
    if ('refresh_token' in response_body):
        self._refresh_token = response_body['refresh_token']
    access_token = response_body['access_token']
    refresh_token = response_body['refresh_token']
    _keyring.set_password(_keyring_service_name, _keyring_access_token_storage_key, access_token)
    _keyring.set_password(_keyring_service_name, _keyring_refresh_token_storage_key, refresh_token)
    self._credentials = Credentials(access_token=access_token)
The auth_token_resp body is of the form:
{
  "access_token": "foo",
  "refresh_token": "bar",
  "token_type": "Bearer"
}
def _initialize_credentials(self, auth_token_resp):
    '\n        The auth_token_resp body is of the form:\n        {\n          "access_token": "foo",\n          "refresh_token": "bar",\n          "token_type": "Bearer"\n        }\n        '
    response_body = auth_token_resp.json()
    if ('access_token' not in response_body):
        raise ValueError('Expected "access_token" in response from oauth server')
    if ('refresh_token' in response_body):
        self._refresh_token = response_body['refresh_token']
    access_token = response_body['access_token']
    refresh_token = response_body['refresh_token']
    _keyring.set_password(_keyring_service_name, _keyring_access_token_storage_key, access_token)
    _keyring.set_password(_keyring_service_name, _keyring_refresh_token_storage_key, refresh_token)
    self._credentials = Credentials(access_token=access_token)