Fix PocketID OIDC endpoints for auth.jarrett.eu
Build and push images / validate (push) Successful in 2s
Build and push images / build-backend (push) Successful in 5s
Build and push images / build-worker (push) Successful in 5s
Build and push images / build-frontend (push) Successful in 5s

This commit is contained in:
2026-06-06 19:51:08 +01:00
parent 34284f3d9d
commit df6c993709
+2 -2
View File
@@ -92,7 +92,7 @@ async def pocketid_callback(code: str, db: AsyncSession = Depends(get_db)):
async with httpx.AsyncClient() as client: async with httpx.AsyncClient() as client:
resp = await client.post( resp = await client.post(
f"{issuer}/token", f"{issuer}/api/oidc/token",
data={"grant_type": "authorization_code", "code": code, data={"grant_type": "authorization_code", "code": code,
"redirect_uri": f"{settings.base_url}/api/auth/pocketid/callback", "redirect_uri": f"{settings.base_url}/api/auth/pocketid/callback",
"client_id": client_id, "client_secret": client_secret}, "client_id": client_id, "client_secret": client_secret},
@@ -101,7 +101,7 @@ async def pocketid_callback(code: str, db: AsyncSession = Depends(get_db)):
raise HTTPException(status_code=400, detail="Token exchange failed") raise HTTPException(status_code=400, detail="Token exchange failed")
tokens = resp.json() tokens = resp.json()
userinfo_resp = await client.get( userinfo_resp = await client.get(
f"{issuer}/userinfo", f"{issuer}/api/oidc/userinfo",
headers={"Authorization": f"Bearer {tokens['access_token']}"}, headers={"Authorization": f"Bearer {tokens['access_token']}"},
) )
userinfo = userinfo_resp.json() userinfo = userinfo_resp.json()