Practitionist / Practitionist/elluminar_web
Gifting & small-team seat purchases
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 1
- Forks
- 0
- Avg merge
- 17h 2m
- Merged PRs (30d)
- 18
Description
Why / Context
PRD §7.2E: corporate gifting / small-team seat purchase is a lightweight revenue lever distinct from the full enterprise motion — a manager buying 5 seats of a course for their team shouldn't need a sales call. Gift columns were built into OrderItem at MVP; this issue turns them on.
Schema already in place — NO migration required
OrderItem.giftRecipientEmail / giftClaimToken (unique) / giftClaimedById / giftClaimedAtCartItem.giftRecipientEmail+ metadata (gift message)Enrollment(source: GIFT)- Quantity >1 on OrderItem supports seat-pack purchases;
Waitlistnot needed here
Implementation plan
- Gift purchase flow: "Buy as gift" on course/project pages → recipient email + message at cart line level → checkout normally; fulfillment mints
giftClaimTokenper unit instead of enrolling the buyer. - Claim flow: recipient email w/ claim link → signup/login → claim page validates token (unclaimed, unexpired per policy) → creates Enrollment/ProjectInstance(source GIFT) → token consumed (
giftClaimedById/At). - Buyer management: /account/gifts — status per gift (sent/claimed), resend email, reassign recipient before claim, cancel-unclaimed within refund window (normal Refund path).
- Team seats (multi-quantity): quantity picker for eligible items → N claim tokens under one OrderItem → buyer's seat-management table (invite emails per seat, revoke unclaimed, claim links) — deliberately no org/license machinery (that's enterprise).
- Pricing: optional volume discount rule in pricing engine (PlatformConfig thresholds, e.g., 5+ seats −10%).
- Emails: gift-received (with message), reminder before expiry, claimed-notification to buyer (via notification facade).
- Edge cases: recipient already enrolled → credit-to-account choice (support flow documented); refunds void unclaimed tokens.
- GST note: B2B buyers can enter GSTIN in billTo (field exists) — invoice shows it (full B2B treatment in issue #24).
Acceptance criteria
- Gifted course reaches recipient; claim creates their enrollment; buyer never gets access
- 5-seat purchase yields 5 claim links; buyer can invite/revoke unclaimed seats
- Refund of an unclaimed gift voids its token; claimed gifts follow normal consumption guards
- Volume discount applies at configured thresholds
- Duplicate-claim and expired-token paths handled gracefully
Dependencies / sequencing
- MVP M7 fulfillment is the base; notification facade (issue #10) optional
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with MVP M7 fulfillment and the existing OrderItem gift fields, Enrollment(source: GIFT), and CartItem gift metadata. Trace checkout, claim, account gift management, refund, pricing, and notification-facade entry points, then verify the acceptance criteria for per-seat tokens, claiming, refunds, discounts, and duplicate or expired tokens.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- backend, full-stack, payments
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100