Hi
I’ve read the following article: Set up single sign-on (SSO) to access private content
Looks pretty straight forward, but I cannot setup SSO correctly, not sure what I am doing wrong.
I’ve set up SSO with following paramters:
My application code:
```python
@app.get(“/”)
def read_root(request: Request):
if redirect_url := request.query_params.get(“redirect_url”):
jwt_encoded = jwt.encode({“email”: “test@wegroup.be”}, SECRET, algorithm=“HS256”)
url = f"{redirect_url}?jwt={jwt_encoded}"
r = requests.get(url)
url = f"https://help.wegroup.be/_hcms/mem/jwt?redirect_url={redirect_url}&jwt={jwt_encoded}"
print(f"REDIRECTING: {url}")
return RedirectResponse(url)
else:
return JSONResponse({“status”: “ERROR”, “msg”: “Query parameter ‘redirect_url’ required”})
```
I get the following error:
I know best practice is to use a library, I am all in on libraries, but I also like to know how things work. And something like this should be straight forward, but apparently I am missing something…

