PayPal Gateway
PayPal payment gateway integration for SaaS subscriptions. This module enables accepting payments via PayPal for tenant subscription billing.
Features
- PayPal Payments: Accept one-time and recurring payments via PayPal
- Subscription Billing: Automated recurring billing for tenant subscriptions
- Payment Webhooks: Automatic payment status updates via PayPal webhooks
- Payment History: Track all PayPal transactions and payment history
- Refund Processing: Process full or partial refunds through PayPal
- Multiple Currencies: Support for PayPal's supported currencies
Requirements
- Open Core Business Suite (Base System)
- MultiTenancyCore module (required)
- PayPal Business account
- PayPal API credentials (Client ID and Secret)
Installation
- Download the PayPal Gateway module package
- Extract the module to
Modules/PaypalGateway - Run the installation command:
php artisan module:enable PaypalGateway
php artisan migrate
- Configure your PayPal API credentials
- Clear the application cache:
php artisan optimize:clear
Usage
Configuration
Navigate to Settings > Payment Gateways > PayPal to configure:
- Enter your PayPal Client ID
- Enter your PayPal Client Secret
- Select environment (Sandbox or Production)
- Save settings
Webhook Setup
Configure webhooks in your PayPal Developer Dashboard:
- Go to your PayPal Developer account
- Navigate to your application
- Add webhook URL:
https://yourdomain.com/api/webhooks/paypal - Select events:
PAYMENT.SALE.COMPLETEDBILLING.SUBSCRIPTION.ACTIVATEDBILLING.SUBSCRIPTION.CANCELLEDBILLING.SUBSCRIPTION.EXPIRED
Subscription Management
PayPal subscriptions are automatically managed:
- New subscriptions created when tenants select PayPal
- Recurring payments processed automatically
- Failed payments trigger notification to tenant
- Cancelled subscriptions update tenant status
Payment History
View all PayPal transactions at Central Admin > Payments:
- Filter by tenant, date, or status
- View transaction details
- Process refunds when needed
Configuration
Access module settings at Settings > PayPal Gateway to configure:
- API credentials
- Environment (Sandbox/Production)
- Default currency
- Webhook secret
- Payment descriptions