The Ultimate Journey
Pre-Launch Gate Check

handleSeatOpened — Boarding Pass Send

Final Gate Check Tutorial

Walk through all 4 steps to confirm seat_id and tuj_code are correctly threaded through the boarding pass email and CTA links before flipping the gate.

Step 1

Open Base44 Admin

Navigate to app.base44.com and open the Functions panel.
Locate handleSeatOpened and navigate to fan-out step 4 — boarding pass send.
This is where sendBoardingPass/entry.ts is invoked with tuj_code threaded through the payload.
// handleSeatOpened → step 4 fan-out
await sendBoardingPass({
  userId,
  email,
  full_name,
  seat_id,      // e.g. "TUJ-NM0000"
  tuj_code,     // separate param — must be non-empty
});
Step 2

Trigger with Nicole's VIP Passenger Record

Open the Passenger entity in Base44 and find Nicole's row.
Confirm tuj_code is populated on her record — e.g. TUJ-NM0000. If missing, add it now.
In the Admin test runner, call handleSeatOpened with both params:
{
  "seat_id": "<Nicole's seat_id>",
  "tuj_code": "TUJ-NM0000",
  "boarding_type": "standard",
  "force_resend": true
}
⚠ Important: tuj_code must be passed as its own top-level param — not nested inside another object.
Step 3

Confirm the Test Send to test-recipient@example.com

Open test-recipient@example.com and find the boarding pass email just triggered.
For each CTA link (hover or right-click → Copy link), verify the params below. Check each item off as you confirm it.
Email Checklist

Expected passport_url shape

https://app.tuj.us/OnboardingPassport
  ?seat_id=TUJ-NM0000
  &tuj_code=TUJ-NM0000
Step 4

Network Tab Confirm

Click one of the CTA links from the email to open it in the browser.
Open DevTools → Network tab (or inspect the URL bar directly).
In the browser console, run the following to confirm both resolvers read correctly:
// Paste in browser console on the landing page

import { resolveSeatId, resolveTujCode } from '/src/lib/gate-contract.js';

console.log('seat_id  →', resolveSeatId());   // expect: "TUJ-NM0000"
console.log('tuj_code →', resolveTujCode());  // expect: "TUJ-NM0000"
Both values must be non-null and match what was injected in Step 2.
ℹ resolveSeatId() checks URL → sessionStorage. resolveTujCode() checks URL → sessionStorage. Both must resolve from the URL params on first load.
0 / 4 steps complete
base44
Edit with Base44