HouseHub
Capstone project to help households coordinate tasks, chores, finances, and schedules.

Repo currently contains only the **backend API (Spring Boot)**.  
Frontend (React) and infra Postgres/docker will be added later.(will most likely br postgres)

What tech stack is being used 
Tech Stack
- **Java 21 (JDK 21)**
- **Spring Boot 3**
  - Web (REST)
  - Data JPA (Postgres)
  - Security (currently wide open for dev)
- **Gradle 8**
- **PostgreSQL 16**
- **Lombok** (for getters/setters)

How to Run (Backend)
1. Ensure PostgreSQL is running and has: (I am going to try and make a shared database -brian) 
   - Database: `househub`
   - User: `househub`
   - Password: `househub`

Properties file
Configure `src/main/resources/application.properties`:
   server.port=8081
   spring.datasource.url=jdbc:postgresql://localhost:5432/househub
   spring.datasource.username=househub
   spring.datasource.password=househub
   spring.jpa.hibernate.ddl-auto=update
   spring.jpa.show-sql=true

If it is running correctly when you use postman to 
GET http://localhost:8081/api/health
You should get -→ { "status": "ok", "service": "househub-api" }








Project Structure currently 
src/main/java/com/househub/househub_api/
├─ config/
│  └─ SecurityConfig.java         # Dev-only security (all requests permitted)
│
├─ health/
│  └─ HealthController.java       # GET /api/health
│
└─ household/
   ├─ Household.java              # JPA entity
   ├─ HouseholdDto.java           # Data Transfer Object (API payload)
   ├─ HouseholdRepository.java    # Spring Data JPA repository
   ├─ HouseholdService.java       # Business logic
   └─ HouseholdController.java    # REST endpoints (GET/POST /api/households)

HousehubApiApplication.java       # Spring Boot main class


The endpoints that are done so far
	Health will return the service status 
		Get http://localhost:8081/api/health
	HouseHolds 	
		Get http://localhost:8081/api/households
			Will return all households 
		Post http://localhost:8081/api/households
			Creates a new household, has to be written in a JSON file 

Next Steps 
Households
Add GET by ID, PUT/PATCH (update), DELETE endpoints.
Add validation (@NotBlank name) and error handling (409 on duplicate names).


Users & Auth
Replace dev-open SecurityConfig with JWT-based login/registration.
Add HouseholdMember entity to connect users ↔ households.


Chores, Bills, Calendar
Define entities + endpoints.


Infra
Postgres + pgAdmin.










