A full-stack notes app with user accounts, built with Python (Flask) + HTML/CSS/JS.
- β Register & login with username + password
- β Write notes directly in the browser
- β
Upload
.txtfiles as notes - β View, browse, and delete notes
- β Notes are stored per-user in a JSON file
- β Passwords hashed with SHA-256
- β
Keyboard shortcut:
Ctrl+Enterto save
pip install -r requirements.txtpython app.pyVisit: http://localhost:5000
notes_app/
βββ app.py # Flask backend (API + static serving)
βββ requirements.txt # Python dependencies
βββ data/
β βββ db.json # User accounts + notes (auto-created)
βββ static/
βββ index.html # Full frontend (HTML + CSS + JS)
| Method | Endpoint | Description |
|---|---|---|
| POST | /api/register | Create new account |
| POST | /api/login | Authenticate user |
| GET | /api/notes/:user | Get all notes |
| POST | /api/notes/:user | Save a new note |
| DELETE | /api/notes/:user/:id | Delete a note |
- Passwords are hashed before storage (SHA-256)
- Each API request requires the password hash as
X-Authheader - For production use, consider adding HTTPS, session tokens, and rate limiting