Skip to content

Commit a0cb30b

Browse files
committed
hotfix: KG new auth
1 parent 9c12770 commit a0cb30b

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

app/ebrains_token.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
class TokenWrapper:
3030
def __init__(
3131
self,
32-
iam_url='https://services.humanbrainproject.eu/oidc',
32+
iam_url='https://iam.ebrains.eu/auth/realms/hbp/protocol/openid-connect',
3333
client_id=None,
3434
client_secret=None,
3535
refresh_token=None):
@@ -60,8 +60,7 @@ def _get_new_token(self):
6060
url,
6161
headers={'content-type': 'application/x-www-form-urlencoded'},
6262
data={
63-
'grant_type': 'refresh_token',
64-
'refresh_token': self.refresh_token,
63+
'grant_type': 'client_credentials',
6564
'client_id': self.client_id,
6665
'client_secret': self.client_secret
6766
})
@@ -102,7 +101,6 @@ def get_token(self):
102101

103102
return self.access_token
104103

105-
106104
token_wrapper = TokenWrapper(
107105
client_id=_client_id,
108106
client_secret=_client_secret,

0 commit comments

Comments
 (0)