How hausenlot/socmed-backend works
This is a social-media backend for accounts, posts (“rants”), threaded replies, timelines, follows, notifications, and direct or group messaging. The principal flow is a user request through an API controller into a domain service, which reads or changes application data and returns a response; posts and replies can also trigger notifications. The graph preserves the documented-by-code media and real-time messaging capabilities. Several service implementations were not excerpted, so their internal calls and timeline behavior are not asserted.
Main entry points: Program.cs Application host · AppDbContext.cs Data access · NotificationService.cs Notifications · MessageService.cs Direct messaging
Components 29
HTTP API
- Authentication API
socmed-backend/Controllers/AuthController.cs - Rants API
socmed-backend/Controllers/RantsController.cs - Replies API
socmed-backend/Controllers/RepliesController.cs - Timelines API
socmed-backend/Controllers/TimelinesController.cs - Users API
socmed-backend/Controllers/UsersController.cs - Messages API
socmed-backend/Controllers/MessagesController.cs - Notifications API
socmed-backend/Controllers/NotificationsController.cs
Social features
- Authentication
socmed-backend/Services/AuthService.cs - Rant posts
socmed-backend/Services/RantService.cs - Threaded replies
socmed-backend/Services/ReplyService.cs - Timeline queries
socmed-backend/Services/TimelineService.cs - Follow relationships
socmed-backend/Services/FollowService.cs - User profiles
socmed-backend/Services/UserService.cs
Messaging and alerts
- Direct messaging
socmed-backend/Services/MessageService.cs - Notifications
socmed-backend/Services/NotificationService.cs - Notification hub
socmed-backend/Hubs/NotificationHub.cs - Message encryption
socmed-backend/Services/EncryptionService.cs
Runtime and integrations
- Application host
socmed-backend/Program.cs - Multimedia handling
socmed-backend/Services/MultimediaService.cs - File manager
Domain data
- Data access
socmed-backend/Data/AppDbContext.cs - Account model
socmed-backend/Models/User.cs - Rant model
socmed-backend/Models/Rant.cs - Reply model
socmed-backend/Models/RantReply.cs - Message model
socmed-backend/Models/Message.cs - Conversation model
socmed-backend/Models/Conversation.cs - Notification model
socmed-backend/Models/Notification.cs - Follow model
socmed-backend/Models/Follow.cs
Other components
- User
Connections 45
- User → Application host: sends requests
- Application host → Authentication API: maps controllers
socmed-backend/Program.cs - Application host → Rants API: maps controllers
socmed-backend/Program.cs - Application host → Replies API: maps controllers
socmed-backend/Program.cs - Application host → Timelines API: maps controllers
socmed-backend/Program.cs - Application host → Users API: maps controllers
socmed-backend/Program.cs - Application host → Messages API: maps controllers
socmed-backend/Program.cs - Application host → Notifications API: maps controllers
socmed-backend/Program.cs - Authentication API → Authentication: delegates to
socmed-backend/Controllers/AuthController.cs - Rants API → Rant posts: delegates to
socmed-backend/Controllers/RantsController.cs - Rants API → Threaded replies: delegates to
socmed-backend/Controllers/RantsController.cs - Replies API → Threaded replies: delegates to
socmed-backend/Controllers/RepliesController.cs - Timelines API → Timeline queries: delegates to
socmed-backend/Controllers/TimelinesController.cs - Users API → User profiles: delegates to
socmed-backend/Controllers/UsersController.cs - Users API → Follow relationships: delegates to
socmed-backend/Controllers/UsersController.cs - Messages API → Direct messaging: delegates to
socmed-backend/Controllers/MessagesController.cs - Notifications API → Notifications: delegates to
socmed-backend/Controllers/NotificationsController.cs - Application host → Data access: configures database
socmed-backend/Program.cs - Application host → Notification hub: maps hub
socmed-backend/Program.cs - Application host → Multimedia handling: registers service
socmed-backend/Program.cs - Application host → Direct messaging: registers service
socmed-backend/Program.cs - Application host → Notifications: registers service
socmed-backend/Program.cs - Application host → Rant posts: registers service
socmed-backend/Program.cs - Authentication → Data access: reads and writes
socmed-backend/Services/AuthService.cs - Authentication → Multimedia handling: gets media URL
socmed-backend/Services/AuthService.cs - Rant posts → Data access: queries and saves
socmed-backend/Services/RantService.cs - Rant posts → Notifications: processes mentions
socmed-backend/Services/RantService.cs - Threaded replies → Data access: queries and saves
socmed-backend/Services/ReplyService.cs - Threaded replies → Notifications: creates alerts
socmed-backend/Services/ReplyService.cs - Threaded replies → Multimedia handling: gets media URL
socmed-backend/Services/ReplyService.cs - Direct messaging → Data access: uses data context
socmed-backend/Services/MessageService.cs - Direct messaging → Message encryption: uses encryption
socmed-backend/Services/MessageService.cs - Direct messaging → Notification hub: uses notification hub
socmed-backend/Services/MessageService.cs - Direct messaging → Multimedia handling: uses media service
socmed-backend/Services/MessageService.cs - Notifications → Data access: uses data context
socmed-backend/Services/NotificationService.cs - Notifications → Notification hub: uses notification hub
socmed-backend/Services/NotificationService.cs - Notifications → Multimedia handling: uses media service
socmed-backend/Services/NotificationService.cs - Multimedia handling → File manager: forwards uploads
- Data access → Account model: maps entity
socmed-backend/Data/AppDbContext.cs - Data access → Rant model: maps entity
socmed-backend/Data/AppDbContext.cs - Data access → Reply model: maps entity
socmed-backend/Data/AppDbContext.cs - Data access → Message model: maps entity
socmed-backend/Data/AppDbContext.cs - Data access → Conversation model: maps entity
socmed-backend/Data/AppDbContext.cs - Data access → Notification model: maps entity
socmed-backend/Data/AppDbContext.cs - Data access → Follow model: maps entity
socmed-backend/Data/AppDbContext.cs