Caregiver Service
Component Detail
Service Layer
low complexity
mobile
1
Dependencies
1
Dependents
3
Entities
0
Integrations
Description
Business logic layer for managing caregiver and next-of-kin records. Handles CRUD operations against the REST API, enforces permission checks (only coordinators and assigned peer mentors may access), and validates caregiver form data including relationship type enum constraints.
caregiver-service
Responsibilities
- Perform CRUD operations for caregiver records via REST API
- Validate caregiver form inputs and relationship type enum
- Enforce role-based access (coordinator or assigned peer mentor only)
- Map API responses to local caregiver models
Interfaces
getCaregiversForContact(contactId): Future<List<Caregiver>>
createCaregiver(contactId, data): Future<Caregiver>
updateCaregiver(caregiverId, data): Future<Caregiver>
deleteCaregiver(caregiverId): Future<void>
validateCaregiverData(data): ValidationResult
Relationships
Related Data Entities (3)
Data entities managed by this component