A comprehensive task-based rewards platform built for the African market, enabling users to earn money by completing simple tasks, referring friends, and participating in gamification features.
- Task System: Browse and complete various tasks (surveys, app installs, social media engagement)
- CB Points Wallet: Earn and manage CB Points (1 CB Point = 1 Ksh)
- M-Pesa Withdrawals: Direct withdrawal to M-Pesa accounts
- Referral System: Earn Ksh 5 per referral + milestone bonuses
- VIP Tiers: 6 levels (Starter β Diamond) with increasing reward multipliers
- Spin & Win: Daily wheel spin for instant CB Points rewards
- Real-time Notifications: Stay updated on earnings and approvals
- Daily Login Streaks: Bonus rewards for consistent engagement
- User Management: View and manage all users, adjust VIP levels
- Task Approval: Review and approve business-submitted tasks
- Withdrawal Management: Approve/reject withdrawal requests
- Task Completion Review: Verify task completions with proof
- Platform Settings: Configure rewards, bonuses, and system parameters
- Analytics Dashboard: Track platform metrics and user activity
- Task Creation: Submit tasks for user completion
- Campaign Management: Track task performance and completions
- Wallet System: Manage business credits for task rewards
- Analytics: View completion rates and user engagement
- Frontend: React 19 + TypeScript + Tailwind CSS 4
- Backend: Node.js + Express + tRPC 11
- Database: MySQL with Drizzle ORM
- Authentication: Built-in OAuth system
- Deployment: Manus Platform
users- User accounts with VIP levels and roleswallets- CB Points balance trackingtransactions- All financial transactionstasks- Available tasks from businessestask_completions- User task submissionswithdrawals- Withdrawal requests and approvalsreferrals- Referral tracking and bonusesvip_levels- VIP tier definitions and benefitsspin_rewards- Spin & Win reward configurationsbusinesses- Business/advertiser accountsnotifications- User notificationslogin_logs- Security and analytics trackingfraud_logs- Fraud detection recordssettings- Platform configuration
- Node.js 22+
- MySQL database
- Manus Platform account
-
Clone the repository
git clone <repository-url> cd cashbucks
-
Install dependencies
pnpm install
-
Set up environment variables Configure in Management UI β Settings β Secrets or
.envfile:DATABASE_URL=mysql://user:password@host:port/database JWT_SECRET=your_jwt_secret # Add M-Pesa credentials when ready (see INTEGRATION_GUIDE.md) -
Initialize database
pnpm db:push
-
Seed initial data
pnpm exec tsx scripts/seed.mjs -
Start development server
pnpm dev
- Complete tasks
- Earn CB Points
- Request withdrawals
- Refer friends
- Spin & Win
- View VIP progress
- Create tasks
- Manage campaigns
- Track completions
- Manage wallet
- Full platform access
- User management
- Task approval
- Withdrawal processing
- System configuration
| Level | Name | Tasks Required | Earnings Required | Reward Multiplier | Withdrawal Cooldown |
|---|---|---|---|---|---|
| 0 | Starter | 0 | 0 | 1.0x | 14 days |
| 1 | Bronze | 10 | 500 | 1.1x | 10 days |
| 2 | Silver | 50 | 2,500 | 1.25x | 7 days |
| 3 | Gold | 150 | 7,500 | 1.5x | 5 days |
| 4 | Platinum | 300 | 15,000 | 1.75x | 3 days |
| 5 | Diamond | 500 | 25,000 | 2.0x | 1 day |
- Base Bonus: Ksh 5 per successful referral
- Milestone Bonus: Ksh 100 for every 50 referrals
- Leaderboard: Top referrers featured on platform
- Lifetime Tracking: All referrals tracked permanently
- Cooldown: 24 hours between spins
- Rewards: 5 to 200 CB Points
- Probability-based: Configured reward distribution
- History Tracking: View all spin results
- 2FA Support: Two-factor authentication ready
- Fraud Detection: Automated suspicious activity logging
- Login Tracking: All login attempts recorded
- Rate Limiting: Prevent abuse on critical endpoints
- Role-based Access: Strict permission controls
- User Metrics: Track engagement, earnings, and activity
- Task Performance: Monitor completion rates and quality
- Financial Tracking: All transactions logged and auditable
- Referral Analytics: Track referral performance and bonuses
- VIP Progression: Monitor user tier advancement
All integrations are currently in mock mode. See INTEGRATION_GUIDE.md for implementation details.
- M-Pesa: Withdrawal processing (placeholder)
- SMS (Africa's Talking): OTP and notifications (placeholder)
- Firebase: Push notifications (optional)
- AdSense: Monetization (optional)
The platform uses tRPC for type-safe API communication. All endpoints are defined in server/routers.ts.
auth.*- Authentication and session managementuser.*- User profile and dashboardwallet.*- Balance and transactionstasks.*- Task browsing and completionvip.*- VIP tier informationreferrals.*- Referral systemspin.*- Spin & Win gamenotifications.*- User notificationsadmin.*- Admin management (requires admin role)business.*- Business portal (requires business role)
# Run TypeScript checks
pnpm tsc
# Test database connection
pnpm db:push
# Seed test data
pnpm exec tsx scripts/seed.mjs-
Save Checkpoint
Create checkpoint via Management UI or CLI -
Publish
Click "Publish" button in Management UI -
Configure Domain
Settings β Domains β Add custom domain (optional)
Ensure all secrets are configured in Management UI β Settings β Secrets:
- Database credentials
- JWT secret
- M-Pesa credentials (when ready)
- SMS API keys (when ready)
cashbucks/
βββ client/ # Frontend React application
β βββ src/
β β βββ pages/ # Page components
β β βββ components/ # Reusable UI components
β β βββ lib/ # Utilities and tRPC client
β β βββ App.tsx # Main app and routing
βββ server/ # Backend Node.js application
β βββ routers.ts # tRPC API endpoints
β βββ db.ts # Database queries and helpers
β βββ _core/ # Framework infrastructure
βββ drizzle/ # Database schema and migrations
β βββ schema.ts # Table definitions
βββ scripts/ # Utility scripts
β βββ seed.mjs # Database seeding
βββ todo.md # Feature tracking
βββ INTEGRATION_GUIDE.md # Integration documentation
βββ README.md # This file
This is a custom-built platform. For modifications:
- Update
todo.mdwith new features - Implement changes in appropriate files
- Test thoroughly
- Create checkpoint before deploying
Proprietary - All rights reserved
For platform issues or questions:
- Check
INTEGRATION_GUIDE.mdfor integration help - Review
todo.mdfor planned features - Contact platform administrator
Built with:
- React + TypeScript
- tRPC for type-safe APIs
- Tailwind CSS for styling
- Drizzle ORM for database
- Manus Platform for deployment
Version: 1.0.0
Last Updated: 2024
Status: Production Ready (pending external API integrations)