How naumsantos/voleiapp works
VoleiApp is an ASP.NET Core backend for managing recreational volleyball: users manage athletes and teams, draw balanced teams, create and track matches, record results and substitutions, and request AI match insights. The main flow is HTTP controllers into application services, which use domain repository contracts and infrastructure persistence; match results also invoke substitution logic. AI insights use configurable providers with a documented local fallback. The graph preserves these product areas and the core match, domain, and persistence layers. Some controller/service wiring and provider selection are represented only by the source index or README.
Main entry points: PartidaService.cs Match lifecycle · ResilienteAiInsightsService.cs AI provider routing · SorteioService.cs Team draw · AtletaRepository.cs Athlete repository
Components 26
HTTP API
- Athlete endpoints
src/VoleiApp.API/Controllers/AtletasController.cs - Team endpoints
src/VoleiApp.API/Controllers/TimeController.cs - Draw endpoint
src/VoleiApp.API/Controllers/SorteioController.cs - Match endpoints
src/VoleiApp.API/Controllers/PartidasController.cs - Substitution endpoints
src/VoleiApp.API/Controllers/SubstituicoesController.cs - Insight endpoint
src/VoleiApp.API/Controllers/InsightsController.cs
Application workflows
- Athlete management
src/VoleiApp.Application/Services/AtletaService.cs - Team management
src/VoleiApp.Application/Services/TimeService.cs - Team draw
src/VoleiApp.Application/Services/SorteioService.cs - Match lifecycle
src/VoleiApp.Application/Services/PartidaService.cs - Match DTOs
src/VoleiApp.Application/DTOs/Partida - Insight DTOs
src/VoleiApp.Application/DTOs/Insights
Domain model
- Athlete
src/VoleiApp.Domain/Entities/Atleta.cs - Team roster
src/VoleiApp.Domain/Entities/Time.cs - Match and reserves
src/VoleiApp.Domain/Entities/Partida.cs - Substitutions
src/VoleiApp.Domain/Entities/Substituicao.cs
Persistence
- Athlete repository
src/VoleiApp.Infrastructure/Repositories/AtletaRepository.cs - Team repository
src/VoleiApp.Infrastructure/Repositories/TimeRepository.cs - Match repository
src/VoleiApp.Infrastructure/Repositories/PartidaRepository.cs - SQLite data context
src/VoleiApp.Infrastructure/Persistence/VoleiContext.cs
AI insights
- AI provider routing
src/VoleiApp.Infrastructure/AI/ResilienteAiInsightsService.cs - Ollama provider
src/VoleiApp.Infrastructure/AI/OllamaAiInsightsService.cs - OpenAI-compatible provider
src/VoleiApp.Infrastructure/AI/OpenAiInsightsService.cs - Local fallback
src/VoleiApp.Infrastructure/AI/FallbackInsightsService.cs
Other components
- API user
- Configured AI service
Connections 29
- API user → Athlete endpoints: manages athletes
README.md - API user → Team endpoints: manages teams
README.md - API user → Draw endpoint: requests draw
README.md - API user → Match endpoints: tracks matches
README.md - API user → Substitution endpoints: queries substitutions
README.md - API user → Insight endpoint: requests insights
README.md - Athlete endpoints → Athlete management: delegates
src/VoleiApp.API/Controllers/AtletasController.cs - Team endpoints → Team management: delegates
src/VoleiApp.API/Controllers/TimeController.cs - Draw endpoint → Team draw: delegates
- Match endpoints → Match lifecycle: delegates
src/VoleiApp.API/Controllers/PartidasController.cs - Substitution endpoints → Match lifecycle: delegates
src/VoleiApp.API/Controllers/SubstituicoesController.cs - Insight endpoint → Match lifecycle: loads match
src/VoleiApp.API/Controllers/InsightsController.cs - Insight endpoint → AI provider routing: requests insight
src/VoleiApp.API/Controllers/InsightsController.cs - Athlete management → Athlete repository: uses repository
src/VoleiApp.Application/Services/AtletaService.cs - Team management → Team repository: uses repository
src/VoleiApp.Application/Services/TimeService.cs - Team draw → Athlete repository: loads athletes
src/VoleiApp.Application/Services/SorteioService.cs - Team draw → Team repository: persists drawn teams
src/VoleiApp.Application/Services/SorteioService.cs - Match lifecycle → Match repository: reads and writes
src/VoleiApp.Application/Services/PartidaService.cs - Match lifecycle → Athlete repository: loads athletes
src/VoleiApp.Application/Services/PartidaService.cs - Match lifecycle → Team draw: requests substitutions
src/VoleiApp.Application/Services/PartidaService.cs - Match lifecycle → Match DTOs: maps responses
src/VoleiApp.Application/Services/PartidaService.cs - Athlete repository → SQLite data context: queries and saves
src/VoleiApp.Infrastructure/Repositories/AtletaRepository.cs - Team repository → SQLite data context: queries and saves
src/VoleiApp.Infrastructure/Repositories/TimeRepository.cs - Match repository → SQLite data context: queries and saves
src/VoleiApp.Infrastructure/Repositories/PartidaRepository.cs - AI provider routing → Ollama provider: routes requests
src/VoleiApp.Infrastructure/AI/ResilienteAiInsightsService.cs - AI provider routing → OpenAI-compatible provider: routes requests
- AI provider routing → Local fallback: falls back
src/VoleiApp.Infrastructure/AI/ResilienteAiInsightsService.cs - Ollama provider → Configured AI service: sends prompt
src/VoleiApp.Infrastructure/AI/OllamaAiInsightsService.cs - OpenAI-compatible provider → Configured AI service: sends prompt