Social challenges platform built with ASP.NET Core. Users create challenges for followers/friends; participants join and submit proofs to complete them.
- Create, browse, and search public or invite-only challenges
- Join challenges, submit proofs (text/image/link), comment, react
- Follows, feeds, and notifications (optional real-time via SignalR)
- User profiles, privacy controls, and reporting
- Moderation: flagging and basic abuse prevention hooks
- JWT authentication with ASP.NET Core Identity
- EF Core data access and migrations
- .NET 8, ASP.NET Core Web API (or MVC)
- EF Core (SQL Server or SQLite)
- ASP.NET Core Identity + JWT
- SignalR (optional) for real-time updates
- Serilog (optional) for logging
Prerequisites:
- .NET SDK 8.0+
- SQL Server (LocalDB) or SQLite
- Node.js only if a separate SPA client is added
- Clone and enter the project
- cd src/challenger
- Configure appsettings.Development.json
{
"ConnectionStrings": {
"DefaultConnection": "Server=(localdb)\\MSSQLLocalDB;Database=ChallengerDb;Trusted_Connection=True;MultipleActiveResultSets=true"
// Or: "DefaultConnection": "Data Source=challenger.db"
},
"Jwt": {
"Issuer": "Challenger",
"Audience": "Challenger",
"Key": "dev-only-change-this-super-secret-key"
},
"Storage": {
"Provider": "Local",
"LocalPath": "wwwroot/uploads"
},
"Logging": {
"LogLevel": { "Default": "Information" }
}
}- Restore, migrate, run
dotnet restore
dotnet tool install -g dotnet-ef # if not installed
dotnet ef database update
dotnet runDefault URLs:
- Add migration: dotnet ef migrations add InitialCreate
- Update DB: dotnet ef database update
- Run tests: dotnet test
- Auth
- POST /api/auth/register
- POST /api/auth/login
- Profiles
- GET /api/users/{id}
- GET /api/users/me
- Challenges
- GET /api/challenges
- POST /api/challenges
- GET /api/challenges/{id}
- POST /api/challenges/{id}/join
- Submissions
- POST /api/challenges/{id}/submissions
- GET /api/challenges/{id}/submissions
- POST /api/submissions/{id}/reactions
- POST /api/submissions/{id}/comments
- Follows
- POST /api/users/{id}/follow
- DELETE /api/users/{id}/follow
- Notifications
- GET /api/notifications
- GET /hubs/notifications (SignalR)
OpenAPI/Swagger is available at /swagger when running in Development.
- User: Identity user profile
- Challenge: Title, description, rules, visibility, ownerId, start/end
- Membership: User joined a challenge
- Submission: User’s proof for a challenge
- Reaction: Like/upvote on a submission
- Comment: Threaded discussion on submissions
- Follow: User-to-user follow relationship
- Notification: Event delivery to users
- Report: Abuse report entity
- Program.cs, appsettings*.json
- Controllers/ or Minimal API endpoints
- Domain/Entities, Domain/Events
- Application/Services, DTOs
- Infrastructure/Persistence (EF Core), Identity, Storage
- Web/Filters, Middleware, Hubs
- Tests/
- Set ASPNETCORE_ENVIRONMENT=Development for local runs
- For SQLite: update DefaultConnection and add UseSqlite in DbContext configuration
- For image uploads, ensure writable Storage.LocalPath or configure a cloud provider
- Store a strong Jwt:Key in production secrets
- Enforce max upload sizes and file type checks
- Rate-limit auth and write endpoints
- Implement moderation workflows for reports
- Challenge templates and recurring schedules
- Team challenges and co-hosts
- Rich media processing and CDN integration
- Advanced leaderboards and scoring rules
- Mobile push notifications
- Open issues for bugs/features
- Use feature branches and small PRs
- Include tests for new behavior