Greenfield rebuild (draft)
Status: under review on /next. v1 winners stay live until a row is promoted.
Rebuild pack from the Convex monorepo → Marketplace · MelonQ · Middleware · Core. Use live explorers + sibling repos, not Convex, as “what exists today.”
Keep from v1
- Amenity ticks are a local slug catalog — v1 tick list. APIs store which slugs a property has (
amenity_{slug}). Do not fetch the picker list from Core. - Middleware wins over Core. IDOR on Core path-settings + Middleware only.
- Core stays generic entities. No Resend, PSP, or GuestTraction in Laravel.
Proposed surfaces
| Surface | Host (draft) | v1 today |
|---|---|---|
| Marketplace | bookdirect.ng | same app |
| Booking Engine | {HotelName}.com-bookdirect.com | path slug on Marketplace (Direct Booking) |
| Partner platform | platform.melonq.com | /extranet |
| Partner onboarding | onboarding.bookdirect.melonq.com | /extranet/onboarding |
| Partner auth | melonq.com/signin | Core login in the same Next app |
Playbooks in this draft
| Guide | Decision vs v1 |
|---|---|
| Email (Resend) + template matrix | Promote live POST .../emails/send. Matrix of keys + CTAs — no full TSX dump |
| Booking ID format | 6-digit lodging ref; seed 010000 only if live max < 10000 |
| API-based content | Galleries/CMS via API. Amenities = local slugs |
| Placeholder photos | Four API slots |
| Google Maps | Fetch once, store, serve from property API |
| ARI SSOT | Proposed inventory rows. Live winner stays availability/check |
| MelonQ separation | Partner hosts. v1 /extranet until redirects |
| Booking Engine | Subdomain-only. Path links become 301s |
| AI Rate Match | New Middleware + worker. After rates + ARI |
| Migration | Cutover order. Rooms stay a rooms folder (live) |
Path remount (draft winner)
Sibling config/routes.json and the live explorer already mount lodging folders at /api/v1/bookdirect/* (properties, rooms, rates-packages, bookings, reservations, emails). File-manager stays /api/v1/nellalink/file-manager.
v1 playbooks still document /api/v1/nellalink/properties. Promote remount in one iterate — do not mix it into MelonQ or ARI.