Bicrypto 6.0.4
3 January 2026
This release has upgrade notes. Read them before updating — they describe behaviour changes that need your attention.
Core v6.0.4
Release Date: January 3, 2026 Tags: MAJOR UPDATE, WALLET SERVICE, NOTIFICATION SERVICE, SETTINGS MIGRATION, ARCHITECTURE, SECURITY, BUG FIX
Overview
Version 6.0.4 introduces three major architectural improvements: a comprehensive Centralized Wallet Service, a Multi-Channel Notification Service, and Database-Backed Settings System. The wallet service consolidates all wallet operations across the platform, the notification service provides a unified solution for all platform communications, and the new settings system allows administrators to manage all platform configuration through the admin panel without server restarts. Additionally includes important bug fixes for KYC and binary trading.
Upgrade Notes
Step 1: Remove Deprecated Files
Run this command from your public_html directory to remove all deprecated files:
rm .eslintignore \
frontend/.eslintrc.json \
"frontend/app/[locale]/(dashboard)/user/profile/components/profile-content.tsx" \
"frontend/app/[locale]/(dashboard)/user/profile/components/profile-sidebar.tsx" \
"frontend/app/[locale]/(dashboard)/user/profile/components/tabs/dashboard-tab.tsx" \
"frontend/app/[locale]/(dashboard)/user/profile/components/tabs/personal-info-tab.tsx" \
"frontend/app/[locale]/(dashboard)/user/profile/components/tabs/security-tab.tsx" \
"frontend/app/[locale]/(dashboard)/user/profile/components/ui/activity-card.tsx" \
"frontend/app/[locale]/(dashboard)/user/profile/components/ui/stat-card.tsx" \
"frontend/app/[locale]/(dashboard)/user/profile/components/ui/tab-button.tsx" \
"frontend/app/[locale]/(utility)/comming-soon/page.tsx" \
"frontend/app/[locale]/(utility)/maintinance/page.tsx"Step 2: Update Notification Templates
Run the following command to update notification templates with SMS and Push content:
pnpm seed:notificationThis will add SMS (160 char limit) and Push (240 char limit) message templates to all existing notification templates, enabling multi-channel notifications.
Step 3: Generate VAPID Keys for Web Push
Generate VAPID keys for browser push notifications:
pnpm vapid:generateThis will prompt for your email and automatically update your .env file with the required VAPID keys.
Step 4: Run Updator
pnpm updatorStep 5: Re-save Settings
After running the updator, visit each of the following settings pages in the admin panel and click Save to ensure all settings are properly initialized in the database:
- Platform Settings (
/admin/settings) - Security, 2FA, and integration settings - Blog Settings (
/admin/blog/settings) - Blog status and layout settings - Trading Settings (
/admin/trading/settings) - Spot trading settings - Binary Settings (
/admin/finance/binary/settings) - Binary trading configuration
This step is required because the settings system has been migrated from environment variables to the database. Re-saving ensures all default values are properly stored.
Step 6: Test Notification Service
Visit the Notification Service dashboard to verify all channels are working correctly:
- Notification Dashboard (
/admin/system/notification) - Test all notification channels (IN_APP, EMAIL, SMS, PUSH) - Use the Channel Testing tab to send test notifications to each channel
- Verify provider status in the Settings Panel tab
Compatibility
- All existing integrations continue to work without changes
- No database schema changes are required
Upgrade Support
For assistance with migration or issues:
- Visit our Support Center
- Review the Documentation
- Check Server Requirements
Added
Centralized Wallet Service
A complete overhaul of how wallet operations are handled throughout the platform:
Single Source of Truth
- All wallet balance operations now flow through one centralized service
- Consistent behavior for all wallet types: FIAT, SPOT, ECO, FUTURES, and COPY_TRADING
Atomic Transactions
- All wallet operations are now wrapped in database transactions
- Prevents partial updates that could lead to balance inconsistencies
- Automatic rollback on any failure during multi-step operations
Idempotency Protection
- Every wallet operation requires a unique idempotency key
- Prevents duplicate credits/debits from retried requests
- Critical for payment webhook handlers that may receive duplicate notifications
Row-Level Locking
- Concurrent wallet updates are now properly synchronized
- Eliminates race conditions that could cause balance discrepancies
- Uses database-level locking for maximum reliability
Safe Arithmetic
- All balance calculations now use precision-safe arithmetic
- Eliminates floating-point errors in financial calculations
- Configurable precision per currency type
Dynamic Precision Caching
- Currency precision values are now loaded from database
- No more fixed precision values that ignore your currency configuration
- Auto-refreshing cache with 5-minute TTL
Comprehensive Error Handling
- Dedicated error types for common wallet issues:
- Insufficient funds
- Wallet not found
- Duplicate operation
- Negative balance prevention
- Wallet disabled
- Invalid amount
Wallet Operations Supported
The new service handles all wallet operations:
- Credits: Deposits, incoming transfers, refunds, rewards, payouts
- Debits: Withdrawals, outgoing transfers, fees, payments
- Holds: Lock funds for pending orders
- Releases: Return held funds to available balance
- Transfers: Atomic movement between wallets with optional fees
- Execute from Hold: Complete trades from held funds
Multi-Chain Address Support
Enhanced ECO wallet creation with support for:
- EVM Chains: Ethereum, BSC, Polygon, Arbitrum, Optimism, Base, Avalanche, Fantom, Linea, Celo
- UTXO Chains: Bitcoin, Litecoin, Dogecoin, Dash
- Special Chains: Solana, Tron, Monero, TON
Multi-Channel Notification Service
A complete enterprise-grade notification system that handles all platform communications:
Unified Notification Architecture
- Single Service for All Notifications: one notification service replaces notification logic that was previously scattered across the platform
- Multi-Channel Support: IN_APP, EMAIL, SMS, and PUSH notifications from a single API
- Notification Types: SYSTEM, INVESTMENT, TRADE, P2P, COPY_TRADING, ICO, STAKING, WALLET, SECURITY, MARKETING, FOREX, BINARY, FUTURES, ECOMMERCE, NFT, ALERT, MESSAGE, USER
- Priority Levels: LOW, NORMAL, HIGH, and URGENT for intelligent message routing
Core Features
Idempotency Protection
- Unique idempotency keys prevent duplicate notifications
- 30-day deduplication window using Redis cache
- Critical for webhook handlers and retry scenarios
User Preferences
- Respects per-user, per-type notification preferences
- 1-hour preference cache with auto-refresh
- Granular control over which channels users want to receive
Delivery Tracking
- Complete audit trail of all notification attempts
- 30-day delivery status retention
- Per-channel success/failure tracking
Smart Channel Selection
- Automatic channel selection based on notification type
- Priority-based routing (URGENT → All channels, NORMAL → IN_APP only)
- Fallback mechanisms for channel failures
Channel Implementations
In-App Notifications
- WebSocket real-time delivery
- Persistent storage in database
- Badge counts and read/unread tracking
Email Notifications
- Template-based email rendering
- Queue-based processing
- Configurable SMTP and SendGrid support
- Automatic retry on failure
SMS Notifications
- Twilio integration
- E.164 phone number validation
- Template system for consistent messaging
Push Notifications
- Web Push (VAPID) - Browser push notifications without Firebase
- Works with Chrome, Firefox, Edge, Safari
- No third-party service required for web browsers
- Automatic VAPID key generation script (
pnpm vapid:generate) - Service worker for background notification handling
- Firebase Cloud Messaging (FCM) - For mobile apps
- Required for iOS and Android native apps
- Device token management
- Smart Provider Selection
- Automatically uses VAPID for web subscriptions
- Automatically uses FCM for mobile tokens
- Supports both simultaneously
- Rich notification payloads with badges and actions
Advanced Capabilities
Batch Operations
- Batch sending: Send to multiple users efficiently
- Send by permission: Target users by permission level
- Optimized database queries and caching
Template Engine
- Templating for emails
- Variable substitution for personalization
- Channel-specific template support
Redis Caching
- User preference caching (1-hour TTL)
- Idempotency tracking (30-day TTL)
- Delivery status caching (30-day TTL)
- Cache hit rate monitoring
Email Queue Management
- Queue for email processing
- Configurable retry strategies
- Dead letter queue for failed jobs
- Queue statistics and monitoring
Admin Dashboard
Overview Tab
- Real-time statistics with glassmorphism stats cards
- Total Sent, Failed, Queue Jobs, Success Rate
- Channel status monitoring (IN_APP, EMAIL, SMS, PUSH)
- Performance metrics with visual progress bars
- Queue health indicators
- System uptime tracking
- Redis connection status
Health Monitor Tab
- Overall system health status with color-coded indicators
- Individual channel health checks
- Redis cache connection monitoring
- Real-time health updates with manual refresh
- Detailed error reporting per channel
Channel Testing Tab
- Interactive test tools for all 4 channels
- User ID configuration with optional overrides
- Email address override for testing
- Phone number override for SMS (E.164 format)
- Real-time test results with success/failure indicators
- Delivery status tracking per test
- Testing tips and best practices
Queue Manager Tab
- Real-time queue statistics (Waiting, Active, Completed, Failed, Total)
- Queue health monitoring with status badges
- Failure rate calculation and alerts
- Queue cleanup tools with configurable age
- Safety confirmation dialogs for destructive actions
- Health indicators (degraded when >10% failure rate)
Metrics Panel Tab
- Time-based analytics (Hour, Day, Week, Month)
- Total notification overview metrics
- Channel-specific performance breakdown
- Notification type distribution
- Success rate visualization per channel
- Trend analysis and comparisons
Settings Panel Tab
- Channel configuration display
- Provider status overview (SendGrid, Nodemailer, Twilio, FCM)
- Feature status indicators:
- Idempotency (enabled, 30-day TTL)
- User Preferences (enabled, 1-hour cache)
- Delivery Tracking (enabled, 30-day TTL)
- Priority levels overview
- All 15+ notification types listed
- Provider configuration status
Affected Systems
The new service now carries notifications for:
- P2P Trading notifications (10+ notification types)
- Copy Trading notifications (follower/leader events)
- NFT marketplace notifications (listings, bids, auctions)
- Ecosystem wallet notifications (deposits, withdrawals, transfers)
- ICO notifications (contributions, vesting, refunds)
- Staking notifications (deposits, claims, rewards)
- Forex trading notifications (deposits, withdrawals, trades)
- Futures trading notifications (positions, liquidations)
- Binary trading notifications (orders, outcomes)
- E-commerce notifications (orders, shipping)
- Gateway notifications (payments, refunds)
- Investment notifications (AI trading, market maker)
Database-Backed Settings System
All platform configuration has been migrated from environment variables to the database, allowing real-time configuration changes through the admin panel:
Settings Now in Admin Panel
Security Settings (/admin/settings):
- Authentication:
- Google OAuth Login - Enable/disable social login
- Email Verification - Require email verification after registration
- Two-Factor Authentication:
- Master 2FA toggle
- SMS-based authentication
- Email-based authentication
- Authenticator app (TOTP)
- Protection:
- Google reCAPTCHA - Bot protection for forms
Integration Settings (/admin/settings):
- Google Analytics - Website analytics tracking
- Facebook Pixel - Advertising and conversion tracking
Module-Specific Settings:
- Blog Settings (
/admin/blog/settings):- Blog status toggle
- Post layout selection (Default/Modern/Classic)
- Trading Settings (
/admin/trading/settings):- Spot trading enable/disable
- Binary Trading Settings (
/admin/finance/binary/settings):- Master toggle to enable/disable binary trading
- Practice/demo mode toggle
- Order types configuration (Rise/Fall, Higher/Lower, Touch/No Touch, Call/Put, Turbo)
- Duration settings
- Payout percentages
- Barrier and strike levels
- Risk management rules
- Cancellation policies
Key Benefits
- Instant Changes: All settings take effect immediately without server restart
- Admin-Friendly: Configure through web interface instead of editing files
- Centralized: All platform settings managed in one place
- Secure: No need to access server files for configuration
- Environment Independent: Same settings work across all environments
Maintenance Mode Improvements
- Automatic maintenance page when server stops
- No configuration needed
Migration Details
Removed Environment Variables:
NEXT_PUBLIC_GOOGLE_AUTH_STATUSNEXT_PUBLIC_VERIFY_EMAIL_STATUSNEXT_PUBLIC_2FA_STATUSand related 2FA method togglesNEXT_PUBLIC_GOOGLE_RECAPTCHA_STATUSNEXT_PUBLIC_GOOGLE_ANALYTICS_STATUSNEXT_PUBLIC_FACEBOOK_PIXEL_STATUSNEXT_PUBLIC_BLOG_STATUSNEXT_PUBLIC_BINARY_STATUSandNEXT_PUBLIC_BINARY_PRACTICE_STATUSNEXT_PUBLIC_MAINTENANCE_STATUS
Retained in .env (API keys and credentials):
NEXT_PUBLIC_GOOGLE_CLIENT_IDNEXT_PUBLIC_GOOGLE_RECAPTCHA_SITE_KEYNEXT_PUBLIC_GOOGLE_ANALYTICS_IDNEXT_PUBLIC_FACEBOOK_PIXEL_ID
Notification System Configuration
Email Provider Configuration (Choose one)
Option 1: SMTP (Nodemailer)
APP_EMAILER="nodemailer-smtp"APP_NODEMAILER_SMTP_HOST- Your SMTP server hostnameAPP_NODEMAILER_SMTP_PORT- SMTP port (587 for TLS, 465 for SSL)APP_NODEMAILER_SMTP_ENCRYPTION- "tls" or "ssl"APP_NODEMAILER_SMTP_SENDER- Your sender email addressAPP_NODEMAILER_SMTP_PASSWORD- SMTP authentication passwordNEXT_PUBLIC_APP_EMAIL- Public-facing email addressAPP_EMAIL_SENDER_NAME- Display name for emails
Option 2: Gmail/Outlook (Nodemailer Service)
APP_EMAILER="nodemailer-service"APP_NODEMAILER_SERVICE- "gmail" or "outlook"APP_NODEMAILER_SERVICE_SENDER- Your Gmail/Outlook emailAPP_NODEMAILER_SERVICE_PASSWORD- App-specific password (not your account password)NEXT_PUBLIC_APP_EMAIL- Public-facing email addressAPP_EMAIL_SENDER_NAME- Display name for emails
Option 3: SendGrid
APP_EMAILER="nodemailer-sendgrid"APP_SENDGRID_API_KEY- Your SendGrid API keyAPP_SENDGRID_SENDER- Verified sender email in SendGridNEXT_PUBLIC_APP_EMAIL- Public-facing email addressAPP_EMAIL_SENDER_NAME- Display name for emails
SMS Provider Configuration
APP_TWILIO_ACCOUNT_SID- Twilio Account SIDAPP_TWILIO_AUTH_TOKEN- Twilio Auth TokenAPP_TWILIO_PHONE_NUMBER- Your Twilio phone number (E.164 format: +1234567890)APP_SUPPORT_PHONE_NUMBER- Support phone number for SMS messages
Push Notification Configuration
Two options are available for push notifications. You can use either one or both:
Option 1: Web Push (VAPID) - Recommended for Browsers
Works with Chrome, Firefox, Edge, and Safari without requiring Firebase.
# Generate VAPID keys automatically
pnpm vapid:generateThis script will prompt for your email and automatically update your .env file with:
VAPID_PUBLIC_KEY- Generated public key for browser subscriptionsVAPID_PRIVATE_KEY- Generated private key (keep secret!)VAPID_SUBJECT- Your email (mailto:admin@example.com) or website URL
Option 2: Firebase Cloud Messaging (FCM) - For Mobile Apps
Required for native iOS and Android apps:
FCM_PROJECT_ID- Your Firebase project IDFCM_PRIVATE_KEY- Firebase service account private keyFCM_CLIENT_EMAIL- Firebase service account emailFCM_SERVICE_ACCOUNT_PATH- Alternative: path to service account JSON file
Important Notes
- All email providers are now centrally managed through the notification service
- The system automatically detects and uses the configured provider
- No code changes needed to switch between providers
- Provider status is displayed in the admin notification settings panel
- Test each channel through the admin panel after configuration
- Web Push (VAPID) is recommended for browser notifications - no Firebase account needed
- FCM is only required if you have native iOS/Android mobile apps
- Both VAPID and FCM can be configured simultaneously - the system will use the appropriate one based on subscription type
Changed
Backend Security Validation
- Binary Order Creation: Added validation to check
binaryStatusandbinaryPracticeStatussettings before allowing order placement to prevent money-spending when features are disabled - Investment Creation: Added validation to check
investmentsetting before creating investments to prevent unauthorized investment creation - Spot Trading Orders: Added validation to check
spotStatussetting before creating orders to prevent trading when feature is disabled - Read-Only Endpoints Protected: Market listing and other read-only endpoints remain unrestricted for better user experience while money-spending operations are properly gated
Payment Gateway Handlers
- All fiat deposit verification handlers now use the centralized wallet service
- Consistent error handling across all payment gateways
- Improved transaction logging with operation metadata
Gateway Operations
- Refund processing uses atomic wallet operations
- Fee collection properly tracked through wallet service
- Payout processing with proper audit trail
Trading Operations
- Exchange order wallet operations centralized
- Binary order payouts use safe arithmetic
- Copy trading allocations properly tracked
P2P Trading
- Trade release and cancellation use atomic operations
- Offer creation with proper fund locking
- Dispute resolution through centralized service
Admin Settings Enhancements
- Clear Settings Cache Button: Added a cache refresh button to the System Settings page header for quick cache invalidation when settings don't reflect correctly
- VAPID Provider Detection: Notification settings panel now correctly shows VAPID (Web Push) vs FCM (Firebase) based on configured environment variables
- Settings Cache Fix: Fixed a bug where updating settings could corrupt the in-memory cache, causing only partial settings to be returned
Notification Templates
- SMS Templates Added: All notification templates now include SMS message content (160 character limit)
- Push Templates Added: All notification templates now include Push notification body content (240 character limit)
- SMS & Push Enabled by Default: All 99 notification templates now have SMS and Push enabled by default
- Template Seeder Update: Running
pnpm seed:notificationwill now update existing templates with SMS/Push content and enable the flags - Template Manager UI: SMS and Push channel toggles are now fully functional in the admin notification template editor (
/admin/system/notification/template)
PWA Management & Push Notifications
- Auto-Generated Manifest Files: PWA manifest files (
manifest.jsonandsite.webmanifest) are now auto-generated if missing when accessing PWA settings, using environment variables for default values - Multi-Device Push Support: Push notifications now properly send to ALL registered devices instead of just one, enabling users to receive notifications on desktop and mobile simultaneously
- Automatic Subscription Sync: Browser push subscriptions are automatically synced with the server when visiting the notifications settings page, ensuring devices are always registered
- Device ID Generation: Consistent device IDs are generated per device, ensuring the same device always uses the same identifier across sessions
- Fixed Notification Icons: Push notification icons now display correctly
- Consolidated Startup Logs: Notification service startup now shows a single clean log line listing the active channels instead of multiple verbose entries, and providers are initialized only once
Ecosystem Operations
- ECO wallet creation streamlined
- Blockchain deposit processing improved
- Transfer operations between wallet types unified
Data Table Filter Responsiveness
- Improved Grid Breakpoints: Filter grid now uses more appropriate breakpoints to prevent overlap:
- Single column on mobile (default)
- 2 columns at
md(768px+) - 3 columns at
xl(1280px+) - 4 columns at
2xl(1536px+)
- Text Filter Stacking: Operator select and input now stack vertically on smaller screens, switching to horizontal layout at
lg(1024px+) - Range Filter Stacking: Operator select and value inputs now stack vertically until
lgbreakpoint, with "between" mode inputs stacking untilsmbreakpoint - Reduced Padding on Mobile: Filter container now uses smaller gap and padding on mobile with larger values on wider screens
- Prevented Overflow: Filter cells no longer overflow in constrained grid cells
Binary Settings UI Improvements
- Changed the binary master toggles (Binary Trading Status and Practice Mode Status) to sit at the top of the settings page as the most important settings
- Changed all grid layouts in the binary settings page for proper mobile and tablet responsiveness
- Changed binary configuration to three completely separate, independent settings — status, practice status and advanced settings — with no legacy compatibility layer
- Changed the Master Controls section to a prominent card design with gradient styling
Blog Settings Organization
- Added a new "General" tab as the first tab in blog settings for primary configuration
- Changed the Blog Status toggle and Blog Post Layout to live on the General tab rather than the Display tab
- Changed navigation so General settings appear first, making the most important blog configuration immediately accessible
Premium User Profile Redesign
Complete overhaul of the user profile page with a premium "Obsidian Lux" design aesthetic:
New Premium Components
- Profile Hero: Animated header with security score ring, avatar upload, profile completion bar, and contextual action buttons
- Premium Sidebar: Glassmorphism navigation with profile stats, security tips, and smooth tab transitions
- Dashboard Tab: Account overview with stat cards, security checklist, recent activity feed, and quick actions
- Security Tab: Security center with 2FA management, session controls, and security score visualization
- Personal Info Tab: Enhanced form with cascading location selectors (Country → State → City)
Design Features
- Dark zinc backgrounds with amber/gold accent gradients
- Glassmorphism effects with subtle transparency
- Animations throughout
- Responsive design for all screen sizes
- Security score ring visualization around avatar
Location Selector Integration
- Country, state and city selectors on the profile form
- Cascading selection with automatic reset (changing country resets state and city)
- Consistent dark theme styling across all selectors
Conditional UI Based on Settings
- KYC-related UI elements now respect the KYC status setting:
- KYC badge on profile hero hidden when KYC disabled
- "Upgrade KYC" button hidden when KYC disabled
- "KYC Level" stat card hidden when KYC disabled
- "KYC Verification" checklist item hidden when KYC disabled
- Removed share profile functionality (no public profile page exists)
Smart Action Buttons
- Profile hero action buttons now show contextually based on current tab:
- Settings button: Visible on Overview and Profile tabs (navigates to Security)
- Edit Profile button: Visible on Overview and Security tabs (navigates to Profile)
- Prevents redundant navigation buttons when already on the target tab
Fixed
KYC Document Type Toggle Not Saving
- Fixed the KYC Level Builder not persisting identity document types (Passport, Driver's License, National ID, Residence Permit, Other Government-Issued ID) after they were toggled on or off and saved
Binary Trading Transaction Type Error
- Fixed binary trading order completions (WIN/LOSS) failing with "Type must be one of the valid transaction types". The original operation type is preserved for auditing
Menu Visibility Based on Settings
- Fixed binary trading menu items staying in user navigation when binary trading is disabled in settings
- Fixed admin panel menu items for binary and blog disappearing when the feature was disabled, so administrators can still manage settings for a disabled feature
- Fixed menu visibility not reflecting saved settings at all in some installations
2FA Settings Display
- Fixed SMS 2FA, Email 2FA, and Authenticator App 2FA settings not showing when the master 2FA toggle was enabled
- Fixed conditional fields elsewhere in settings failing to display based on their parent setting