Lucas

Project — auth-api

A Spring Boot Authentication API with JWT and Refresh Tokens

Sign-up, login, logout and session refresh, built in three days.

Image 1
Image 2
Image 3
Image 4
Image 5
Image 6
Image 7
Image 8
Image 9
Image 10
Image 11
Image 12
Image 13
Image 14
1 / 14
01

In plain English

Almost every website needs a safe way to sign up, log in and log out. This project is exactly that building block: an API that creates accounts, checks who you are and keeps your session alive without asking for your password every few minutes, while keeping out anyone who shouldn't get in.

02

For the curious

Built with Spring Boot, Spring Security and PostgreSQL. Users receive a short-lived JWT access token and a refresh token to renew it, and tokens are blacklisted on logout so they can't be reused. The code follows the usual layers (models, DTOs with request validation, repositories, services, controllers) with a dedicated security configuration. Unit tests cover the core features, Docker Compose sets up the environment, and a CI/CD pipeline builds and deploys it automatically.

A little summary :

I built it in three days to really understand token-based authentication with Spring Security. It's now a building block I can reuse in any backend that needs proper user management.