Recruitment Service
Component Detail
Service Layer
low complexity
backend
2
Dependencies
1
Dependents
3
Entities
0
Integrations
Description
Backend service responsible for generating short-lived referral tokens per peer mentor and recording attribution when a referred individual completes registration within the same organization. Integrates with the organization labels system for dynamic benefit content and notifies on referral conversion.
recruitment-service
Responsibilities
- Generate unique referral tokens per peer mentor via Next.js API route
- Resolve deep links and attribute completed registrations to the referring peer mentor
- Retrieve and cache membership benefit content from organization labels
- Expose referral statistics (count, conversion rate) per peer mentor
Interfaces
generateReferralToken(userId: string, organizationId: string): Promise<string>
getReferralLink(userId: string): Promise<string>
recordReferralConversion(referralToken: string, newUserId: string): Promise<void>
getReferralStats(userId: string): Promise<ReferralStats>
getMembershipBenefitsContent(organizationId: string): Promise<BenefitContent[]>
validateReferralToken(token: string): Promise<boolean>
Relationships
Dependencies (2)
Components this component depends on
Related Data Entities (3)
Data entities managed by this component