Spaces:
Paused
Paused
Upload app/routers/auth_social.py with huggingface_hub
Browse files
app/routers/auth_social.py
CHANGED
|
@@ -13,7 +13,9 @@ async def oauth_login(provider: str):
|
|
| 13 |
raise HTTPException(status_code=400, detail="Unsupported provider")
|
| 14 |
|
| 15 |
# Simulate redirect url
|
| 16 |
-
return RedirectResponse(
|
|
|
|
|
|
|
| 17 |
|
| 18 |
|
| 19 |
@router.get("/{provider}/callback")
|
|
|
|
| 13 |
raise HTTPException(status_code=400, detail="Unsupported provider")
|
| 14 |
|
| 15 |
# Simulate redirect url
|
| 16 |
+
return RedirectResponse(
|
| 17 |
+
url=f"https://{provider}.com/oauth2/authorize?client_id=123&redirect_uri=https://api.zenith.com/callback"
|
| 18 |
+
)
|
| 19 |
|
| 20 |
|
| 21 |
@router.get("/{provider}/callback")
|