Commit Graph

6 Commits

Author SHA1 Message Date
idevakk
75086ad83b feat(payment): integrate Polar.sh payment provider with checkout flow
- Build PolarProvider from scratch with proper HTTP API integration
  - Add encrypted configuration loading from payment_providers table via model
  - Implement sandbox/live environment switching with proper credential handling
  - Fix product creation API structure for Polar.sh requirements
  - Add comprehensive error handling and logging throughout checkout flow
  - Fix PaymentController checkout URL handling to support Polar's checkout_url response
  - Add debug logging for troubleshooting checkout session creation
  - Support both regular and trial checkout flows for Polar payments
2025-12-04 10:29:25 -08:00
idevakk
ad89b84471 feat(payments): enhance Polar.sh provider with official API compliance
- Add comprehensive rate limiting (300 req/min) with automatic throttling
  - Implement centralized API request method for consistent authentication
  - Add support for Polar-specific webhook events (order.created, order.paid, subscription.active, customer.state_changed, benefit_grant.created)
  - Update API endpoints to match Polar's official structure (remove /v1 prefix)
  - Add external_id support for reliable customer-user mapping
  - Implement sandbox mode with separate credentials configuration
  - Add discount code support in checkout flow
  - Add credential validation method for API connectivity testing
  - Update webhook signature validation and event handling
  - Enhance error handling and logging throughout provider
  - Add proper metadata structure with user and plan information
  - Update services configuration and environment variables for sandbox support

  BREAKING CHANGE: Updated API endpoint structure and webhook event handling to comply with Polar.sh official API specification.
2025-11-22 06:19:27 -08:00
idevakk
0baacdc386 feat: implements activation key as payment provider and migrate activation key to use unified payment system 2025-11-21 12:14:20 -08:00
idevakk
27ac13948c feat: implement comprehensive multi-provider payment processing system
- Add unified payment provider architecture with contract-based design
  - Implement 6 payment providers: Stripe, Lemon Squeezy, Polar, Oxapay, Crypto, Activation Keys
  - Create subscription management with lifecycle handling (create, cancel, pause, resume, update)
  - Add coupon system with usage tracking and trial extensions
  - Build Filament admin resources for payment providers, subscriptions, coupons, and trials
  - Implement payment orchestration service with provider registry and configuration management
  - Add comprehensive payment logging and webhook handling for all providers
  - Create customer analytics dashboard with revenue, churn, and lifetime value metrics
  - Add subscription migration service for provider switching
  - Include extensive test coverage for all payment functionality
2025-11-19 09:37:00 -08:00
idevakk
a7029b5f57 feat: add user impersonation service 2025-11-17 10:44:19 -08:00
idevakk
4615d384be feat: implement repository architecture with smart caching
- Add base repository interfaces and abstract classes
  - Implement separated read/write repositories for Domain and Username models
  - Add intelligent query caching with automatic invalidation
  - Include cache management service and CLI commands
  - Add comprehensive configuration for cache TTL and monitoring
  - Enhance performance through optimized data access patterns
2025-11-15 22:11:19 -08:00