Merge pull request #17284 from xyb/feishucn

feat: add Feishu OAuth integration
This commit is contained in:
Tim Jaeryang Baek
2025-09-12 12:48:45 +04:00
committed by GitHub
4 changed files with 65 additions and 1 deletions

View File

@@ -602,6 +602,8 @@ class OAuthManager:
or (auth_manager_config.OAUTH_USERNAME_CLAIM not in user_data)
):
user_data: UserInfo = await client.userinfo(token=token)
if provider == "feishu" and isinstance(user_data, dict) and "data" in user_data:
user_data = user_data["data"]
if not user_data:
log.warning(f"OAuth callback failed, user data is missing: {token}")
raise HTTPException(400, detail=ERROR_MESSAGES.INVALID_CRED)