NextTrip Module — Integration Test Harness

Simulates an external module app testing auth redirect flows with NextTrip ID

Configuration

1. Initiate Auth Flow

Click a button to redirect to NextTrip ID UI. After auth, you'll be redirected back here with tokens in the URL fragment (implicit) or an authorization code (PKCE).

1b. SSO Handoff (server-side, with consent claims)

Simulates a partner calling GET /v1/sso/handoff with a signed JWT that carries consent claims. The auth server auto-completes, 302s back to this page with ?handoff_id=<uuid>, and this harness calls POST /v1/sso/exchange to pick up tokens. The JWT is HS256-signed in the browser using the secret below — dev tool only, never paste a production secret.

terms_accepted_at and privacy_accepted_at are stamped with the current timestamp when you click the button.

Idle. Fill in the fields and click the button.

2. Token Data

No tokens received yet. Complete an auth flow above.

2b. Email Verification Redirect

Not applicable — only shown after a registration verify-email redirect.

3. API Tests

After receiving tokens, test API calls to verify they work.