Admin (apps/admin)
Admin dashboard for the Booking Platform, built with SolidJS and TanStack Start. Provides platform operations, compliance, financial management, and feature flag controls.
Overview
The admin workspace is a separate application from the website, dedicated to platform administration. It features a command palette (Cmd+K), unified sidebar navigation with 7 route groups, and a shared data table system with pagination, search, filters, and date range pickers.
Tech Stack
| Layer | Technology | Version |
|---|---|---|
| Framework | SolidJS | ^1.9.14 |
| Meta Framework | TanStack Start | ^1.168.32 |
| Router | TanStack Solid Router | ^1.170.18 |
| Data Fetching | TanStack Solid Query | ^5.101.4 |
| Forms | TanStack Solid Form | ^1.33.2 |
| State | TanStack Solid Store | ^0.11.0 |
| Tables | TanStack Solid Table | ^8.21.3 |
| API Layer | oRPC | ^1.14.12 |
| Validation | Zod | ^4.4.3 |
| Database | Drizzle ORM | ^0.45.2 |
| Auth | Supabase + jose JWT | ^2.111.0 / ^6.2.4 |
| Payments | Stripe | ^22.5.0 |
| Styling | UnoCSS | ^66.7.5 |
| Cache | Redis (ioredis) | ^5.11.1 |
| Testing | Vitest + Playwright | ^4.1.10 / ^1.62.0 |
| Linting | Biome | ^2.5.6 |
| Build | Vite | ^8.2.1 |
Route Groups
| Group | Description |
|---|---|
(operations) | Overview, health, reports, settings, users |
(bookings) | Bookings, abandoned bookings, disputes |
(financial) | Payments, subscriptions, payouts, financial ledger |
(compliance) | Audit log, compliance, privacy, security, tax |
(marketing) | Audience, communications, notifications, promotions, referrals, reviews, search, seller leads, short URLs |
(platform) | Certifications, domains, feature flags, integrations, partners, providers |
api/ | Health check, metrics, oRPC RPC handler, REST handler, OpenAPI spec |
Key Features
| Feature | Description |
|---|---|
| Command Palette | Cmd+K palette with keyboard navigation and global shortcuts |
| Unified Layout | Sidebar navigation with root navbar and route groups |
| Admin Data Tables | Pagination, search, filters, date range pickers via AdminDataTableShell |
| Feature Flags | Feature flag management with table and create form |
| Webhook Lab | Event monitoring, dead letter queue, replay |
| Privacy Management | Consent, data export, data minimization, data retention (GDPR/CCPA) |
| Provider Verifications | Verifications and certifications management |
| Platform Health | System health monitoring and status dashboards |
| Scheduled Reports | Automated report scheduling and delivery |
| Financial Ledger | Payment management, payouts, subscriptions, ledger |
Key Scripts
bash
# Development
moon run apps-admin:dev
# Build
moon run apps-admin:build
# Preview
moon run apps-admin:preview
# Database
moon run apps-admin:db-generate # Generate migration
moon run apps-admin:db-migrate # Run migrations
moon run apps-admin:db-push # Push schema (dev only)
moon run apps-admin:db-studio # Open Drizzle Studio
# Testing
moon run apps-admin:test # Unit tests
moon run apps-admin:test-e2e # Playwright E2E
# Quality
moon run apps-admin:lint
moon run apps-admin:typecheck
moon run apps-admin:verifyArchitecture
apps/admin/
├── app/
│ ├── client.tsx # Client entry with devtools
│ ├── server.ts # Server entry with Redis, DB, auth
│ ├── router.tsx # TanStack Router configuration
│ ├── routes/
│ │ ├── __root.tsx
│ │ ├── (bookings)/ # Booking management
│ │ ├── (compliance)/ # Compliance and security
│ │ ├── (financial)/ # Payments and subscriptions
│ │ ├── (marketing)/ # Marketing and communications
│ │ ├── (operations)/ # Operations and settings
│ │ ├── (platform)/ # Platform management
│ │ └── api/ # API routes (health, metrics, rpc, rest)
│ ├── modules/
│ │ ├── config-admin/ # Admin configuration
│ │ └── settings/ # Admin settings
│ ├── server/ # oRPC server handlers (30+ handler groups)
│ ├── lib/ # Shared libraries
│ ├── presentation/ # UI components
│ └── shared/ # Shared utilities
├── scripts/
│ └── check-bundle-size.ts
├── package.json
├── moon.yml
├── tsconfig.json
└── wrangler.jsonc # Cloudflare deployment configServer Handlers
The admin app has 30+ oRPC server handler groups under app/server/:
| Handler Group | Description |
|---|---|
| booking | Booking operations |
| communications | Email, SMS, and notification dispatch |
| compliance | Compliance and audit operations |
| currency | Currency conversion |
| export | Data export operations |
| feature-flags | Feature flag management |
| finance | Financial operations |
| i18n | Internationalization |
| loyalty | Loyalty program operations |
| membership | Membership management |
| notifications | Notification management |
| offline | Offline sync support |
| overview | Dashboard overview data |
| partner | Partner operations |
| payment | Payment processing |
| privacy | Privacy and data management |
| provider | Provider operations |
| reports | Report generation |
| route-guard | Route-level permission checks |
| search | Search operations |
| security | Security operations |
| services | Service management |
| support | Support ticket operations |
| tax | Tax calculation |
| user | User management |
| webhooks | Webhook event management |
Environment Variables
The admin workspace uses Infisical for secrets management. See apps/admin/.env.example for all required variables.