Description
Fix white-labeling issue where the OAuth success/redirect page (/redirect?status=success) always shows the default Composio logo instead of the customer's configured whitelabel logo.
Root cause: The OAuth callback handler (handleAuthCallback) did not include the project's custom logo URL when constructing the redirect URL. The redirect page at platform.composio.dev/redirect had no way to know about the whitelabel configuration.
Fix (backend side):
- Added
config: true to the project select in handleAuthCallback to fetch the project configuration
- Parse
ProjectConfigSchema to extract logoURL from the project config
- Added
appLogo field to the CallbackResult interface
- Pass
appLogo as a query parameter in the redirect URL when present
Companion frontend PR: ComposioHQ/frontend — reads the appLogo query param and displays it via AppIcon instead of the hardcoded Logo component.
Ticket: T-11225
Triggered by: palash@composio.dev | Source: slack
Session: https://zen-api-production-4c98.up.railway.app/dashboard/#/chat/zen-64c28838f6cf
How did I test this PR
- Ran
vitest run src/lib/connected_accounts/handleOAuthCallback.test.ts — 7 passed
- Ran
vitest run src/pages/api/v3/toolkits/auth/callback.test.ts — 1 passed
- Verified Apollo health check passes (
curl localhost:9900/api/healthz)
- Frontend lint passes with 0 errors
- TypeScript compilation clean for changed files