Generate and View Personal Referral Code
Peer mentors are on the front lines of member recruitment, regularly meeting with individuals who could benefit from organization membership. This story provides a dedicated screen where a peer mentor can instantly access their personal referral code in both text and QR code format, ready to share during any interaction. The QR code should be large and high-contrast enough to be scanned easily in various lighting conditions, with the text code as a fallback. The screen should load quickly since recruitment opportunities are spontaneous.
User Story
Acceptance Criteria
- Given a peer mentor opens the referral code screen, when the screen loads, then their unique alphanumeric referral code is displayed prominently in large readable text
- Given a peer mentor views the referral code screen, when the QR code is rendered, then it is large enough (minimum 200x200px equivalent) and high-contrast enough to be scanned with a standard phone camera from 30cm distance
- Given a peer mentor's referral code screen is open, when the peer mentor taps the copy button, then the referral code is copied to clipboard and a confirmation toast is shown
- Given the device is offline, when a peer mentor opens the referral code screen, then the previously cached referral code and QR code are displayed with an offline indicator
- Given a screen reader is active, when a peer mentor navigates the referral code screen, then all elements have correct semantic labels and the QR code has an accessible description with the text code
Business Value
Referral codes are the primary mechanism for tracking recruitment attribution and incentivizing peer mentors to actively recruit. Without a frictionless way to access and share codes, recruitment will not happen organically. This directly supports organizational growth and ties peer mentor activity to measurable recruitment outcomes, which is critical for reporting to funders like Bufdir.
Components
- Referral Code Screen ui
- Referral Code Service service
- Referral Code Repository data
- QR Code Generator infrastructure
- Deep Link / OAuth Redirect Handler infrastructure