Turn tasks into actionable plans with real next steps—not just another checklist.
AI Todo List is a single Next.js app (App Router) with:
- UI routes (
/,/sign-in,/sign-up) - Same-origin API routes (
/api/**) - MongoDB persistence
- JWT auth (including guest sessions + guest upgrade)
- AI task guidance with structured response payloads
- Framework: Next.js (App Router + Route Handlers)
- UI: React
- API/Auth: Next.js route handlers + JWT
- Database: MongoDB Atlas
- AI: OpenAI API
The UI expects structured guidance JSON:
{
"message": "Start by researching beginner bodyweight routines...",
"links": [
{
"linkTitle": "Beginner bodyweight guide",
"url": "https://example.com/workout-guide",
"description": "A practical intro plan"
}
],
"googleSearch": "beginner bodyweight workout plan at home",
"steps": ["Pick a 3-day split", "Track your first week"]
}git clone https://github.com/dansbands/ai-todo-list.git
cd ai-todo-list
npm install
npm run devOpen: http://localhost:3000
Create .env.local (or .env) with:
DB_USERNAME=your_mongodb_username
DB_PASSWORD=your_mongodb_password
JWT_PRIVATE_KEY=your_jwt_secret
OPENAI_API_KEY=your_openai_api_keyDB_USERNAME/DB_PASSWORDare used to build the MongoDB Atlas connection string.JWT_PRIVATE_KEYis required for signin/signup/guest tokens.OPENAI_API_KEYis required for/api/chatAI guidance.REACT_APP_SERVER_URL,REACT_APP_PROD_SERVER_URL, andCORS_ALLOWED_ORIGINSare no longer used in this unified Next.js architecture.
npm run dev– start Next.js dev servernpm run build– production buildnpm run start– run built appnpm test– existing component/util tests
MIT