How miguelink113/volleyball-fantasy works
Volleyball Fantasy is a Next.js app for managing private fantasy volleyball leagues and teams, alongside official match results. The user path runs from Supabase authentication and league selection through fantasy roster and scoring APIs to team views; results have a separate competition/round/group workflow. RFEVB ingestion populates the catalog that these views read. The graph includes documented but unsampled capabilities such as standings and ingestion; connections are included only where the excerpts, source index, or README support them.
Main entry points: FantasyTeamBuilder.tsx Fantasy workspace · route.ts Round score API · repositories Catalog repositories · client.ts Browser Supabase client
Components 31
Web experience
- Sign in
components/auth/SimpleAuth.tsx - League manager
components/dashboard/LeagueManager.tsx - Fantasy workspace
components/fantasy/FantasyTeamBuilder.tsx - Player stats modal
components/fantasy/PlayerStatsModal.tsx - Results page
app/(app)/results/page.tsx - Results views
components/results
Fantasy domain
- Fantasy team API
app/api/fantasy-team/route.ts - League ranking API
app/api/league-ranking/route.ts - League scores API
app/api/league-scores/route.ts - Team rules
lib/services/fantasy/fantasy-team.service.ts
Catalog and scoring data
- Competition roster API
app/api/competition-roster/route.ts - Round score API
app/api/fantasy-round-scores/route.ts - Scoring system
domain/scoring/scoring-v1.system.ts - Catalog repositories
lib/repositories - Standings repository
lib/repositories/standings.repository.ts - Match and player types
domain/match - Player types
domain/player/player.types.ts
RFEVB ingestion
- Ingest cron API
app/api/cron/ingest/route.ts - Catalog ingestion
scripts/ingest - RFEVB scrapers
lib/scraper - Match statistics scraper
lib/scraper/fetch-match-statistics.ts - Team alias resolver
lib/services/ingestion/team-alias-resolver.ts - Esvoley exploration
lib/scraper/esvoley-ingestion.ts
Identity and persistence
- Auth state
hooks/useAuth.ts - User profile
lib/services/profile/profile.service.ts - Supabase catalog
- Browser Supabase client
lib/supabase/client.ts - Server Supabase client
lib/supabase/server.ts - Admin Supabase client
lib/supabase/admin.server.ts
Other components
- Fantasy user
- RFEVB
Connections 37
- Fantasy user → Sign in: signs in
- Sign in → Auth state: uses auth
components/auth/SimpleAuth.tsx - Auth state → Browser Supabase client: authenticates
hooks/useAuth.ts - Auth state → User profile: loads profile
hooks/useAuth.ts - League manager → Browser Supabase client: manages leagues
components/dashboard/LeagueManager.tsx - Fantasy user → League manager: selects league
- Fantasy user → Fantasy workspace: manages team
- Fantasy workspace → Team rules: validates lineup
components/fantasy/FantasyTeamBuilder.tsx - Fantasy workspace → Player stats modal: opens details
components/fantasy/FantasyTeamBuilder.tsx - Fantasy workspace → Browser Supabase client: reads data
components/fantasy/FantasyTeamBuilder.tsx - Fantasy workspace → Fantasy team API: requests team
- Fantasy workspace → Round score API: requests scores
- Fantasy team API → Server Supabase client: authenticates request
app/api/fantasy-team/route.ts - League ranking API → Server Supabase client: checks user
app/api/league-ranking/route.ts - League scores API → Server Supabase client: checks user
app/api/league-scores/route.ts - Competition roster API → Admin Supabase client: queries catalog
app/api/competition-roster/route.ts - Competition roster API → Catalog repositories: loads roster
app/api/competition-roster/route.ts - Round score API → Admin Supabase client: queries season
app/api/fantasy-round-scores/route.ts - Round score API → Catalog repositories: loads match data
app/api/fantasy-round-scores/route.ts - Round score API → Scoring system: scores statistics
app/api/fantasy-round-scores/route.ts - Catalog repositories → Supabase catalog: reads catalog
- Admin Supabase client → Supabase catalog: connects to
lib/supabase/admin.server.ts - Browser Supabase client → Supabase catalog: connects to
- Server Supabase client → Supabase catalog: connects to
- Results page → Admin Supabase client: loads results
app/(app)/results/page.tsx - Results page → Results views: renders views
app/(app)/results/page.tsx - Results views → Standings repository: loads standings
components/results/StandingsTable.tsx - Standings repository → Supabase catalog: reads standings
- RFEVB → RFEVB scrapers: provides data
- RFEVB → Match statistics scraper: provides statistics
- Ingest cron API → Catalog ingestion: triggers ingestion
- Catalog ingestion → RFEVB scrapers: fetches source data
- Catalog ingestion → Supabase catalog: persists catalog
- Esvoley exploration → Team alias resolver: resolves aliases
lib/scraper/esvoley-ingestion.ts - Match statistics scraper → Match and player types: maps statistics
- Catalog repositories → Match and player types: returns typed data
lib/repositories/match-player-stats.repository.ts - Team rules → Player types: uses positions
lib/services/fantasy/fantasy-team.service.ts