beautyhealthytips177/todo-phase3-hackathon2
0
Todo Backend API
FastAPI backend for the Todo application with PostgreSQL database.
Environment Variables
You need to configure these secrets in Hugging Face Spaces settings:
DATABASE_URL: PostgreSQL connection string (e.g., from Neon)JWT_SECRET: Secret key for JWT token generation (min 32 characters)CORS_ORIGINS: Comma-separated list of allowed frontend URLs (e.g., https://your-app.vercel.app)
API Endpoints
GET /api/health- Health checkPOST /api/auth/register- User registrationPOST /api/auth/login- User loginGET /api/tasks- Get all tasksPOST /api/tasks- Create new taskPATCH /api/tasks/{id}/complete- Mark task as completeDELETE /api/tasks/{id}- Delete task
