Moo Twitter Backend¶
Moo is a Spring Boot backend for a Twitter-style social network. It provides versioned REST APIs for users, posts, follows, likes, replies, hashtags, search, and JWT authentication.
-
:material-rocket-launch: Run Moo
Install the prerequisites and start the API locally or with Docker.
-
:material-api: Integrate with the API
Learn the JWT and CSRF flow, endpoint contracts, and response models.
-
:material-sitemap: Understand the design
Follow requests through the application and inspect the persistence model.
-
:material-source-pull: Contribute
Find the focused workflow for issues, branches, tests, and pull requests.
At a glance¶
- Java 25 and Spring Boot 4.1
- Spring MVC, Spring Security, and Spring Data JPA
- MySQL in development and production; H2 for tests
- JWT access tokens with rotating refresh tokens
- CSRF double-submit protection for state-changing requests
- OpenAPI, Prometheus metrics, OpenTelemetry, JaCoCo, Sonar, and CodeQL
Request flow¶
flowchart LR
Client --> Security[Spring Security filters]
Security --> Controller
Controller --> Service
Service --> Repository
Repository --> Database[(MySQL / H2)]
The project keeps transport concerns in controllers, business rules in services, and persistence in repositories. API consumers receive model records, not JPA entities.
Documentation map¶
| Section | What you will find |
|---|---|
| Getting started | Installation, profiles, configuration, and local development |
| Architecture | Request flow, technology choices, security, and persistence |
| API | Authentication, endpoints, models, examples, and generated reference |
| Quality | Tests, coverage, formatting, analysis, and CI |
| Contributing | Contribution workflow, issues, and reviews |
| Project | Planning, releases, support, and community resources |