You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+94-5Lines changed: 94 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ A **modern, scalable, and production-ready REST API** for a Markdown-based blogg
4
4
5
5
This project demonstrates **real-world backend engineering practices** including authentication, authorization, modular architecture, cursor pagination, security hardening, and clean API design — built with **TypeScript, Express 5, PostgreSQL, Drizzle ORM, and Zod**.
6
6
7
-
> ⚡ Designed as a portfolio-grade backend to showcase job-ready backend skills.
7
+
> ⚡ This backend is intentionally over-engineered for a portfolio project to demonstrate real-world backend engineering decisions.
8
8
9
9
---
10
10
@@ -27,15 +27,18 @@ If you’re reviewing this repo:
27
27
28
28
## 🚀 Features
29
29
30
-
### 🔐 Authentication & Security
30
+
### 🔐 Authentication & Account Lifecycle
31
31
32
32
- JWT **access tokens** (short-lived)
33
33
-**Refresh tokens** via HTTP-only cookies
34
-
- Secure logout & token rotation
34
+
- Secure logout & refresh token rotation
35
+
- Refresh tokens are **hashed before storage**
36
+
- Token reuse detection & family revocation
35
37
- Role-based access control (**USER / AUTHOR / ADMIN**)
36
-
- Rate limiting on sensitive routes
38
+
- Email verification with expiring, one-time tokens
39
+
- Rate limiting on authentication & write endpoints
37
40
- Security headers via **Helmet**
38
-
-Proper CORS for multiple frontends
41
+
-Strict CORS allowlist (no wildcard origins with credentials)
39
42
40
43
### ✍️ Blogging System
41
44
@@ -95,6 +98,63 @@ If you’re reviewing this repo:
95
98
96
99
---
97
100
101
+
## 👤 Users & Admin Management
102
+
103
+
The API includes a complete user management system designed for real-world applications.
104
+
105
+
### User Capabilities
106
+
107
+
- View authenticated user profile
108
+
- Update own profile (username, bio)
109
+
- Upload profile picture via signed uploads
110
+
- Email verification workflow
111
+
112
+
### Admin Capabilities
113
+
114
+
- List all users with cursor-based pagination
115
+
- Filter users by role and active status
116
+
- Update user roles and activation state
117
+
- Moderate platform access without hard deletes
118
+
119
+
User operations follow strict **role-based authorization policies** and avoid destructive actions to preserve data integrity.
0 commit comments