diff --git a/orchestra/views.py b/orchestra/views.py index 79b61e24..02a0076c 100644 --- a/orchestra/views.py +++ b/orchestra/views.py @@ -1,6 +1,7 @@ import json import requests from django.apps import apps +from django.conf import settings from django.http import Http404, JsonResponse from django.contrib.admin.utils import unquote from django.core.exceptions import PermissionDenied @@ -26,7 +27,9 @@ def serve_private_media(request, app_label, model_name, field_name, object_id, f def get_user_info(token): - url = "http://localhost:5000/oauth/userinfo" + # domain = settings.OIDC_PROVIDER.strip("/") + domain = "https://idp.demo.pangea.org" + url = f"{domain}/application/o/userinfo/" access_token = token['access_token'] token_type = token.get('token_type', 'Bearer') headers = {"Authorization": f"{token_type} {access_token}"}