Certificate Repository
Component Detail
Data Layer
low complexity
backend
0
Dependencies
3
Dependents
1
Entities
0
Integrations
Description
Data access layer for the certifications table, providing CRUD operations and query methods for certification records. Handles all persistence for peer mentor certificates including status transitions, expiry dates, and linkage to users and courses. Supports bulk queries needed for coordinator oversight screens and expiry batch checks.
certificate-repository
Responsibilities
- Persist certificate issuance, renewal, and revocation records
- Query certificates by user, organization, course, and status
- Support bulk expiry queries for scheduled expiry evaluation jobs
- Maintain audit trail of status transitions (issued, renewed, revoked, expired)
- Provide paginated certificate listings for admin oversight
Interfaces
createCertification(data)
updateCertification(id, data)
revokeCertification(id, reason)
getCertificationById(id)
getCertificationsByUser(userId)
getCertificationsByOrganization(orgId)
getExpiringCertifications(withinDays)
getExpiredCertifications()
countActiveCertifications(orgId)
getCertificationHistory(userId)
Relationships
Dependents (3)
Components that depend on this component