An API to manage your study sessions, topics and subjects to strategically plan your study times.
Node.js >= 20 20
git clone https://github.com/ItzShubhamDev/study-planner-api
cd study-planner-api
npm installlnpm run devnpm run build
npm run starttSECRET - Required for encrypting data on the database.
PORT - The port to run the server on.
DB - The location to store database.
| Method | Endpoint | Summary |
|---|---|---|
| POST | /auth/register |
Registers a new user |
| POST | /auth/login |
Login an existing user |
| Method | Endpoint | Summary |
|---|---|---|
| GET | /docs |
Swagger Docs |
| GET | /auth/user |
Get current user info |
| GET | /subjects |
Get all subjects of the user |
| POST | /subjects |
Create a new subject |
| GET | /subjects/{id} |
Get subject details with topics & sessionsions |
| PUT | /subjects/{id} |
Update a subject |
| DELETE | /subjects/{id} |
Delete a subject |
| GET | /subjects/{subjectId}/topics |
Get topics of a subject |
| POST | /subjects/{subjectId}/topics |
Create a new topic |
| GET | /topics/{topicId} |
Get topic details with sessions |
| PUT | /topics/{topicId} |
Update a topic (name, status) |
| DELETE | /topics/{topicId} |
Delete a topic |
| GET | /topics/{topicId}/sessions |
Get sessions for a topic |
| POST | /topics/{topicId}/sessions |
Add a new session to a topic |