How abhishal-ks/yu-kan works
YuKan is a creator-facing YouTube analytics and AI-insights app. A creator signs in through Google OAuth, views a channel profile, requests a recent-upload/90-day analytics report, and can ask follow-up questions grounded in those metrics. The server-side analysis and question routes fetch YouTube data and call Gemini; the dashboard renders the results. The graph also shows policy pages and shared OAuth support. Some route and UI internals were not excerpted, so those links rely on README documentation rather than claims about unsampled implementation details.
Main entry points: dashboard-workspace.tsx Dashboard workspace · google-oauth.ts OAuth helpers · analyze/route.ts Analysis route · ask/route.ts Question route
Components 20
Creator experience
- Landing page
src/features/landing/landing-page.tsx - Dashboard workspace
src/features/dashboard/dashboard-workspace.tsx - Analytics chat
src/features/chat/analytics-chat.tsx - Analysis results
src/features/analytics/analysis-results.tsx - Site footer
src/components/site-footer.tsx
Google identity
- OAuth login route
src/app/api/auth/login/route.ts - OAuth callback route
src/app/api/auth/callback/route.ts - Channel profile route
src/app/api/auth/channel/route.ts - Logout route
src/app/api/auth/logout/route.ts - OAuth helpers
src/lib/google-oauth.ts
Analytics and insights
- Analysis route
src/app/api/analyze/route.ts - Question route
src/app/api/ask/route.ts - Analytics types
src/features/analytics/types.ts
Policies
- Policy pages
src/features/legal/legal-page.tsx - Privacy page
src/app/privacy/page.tsx - Terms page
src/app/terms/page.tsx
Other components
- Creator
- YouTube APIs
- Gemini API
- Google OAuth
Connections 29
- Creator → Landing page: opens app
README.md - Landing page → OAuth login route: starts sign-in
src/features/landing/landing-page.tsx - OAuth login route → Google OAuth: starts OAuth
README.md - OAuth login route → OAuth helpers: uses helpers
src/app/api/auth/login/route.ts - Google OAuth → OAuth callback route: returns authorization
README.md - OAuth callback route → OAuth helpers: exchanges code
src/app/api/auth/callback/route.ts - OAuth callback route → Dashboard workspace: redirects after sign-in
src/app/api/auth/callback/route.ts - Dashboard workspace → Channel profile route: loads profile
src/features/dashboard/dashboard-workspace.tsx - Channel profile route → OAuth helpers: uses helpers
src/app/api/auth/channel/route.ts - Channel profile route → YouTube APIs: fetches channel
src/app/api/auth/channel/route.ts - Dashboard workspace → Analysis route: requests analysis
README.md - Dashboard workspace → Analytics chat: renders chat
src/features/dashboard/dashboard-workspace.tsx - Dashboard workspace → Analysis results: renders report
src/features/dashboard/dashboard-workspace.tsx - Dashboard workspace → Question route: requests answers
README.md - Analysis route → OAuth helpers: uses helpers
src/app/api/analyze/route.ts - Analysis route → YouTube APIs: fetches uploads and metrics
src/app/api/analyze/route.ts - Analysis route → Gemini API: generates insights
src/app/api/analyze/route.ts - Analysis route → Analytics types: returns report data
src/features/analytics/types.ts - Question route → OAuth helpers: uses helpers
src/app/api/ask/route.ts - Question route → YouTube APIs: fetches uploads and metrics
src/app/api/ask/route.ts - Question route → Gemini API: generates answers
src/app/api/ask/route.ts - Analysis results → Analytics types: renders typed results
src/features/analytics/analysis-results.tsx - Dashboard workspace → Site footer: renders footer
src/features/dashboard/dashboard-workspace.tsx - Landing page → Site footer: renders footer
src/features/landing/landing-page.tsx - Privacy page → Policy pages: renders policy
src/app/privacy/page.tsx - Terms page → Policy pages: renders policy
src/app/terms/page.tsx - Policy pages → Site footer: renders footer
src/features/legal/legal-page.tsx - Creator → Logout route: disconnects account
README.md - Logout route → OAuth helpers: uses cookie rules
src/app/api/auth/logout/route.ts