A RESTful API application for managing real estate properties, estate agents, customers, and property transactions.
- Java 21
- Spring Boot 3.5.9
- PostgreSQL - Database
- Spring Security - Authentication & Authorization
- JWT - Token-based authentication
- Spring Data JPA - Data persistence
- HATEOAS - Hypermedia-driven API
- MapStruct - Object mapping
- Flyway - Database migrations
- OpenAPI/Swagger - API documentation
- Lombok - Boilerplate code reduction
Once the application is running, access the Swagger UI at:
- Swagger UI:
http://localhost:8080/swagger-ui/index.html - OpenAPI JSON:
http://localhost:8080/v3/api-docs
POST /api/auth/register- Register a new userPOST /api/auth/login- User loginPOST /api/auth/refresh- Refresh access token
GET /api/properties- List all properties (requires USER role)GET /api/properties/{id}- Get property by ID (requires USER role)POST /api/properties- Create new property (requires AGENT role)PUT /api/properties/{id}- Update property (requires AGENT role)DELETE /api/properties/{id}- Delete property (requires AGENT role)
GET /api/agent- List all estate agentsGET /api/agent/{id}- Get estate agent by IDGET /api/agent/{id}/properties- Get properties by estate agent
POST /api/customer/buy- Purchase a property
GET /api/currency/rate?startDate={date}&endDate={date}- Get currency rates
src/main/java/com/deveyk/estateagent/
├── auth/ # Authentication and security
├── property/ # Property management
├── agent/ # Estate agent management
├── customer/ # Customer operations
├── currency/ # Currency service
└── common/ # Shared utilities and models