On-Chain Referral Service
Updated: 8th March 2025
RuBaRu's Refer-2-Earn incentive model, part of the Creator-Consumer Incentive Program (CCIP), is designed as a fully on-chain, event-driven, auto-scalable referral service to efficiently track and reward user-driven growth. The system follows a modular, distributed architecture ensuring scalability, decentralization, and real-time processing.
High-Level Architecture:
Mother Registry Canister (Orchestrator)
The central coordinator managing referral tracking and reward computation & distribution.
Maintains a ledger of referral relationships and dynamically provisions Data Satellite Canisters based on user demand.
Data Satellite Canisters (Sharded Storage & Processing)
Distributed storage and computation layer handling referral tracking at scale.
Ensures load balancing by sharding data across multiple canisters to support high throughput.
On-Chain Referral Code System
Generates unique, immutable referral codes directly on-chain.
Integrated into the user signup flow to link referral relationships.
Event-Driven Reward Computation & Distribution
Referral rewards are dynamically computed based on SignUp and Claim referral reward events.
Message events are generated in response to user Signup using referral code, which then trigger automatic reward distribution.
Directly integrated with Wallet Service for real-time, on-chain ledger updates.
User Service & Wallet Service Integration
Provides instant access to referral earnings, transaction history, and leaderboard rankings.
Users can transparently track referral activity and rewards.
By leveraging an event-based, auto-scalable microservices architecture, the on-chain referral service ensures efficient tracking, seamless reward distribution, and scalable user onboarding. The system dynamically scales with user demand, providing high reliability, decentralization, and an optimal user experience.
Last updated