Admin Dashboard — Service Overview
Status: populated Owner: Platform Engineering (Frontend) Last updated: 2026-04-18 Companion: DOMAIN_MODEL · API_CONTRACTS · SYNC_CONTRACT · SECURITY_MODEL
1. Purpose
admin-dashboard is the internal web application for Ghasi-SMS-Gateway platform administrators. It provides real-time operational visibility, SMPP operator CRUD, routing rule management, cross-tenant message log inspection, billing oversight, user management, and system health monitoring.
The dashboard is a stateless Next.js 14+ frontend deployed as a Docker container. All data lives in backend services accessed via Kong admin routes. Direct database access is strictly prohibited from this service.
2. Bounded Context
Platform Operations — internal tooling for Ghasi staff. Not accessible to customers. Operates with elevated permissions via the admin Firebase custom claim.
3. Responsibilities
| Area | What admin-dashboard owns |
|---|---|
| Real-time dashboard | 30s-polled metric summary; throughput chart (24h hourly); delivery breakdown pie chart; top-5 operators table; alert banners |
| Operator management | Full CRUD for SMPP operators via operator-management-service |
| Routing rules | View and manage routing rule configuration |
| Message logs | Cross-tenant, searchable, filterable message log inspection |
| Billing oversight | Platform-wide pricing configuration; per-tenant invoice review |
| User management | List, create, suspend, delete platform users and tenant accounts |
| System health | Service health indicators for all platform microservices |
| Settings | Platform configuration (rate limits, feature flags, notification templates) |
4. Non-Responsibilities
| Area | Owner |
|---|---|
| Customer-facing self-service | customer-portal |
| JWT issuance + JWKS | auth-service |
| SMS routing execution | routing-engine |
| SMPP connection management | smpp-connector |
| Billing calculation | billing-service |
5. Key Flows
Login
- Admin navigates to
/login. - Firebase Auth signs in; returns Firebase ID token.
- Portal calls
GET /v1/internal/auth/methrough Kong admin routes to verifyadmincustom claim. - Platform JWT stored in
httpOnly; Secure; SameSite=Strictencrypted cookie. - Middleware enforces
adminclaim on all protected routes.
Real-Time Dashboard (/dashboard)
- Page renders initial data server-side (first load fast).
- Client-side polling every 30 seconds calls
/api/metricsBFF endpoint. - Throughput chart updated in-place with recharts/chart.js.
- Delivery breakdown pie chart updated.
- Top-5 operators table refreshed.
- Alert banners appear if any service health check returns non-green.
Operator CRUD
- Admin navigates to
/operators. - Server component lists all SMPP operators via operator-management-service.
- Create/Edit modal collects operator config (host, port, credentials, throughput limits).
- DELETE with confirmation dialog.
6. Dependencies
| Dependency | Purpose |
|---|---|
| Firebase Auth (client SDK) | Admin sign-in |
| Kong Admin Routes | Edge authentication + routing to backend services |
| auth-service | admin claim verification; user management |
| analytics-service | Summary, throughput, delivery-breakdown metrics |
| operator-management-service | SMPP operator CRUD |
| routing-engine | Routing rule read/write |
| billing-service | Per-tenant billing data, pricing configuration |
| notification-service | Platform notification template management |
7. Access Control
This application is restricted to staff with the Firebase admin custom claim. It is not publicly accessible — deployed at an internal subdomain (admin.internal.ghasi.io) protected by Cloudflare Access (identity-aware proxy) as an additional authentication layer.
8. Status
Active development — dashboard and operator management targeted for internal alpha.