Configuration
Environment Configuration
Laravel Sail Configuration
If you're using Laravel Sail, you can customize the Docker environment:
bash
# Edit Sail configuration
./vendor/bin/sail artisan sail:publish
# Customize docker-compose.yml
# Add additional services like Redis, MailHog, etc.Important Configuration Notes
- Port Configuration: The application runs on port
3300by default - Application Access: The system uses FilamentPHP as the main interface, accessible directly at the root URL
- Database Ports: When using Sail, database ports are forwarded:
- MySQL:
3306(container) →3307(host) - Redis:
6379(container) →6380(host)
- MySQL:
- Etherscan API: Get your API key from Etherscan for blockchain data
- Cryptography: Private keys and sensitive data are encrypted using the configured cryptography settings
Blockchain Network Configuration
Configure supported networks in the admin panel:
Network Settings
- Network Name: Display name for the network
- RPC URL: Blockchain node RPC endpoint
- Chain ID: Network chain identifier
- Currency Symbol: Native token symbol
- Block Explorer: Transaction explorer URL
Supported Networks
Zafira supports multiple blockchain networks including:
- Ethereum Mainnet
- Ethereum Testnets (Goerli, Sepolia)
- Polygon
- Binance Smart Chain
- And other EVM-compatible networks
Webhook Configuration
Webhooks are configured directly through the application interface. Navigate to Webhooks in the sidebar menu to manage webhook configurations.
Webhook Setup Process
- Access Webhooks: Go to the Webhooks section in the sidebar menu
- Create New Webhook: Click "Create" to add a new webhook
- Configure Settings:
- Webhook URL: Enter the endpoint URL where notifications will be sent
- Webhook Type: Select the type of events to monitor:
wallet- Wallet-related eventstransaction- Transaction eventsbalance- Balance update eventstoken- Token-related eventscharge- Payment charge eventsall- All events
- Status: Set to
activeorinactive - Events: Select specific events to monitor (dynamically loaded based on type)
- Secret (Optional): Enter a secret key for webhook signature verification
Available Events by Type
- Charge Events:
paid,expired,created,failed - Transaction Events:
created,confirmed,failed - Balance Events:
updated - Token Events:
added,removed - Wallet Events:
created,updated
Security Configuration
Data Encryption
- Private keys are encrypted using AES-256 encryption
- Mnemonic phrases are securely stored with encryption
- API tokens are hashed and secured
- Webhook signatures for payload verification
Access Control
- Role-based access control system
- API rate limiting to prevent abuse
- CSRF protection for web forms
- Session management with secure cookies
Audit Trail
- Transaction logging for all wallet operations
- API access logging for security monitoring
- User activity tracking for compliance
Performance Optimization
Production Configuration
bash
# Production optimization
php artisan config:cache
php artisan route:cache
php artisan view:cache
php artisan optimizeRedis Configuration (Optional)
If using Redis for caching:
env
REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379Monitoring and Logging
Application Logs
Logs are stored in storage/logs/ directory:
laravel.log- General application logswebhook.log- Webhook delivery logstransaction.log- Transaction processing logs
System Monitoring
The application includes a supervisor endpoint for health monitoring:
bash
# Check system health
wget -O /dev/null https://zafira-app.vratts.com/api/supervisorDatabase Configuration
Migration and Seeding
bash
# Run migrations
php artisan migrate
# Seed initial data
php artisan db:seed
# Reset database (development only)
php artisan migrate:fresh --seedDatabase Maintenance
bash
# Optimize database
php artisan optimize
# Clear cache
php artisan cache:clear
php artisan config:clear
php artisan route:clear
php artisan view:clearNext Steps
- API Documentation - Learn about the API endpoints
- Features Guide - Explore application features
- Deployment - Deploy to production