m.moddie / dev
← All projects
Project / 01

Danskyi TMA

A Telegram service-booking platform with payments, scheduling, notifications and administration.

Python · Booking · Payments
Danskyi TMA

Catalog → Schedule → Booking → Payment → Fulfillment

FastAPI / PostgreSQL / ARQ / Next.js / Aiogram
Role

Fullstack / Backend Engineer

Period / format

11.2024 — 05.2025 (maintained through 2026)

Status

Commercial Project

My contribution

  • Engineered an online booking Telegram Mini App from scratch: REST API, PostgreSQL schema, administration panel, and client UI.
  • Implemented real-time booking slot validation with row-level locks in PostgreSQL, eliminating overbooking and race conditions.
  • Integrated payment gateways with webhook processing and asynchronous notifications via Aiogram bot and ARQ background workers.

Python, FastAPI, Dishka, PostgreSQL, Redis, ARQ, Aiogram 3, Next.js, TypeScript, Docker

01 / About the project

About the project

A Telegram service-booking platform with payments, scheduling, notifications and administration.

02 / Product surfaces

Customer flow and operations

The same Next.js application serves the Telegram booking journey and a role-protected desktop workspace for workers and administrators.

Telegram Mini App

3 Telegram captures · 1080 × 2400

Administration workspace

3 desktop screens · 1920 × 1080

The Mini App screens are original Telegram captures. The administration interface was captured from the real Next.js application with representative local mock data; FastAPI, PostgreSQL, Redis, payment providers and ARQ workers were not started.

03 / Case study

A production booking platform inside Telegram

Danskyi turns a service business into a controlled workflow: package selection, canonical slot allocation, payment, fulfillment, warranty and retention are owned by one modular backend.

Product scope

01

Telegram onboarding, locale, timezone and customer profile

02

Catalog of device-specific optimization packages

03

90-minute slot allocation over a canonical 16-slot UTC grid

04

Bookings, transfers, urgency and worker assignment

05

Provider checkout, crypto payment and promo revalidation

06

Reviews, warranties, reminders, retention and mailings

Engineering decisions

01

One product, two interfaces

Customer TMA and admin routes share a Next.js codebase, API client and localization layer. Role checks expose worker and superuser tools.

02

Booking invariants live on the backend

FastAPI modules own availability, contiguous slot duration, rescheduling and assignment. The UI displays backend truth.

03

Billing has an explicit boundary

Payments, methods and promo validation are isolated from booking orchestration. Warranty and setup payments remain distinguishable operations.

04

Background work is recoverable

ARQ jobs use Redis transport for reminders, retention campaigns and cleanup while PostgreSQL keeps durable business state.

05

Operations are part of delivery

Traefik, health probes, Prometheus, Grafana, Loki, Dozzle, CloudBeaver and backups are maintained with the application.

Repository structure

One monorepo with separate application, domain, transport and operations layers.

DANSKYI / MONOREPO
DANSKYI / TMA
apps/deployable application code
backend/src/core/config · PostgreSQL · Redis · security · Dishka · UoW
backend/src/modules/business capabilities with explicit ownership
users/ + catalog/Telegram identity · roles · service packages
bookings/ + schedules/booking lifecycle · canonical UTC slot engine · assignment
billing/ + promo_codes/payment methods · provider state · discounts
warranties/ + reviews/after-service guarantees · customer feedback
notifications/ + retention/ + mailings/reminders · campaigns · audience delivery
hardware/ + system/device evidence · runtime controls
backend/src/presentation/api/customer API · admin API · payment webhooks · health
backend/src/presentation/bot/Aiogram commands · onboarding · deep links
backend/src/worker/ARQ startup · scheduled jobs · retryable handlers
frontend/src/app/Next.js route groups for TMA and admin
(auth)/services · schedule · checkout · reviews · articles
(dashboard)/bookings · profile · promo codes · admin stats
(admin)/admin/dashboard · bookings · schedule · jobs · users · workers
frontend/src/components/shared cards · controls · modals · navigation
frontend/src/hooks/ + lib/Telegram bridge · API client · i18n · money · datetime
infra/runtime and operational delivery
docker/ + traefik/containers · same-origin routing · TLS
monitoring/Prometheus · Grafana · Loki · blackbox
backup/PostgreSQL backup and restore tooling
06 / System architecture

System architecture

Original project documentation in Russian

Open interactive diagram ↗