Skip to content

feat(payments): direct organiser UPI payment integration and verification workflow - #63

Merged
Satelink-Protocol merged 3 commits into
mainfrom
feature/direct-organiser-upi-payment
Nov 24, 2026
Merged

Satelink-Protocol merged 3 commits into
mainfrom
feature/direct-organiser-upi-payment

Conversation

@Satelink-Protocol

Copy link
Copy Markdown
Contributor

NIGHTLIFEZ — Direct Organiser UPI Payment Integration

Overview

Replaces the gateway-pending blocker with a direct organiser-to-attendee UPI payment architecture. Organisers configure their UPI ID and payee name during event creation, attendees pay directly to the organiser via dynamic UPI QR code or mobile deep link, and ticket issuance is gated by independent organiser verification of incoming bank credits.

Key Changes

  1. Database Migration (migrations/032_direct_organiser_upi_payments.sql):
    • Added payment_method, organiser_upi_id, organiser_payee_name, and payment_instructions to events.
    • Added booking_ref, direct_upi_status, utr_reference, payment_reported_at, verified_by_user_id, verified_at, verification_note, and rejection_reason to bookings.
    • Created append-only audit ledger table direct_upi_payment_audits.
  2. Organiser Wizard Configuration:
    • Added explicit Payment section: Free event vs Direct UPI payment to organiser.
    • Input fields for UPI ID, Payee display name, attendee instructions, format validation, and unverified destination status pill.
    • Quick-load button for saved business payment details.
    • Removed obsolete gateway-pending blockers for direct UPI events in publish validation.
  3. Direct UPI Attendee Checkout:
    • Dynamic SVG QR code and safe deep link intent: upi://pay?pa=...&pn=...&am=...&cu=INR&tn=....
    • Strict server-side amount calculation from ticket tier price in paise.
    • Attendee cannot tamper with destination UPI ID or amount.
    • 30-minute reservation countdown timer with automatic inventory release upon hold expiry.
    • Clear transparency disclosure: "Your payment goes directly to the event organiser's UPI account. NIGHTLIFEZ does not collect or hold this ticket payment. Your ticket will be confirmed after the organiser verifies receipt."
  4. State Machine & Verification Workflow:
    • awaiting_payment -> payment_reported -> payment_under_review -> payment_confirmed / payment_rejected / expired / cancelled.
    • Attendee submits 12-digit UTR reference (reference only; does not issue tickets).
    • Organiser dashboard tab for Direct UPI payments with booking details, reported UTR, and amount.
    • Mandatory verification confirmation modal displaying: "I confirm that I independently checked my bank/UPI account and verified that the full amount was received for this booking."
    • Digital tickets issued exactly once on confirmation; rejection or hold expiry immediately restores inventory.
  5. Comprehensive Verification & Tests:
    • Added test/direct-organiser-upi.test.js covering all 15 required scenarios.
    • Verified zero live gateway flags needed (ENABLE_LIVE_PAYMENTS=false, UPI_CHECKOUT_ENABLED=false).
    • All 231 files pass lint (npm run lint).
    • All 16 database migration tests pass.
    • Desktop and mobile Playwright tests pass.

…tion workflow

- Add migration 032: direct organiser upi settings, payment statuses, and append-only audit ledger
- Implement direct UPI checkout with dynamic QR, payee intent, and transparent disclosures
- Add organiser event wizard payment configuration (Free vs Direct UPI) with format validation
- Implement payment verification state machine (awaiting_payment, payment_reported, payment_confirmed, payment_rejected, expired)
- Add organiser payment management tab with explicit independently-verified bank credit confirmation requirement
- Enforce inventory reservation holds and release on rejection/expiry
- Add 15 automated test scenarios covering the full direct UPI lifecycle
@vercel

vercel Bot commented Nov 24, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
strangersmeetup Ready Ready Preview Nov 24, 2026 11:21am UTC

@Satelink-Protocol
Satelink-Protocol merged commit 7c6b16d into main Nov 24, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant