Skip to content

Add discount code and promotion system for organizations#500

Merged
bokelley merged 1 commit into
mainfrom
bokelley/discount-codes
Jan 3, 2026
Merged

Add discount code and promotion system for organizations#500
bokelley merged 1 commit into
mainfrom
bokelley/discount-codes

Conversation

@bokelley

@bokelley bokelley commented Jan 3, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add database migration for org discount fields (percent, amount, reason, granted_by, etc.)
  • Add Stripe coupon/promotion code creation functions
  • Enable promotion codes for one-time payments (was subscription-only)
  • Add admin HTTP routes for discount management
  • Add Addie admin tools: grant_discount, remove_discount, list_discounts, create_promotion_code
  • Add input validation for discount bounds (1-100% or positive amounts)

This allows admins to grant discounts to organizations (like startups) and create promotion codes they can use at checkout. Discounts are tracked at the org level with attribution (who granted it and why).

Test plan

  • TypeScript compiles without errors
  • All existing tests pass
  • Code review addressed validation issues
  • Manual test: Grant discount to org via Addie or HTTP route
  • Manual test: Verify promotion code works at checkout

🤖 Generated with Claude Code

- Add database migration for org discount fields (percent, amount, reason, granted_by, etc.)
- Add Stripe coupon/promotion code creation functions
- Enable promotion codes for one-time payments (was subscription-only)
- Add admin HTTP routes for discount management
- Add Addie admin tools: grant_discount, remove_discount, list_discounts, create_promotion_code
- Add input validation for discount bounds (1-100% or positive amounts)

This allows admins to grant discounts to organizations (like startups) and create
promotion codes they can use at checkout. Discounts are tracked at the org level
with attribution (who granted it and why).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@bokelley bokelley merged commit bc49355 into main Jan 3, 2026
6 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