Appearance
Payment Gateways Settings
The Payment Gateways Settings allow you to configure and manage payment processing methods for your e-commerce transactions, subscriptions, and other paid features.
Table of Contents
- Overview
- Accessing Payment Settings
- Supported Payment Gateways
- Configuring Payment Gateways
- Payment Gateway Settings
- Testing Payment Gateways
- Webhook Configuration
- Best Practices
Overview
Features
- ✅ Multiple payment gateway support
- ✅ Sandbox/Test mode
- ✅ Live/Production mode
- ✅ Gateway activation/deactivation
- ✅ Processing fees configuration
- ✅ Supported currencies
- ✅ Webhook management
- ✅ Payment method ordering
- ✅ Custom payment instructions
Admin Routes
- Payment Methods:
/admin/settings/payments - Payment Method Create:
/admin/settings/payments/create - Payment Method Edit:
/admin/settings/payments/{id}/edit
Accessing Payment Settings
From Admin Panel
- Log in to admin panel
- Navigate to Settings → Payment Gateways
- Or go directly to:
/admin/settings/payments
Permissions Required
- Manage Payment Methods:
manage-payment-methodspermission
Supported Payment Gateways
Credit Card Processors
Stripe
- Description: Popular payment processor
- Supports: Credit cards, debit cards, digital wallets
- Regions: Worldwide
- Fees: 2.9% + $0.30 per transaction
Authorize.Net
- Description: Payment gateway service
- Supports: Credit cards, debit cards
- Regions: US, Canada, UK, Australia
- Fees: Varies by plan
Square
- Description: Payment processing platform
- Supports: Credit cards, digital wallets
- Regions: US, Canada, UK, Australia, Japan
- Fees: 2.6% + $0.10 per transaction
Digital Wallets
PayPal
- Description: Digital wallet and payment processor
- Supports: PayPal accounts, credit cards
- Regions: Worldwide
- Fees: 2.9% + fixed fee per transaction
Regional Gateways
Razorpay
- Description: Payment gateway for India
- Supports: Credit cards, UPI, net banking
- Regions: India
- Fees: 2% per transaction
Mollie
- Description: European payment service
- Supports: Credit cards, iDEAL, SEPA
- Regions: Europe
- Fees: Varies by payment method
Klarna
- Description: Buy now, pay later service
- Supports: Installment payments
- Regions: Europe, US, Australia
- Fees: Varies
Adyen
- Description: Global payment platform
- Supports: Credit cards, digital wallets, local methods
- Regions: Worldwide
- Fees: Varies
Alternative Methods
Cash on Delivery (COD)
- Description: Payment upon delivery
- Supports: Physical products only
- Regions: Depends on shipping
- Fees: None (may charge handling fee)
Free Products
- Description: For free products/services
- Supports: $0 transactions
- Regions: All
- Fees: None
Configuring Payment Gateways
Creating Payment Method
- Go to Payment Gateways → Create New
- Or navigate to:
/admin/settings/payments/create
Basic Information
Payment Method Name
- Display name for customers
- Example:
Credit Card (Stripe) - Shown in checkout
Description
- Brief description
- Shown to customers
- Example:
Pay securely with your credit or debit card
Slug
- Auto-generated from name
- Used internally
- Must be unique
Gateway Configuration
Select Gateway Type
Options:
- Stripe
- PayPal
- Authorize.Net
- Razorpay
- Mollie
- Square
- Klarna
- Adyen
- Cash on Delivery
- Free Products
Gateway-Specific Settings
Stripe Configuration:
- Publishable Key: Public API key
- Secret Key: Private API key
- Webhook Secret: Webhook signing secret
- Mode: Sandbox or Live
PayPal Configuration:
- Client ID: PayPal app client ID
- Client Secret: PayPal app secret
- Mode: Sandbox or Live
- Webhook URL: PayPal webhook endpoint
Authorize.Net Configuration:
- API Login ID: Merchant API login
- Transaction Key: Transaction key
- Mode: Sandbox or Live
Razorpay Configuration:
- Key ID: Razorpay key ID
- Key Secret: Razorpay secret
- Mode: Test or Live
Mollie Configuration:
- API Key: Mollie API key
- Mode: Test or Live
Square Configuration:
- Application ID: Square app ID
- Access Token: Square access token
- Location ID: Square location ID
- Mode: Sandbox or Production
Klarna Configuration:
- Username: Klarna API username
- Password: Klarna API password
- Mode: Test or Live
Adyen Configuration:
- Merchant Account: Adyen merchant account
- API Key: Adyen API key
- Mode: Test or Live
Cash on Delivery:
- No API keys required
- Configure instructions only
Free Products:
- No configuration needed
- Automatically available
General Settings
Status
- Active: Enable payment method
- Inactive: Disable payment method
- Only active methods shown in checkout
Sandbox Mode
- Enable: Use test mode
- Disable: Use live/production mode
- Important: Always test in sandbox first
Supported Currencies
Add Currencies:
- Click Add Currency
- Select currency code:
- USD (US Dollar)
- EUR (Euro)
- GBP (British Pound)
- INR (Indian Rupee)
- And more...
- Click Add
Currency Support:
- Some gateways support multiple currencies
- Others are region-specific
- Check gateway documentation
Processing Fees
Fee Type:
- Percentage: Percentage of transaction
- Fixed: Fixed amount per transaction
- Both: Percentage + fixed amount
Fee Configuration:
- Percentage Fee: Example:
2.9% - Fixed Fee: Example:
$0.30 - Fees added to order total
- Shown to customers
Payment Instructions
Custom Instructions:
- Additional information for customers
- Shown during checkout
- Example:
Please have your order number ready
For Cash on Delivery:
- Delivery instructions
- Payment collection details
- Contact information
Display Settings
Icon
- Upload payment method icon
- Recommended size: 64x64px
- Format: PNG with transparency
- Shown in checkout
Color
- Payment method color
- Hex color code
- Example:
#635BFF - Used for branding
Display Order
- Order in checkout
- Lower numbers appear first
- Example:
1= first,2= second
Payment Gateway Settings
Editing Payment Method
- Click Edit on payment method
- Modify settings
- Click Update
- Changes saved
Toggling Status
Route: /admin/settings/payments/{id}/toggle-status
- Click Toggle Status button
- Status changes immediately
- Active ↔ Inactive
Setting Default
Route: /admin/settings/payments/{id}/set-default
- Click Set as Default
- Method becomes default
- Shown first in checkout
Deleting Payment Method
- Click Delete button
- Confirm deletion
- Warning: Cannot be undone
- Payment method removed
Testing Payment Gateways
Sandbox/Test Mode
Enable Test Mode
- Go to payment method settings
- Enable Sandbox Mode
- Enter test API keys
- Save settings
Test Cards
Stripe Test Cards:
- Success:
4242 4242 4242 4242 - Decline:
4000 0000 0000 0002 - 3D Secure:
4000 0025 0000 3155 - Use any future expiry date
- Use any 3-digit CVC
PayPal Test:
- Use PayPal sandbox accounts
- Create test buyer/seller accounts
- Test transactions in sandbox
Authorize.Net Test:
- Use test mode credentials
- Test card:
4111111111111111 - Use any expiry date
Testing Process
Enable Test Mode:
- Set sandbox mode
- Use test credentials
Create Test Order:
- Add product to cart
- Proceed to checkout
- Select test payment method
Complete Test Payment:
- Use test card details
- Complete payment
- Verify order created
Verify Results:
- Check order status
- Verify payment recorded
- Check webhook received
Going Live
Before Going Live
Verify Configuration:
- All settings correct
- Live API keys entered
- Webhooks configured
Test Thoroughly:
- Test all payment methods
- Test refunds
- Test webhooks
Disable Sandbox:
- Turn off sandbox mode
- Switch to live mode
- Save settings
Live Mode Checklist
- ✅ Live API keys configured
- ✅ Sandbox mode disabled
- ✅ Webhooks configured
- ✅ SSL certificate installed
- ✅ Tested with real transactions
- ✅ Refund process tested
Webhook Configuration
What are Webhooks?
Webhooks allow payment gateways to notify your application about payment events (success, failure, refunds, etc.).
Configuring Webhooks
Stripe Webhooks
Get Webhook URL:
- Your webhook URL:
https://yourdomain.com/webhooks/stripe
- Your webhook URL:
Configure in Stripe:
- Go to Stripe Dashboard
- Webhooks → Add endpoint
- Enter webhook URL
- Select events to listen for
Get Webhook Secret:
- Copy webhook signing secret
- Enter in admin panel
Events to Listen For:
payment_intent.succeededpayment_intent.payment_failedcharge.refunded
PayPal Webhooks
Get Webhook URL:
- Your webhook URL:
https://yourdomain.com/webhooks/paypal
- Your webhook URL:
Configure in PayPal:
- Go to PayPal Developer Dashboard
- My Apps & Credentials
- Webhooks → Add webhook
- Enter webhook URL
Events to Listen For:
PAYMENT.CAPTURE.COMPLETEDPAYMENT.CAPTURE.DENIEDPAYMENT.CAPTURE.REFUNDED
Webhook Security
Verify Webhook Signatures
- Always verify webhook signatures
- Prevents unauthorized requests
- Use webhook secrets
- Validate signatures in code
Webhook URL
Format:
https://yourdomain.com/webhooks/{gateway}Examples:
- Stripe:
/webhooks/stripe - PayPal:
/webhooks/paypal - Razorpay:
/webhooks/razorpay
Best Practices
Security
Protect API Keys:
- Never share API keys
- Use environment variables
- Rotate keys regularly
- Use different keys for test/live
Use HTTPS:
- Always use SSL/HTTPS
- Required for payment processing
- Protects customer data
PCI Compliance:
- Don't store card details
- Use tokenization
- Follow PCI DSS guidelines
- Use compliant gateways
Configuration
Test First:
- Always test in sandbox
- Verify all features work
- Test error scenarios
- Test refunds
Monitor Transactions:
- Check payment logs
- Monitor failed payments
- Review webhook logs
- Track refunds
Keep Updated:
- Update gateway integrations
- Stay current with API changes
- Monitor gateway status
- Update documentation
Troubleshooting
Payment Not Processing
Solutions:
- Verify API keys are correct
- Check sandbox/live mode
- Verify SSL certificate
- Check gateway status
- Review error logs
Webhooks Not Working
Solutions:
- Verify webhook URL is accessible
- Check webhook secret
- Verify SSL certificate
- Check firewall settings
- Review webhook logs
Refunds Not Processing
Solutions:
- Verify refund permissions
- Check transaction status
- Verify API credentials
- Check gateway limits
- Review refund logs
Related Documentation
Last Updated: [Date will be updated during final review]