All projects

Real-time messaging

SwiftChat

One-to-one chat with real-time messages, image attachments, and emoji over WebSockets.

  • Spring Boot
  • Angular
  • PostgreSQL
  • Keycloak
  • STOMP
  • WebSockets
Project
Solo project
Contribution
Backend and Angular interface
Availability
Designed for local development. No public demo.

Overview

SwiftChat is a one-to-one messaging app. You sign in through Keycloak, pick a conversation from the sidebar, and messages arrive without a refresh. Images upload to the backend and are served back in the thread.

Architecture

Keycloak authenticates the browser, and the backend syncs the user on first login. The client keeps a STOMP subscription over SockJS for notifications and uses bearer-token REST for everything else. Messages live in PostgreSQL and attachments are written to local storage. The Angular services and models are generated from the API's OpenAPI document with ng-openapi-gen.

AngularChat interface
STOMP over WebSockets
Spring BootChat backend
PostgreSQLApplication data
KeycloakAuthentication

Designed for local development.

What it does

Per-user message delivery

Each signed-in user keeps a STOMP subscription open, so a message lands in the open thread and in the sidebar preview at once.

Presence and read state

The conversation list shows who is online and how many messages are unread. A message shows as sent, then seen, once the other person opens the thread.

Images and emoji

Attach an image to a message; the API stores the file and serves it back. The composer has an emoji picker.

Accounts through Keycloak

Keycloak owns the accounts and issues the tokens. The API creates its local user record on first login.

SwiftChat workspace with a conversation list and welcome screen.
Screenshot from the public SwiftChat repository.

Source code