Parent Portal
Linking parents to students and what they see in OptiLearn
OptiLearn surfaces a parent dashboard that shows each linked child's courses, recent grades, upcoming assignments, live class attendance, gamification, and certificates. The portal pulls from the LMS for course/grade data and from OptiCRM for the parent↔child relationship.
How parents are linked to students
OptiLearn does not own the parent↔student graph. The relationship lives in OptiCRM as ContactStudentLink, which records:
- The parent Contact (
contactType: CONTACT_PARENT) - The student (the corresponding Student record)
- A relation label (
FATHER,MOTHER,GUARDIAN,OTHER) - An
isPrimaryflag
OptiLearn reads this relationship through two OptiCRM endpoints:
| Direction | Endpoint | Used by |
|---|---|---|
| Parent → children | GET /api/lms/parent/[id]/children | Parent dashboard, child selector |
| Student → parents | GET /api/lms/student/[id]/parents | Notification fan-out |
Both are cached no-store — newly linked children must appear immediately.
Linking workflow (admin side)
Linking happens in OptiCRM, not OptiLearn:
- Open the student's profile in OptiCRM
- Add a parent Contact (or link an existing one)
- Pick the relation
- Mark
isPrimaryif applicable - Save
Within seconds the parent will see the student in their OptiLearn dashboard on next refresh.
Verifying the link
To confirm a parent can see a student in OptiLearn:
- Have the parent log in to OptiCRM (
<slug>.opticrm.app) - Open
learn.opticrm.app— they should land on the parent dashboard - Their child(ren) appear in the header switcher
- Selecting a child loads the read-only overview
If the child doesn't appear:
- Confirm the parent Contact has
contactType: CONTACT_PARENTin OptiCRM - Confirm
ContactStudentLinkexists between the two records - Check OptiLearn server logs for
[opticrm] getParentChildrenerrors — usually an auth or slug issue
What parents see
Parents have their own dashboard layout (/parent) with a header child-switcher when more than one child is linked. The per-child overview is read-only and includes:
- Courses — all active + completed enrollments with progress, last accessed, completion status
- Recent grades — last 10 graded submissions with score, percentage, pass/fail
- Upcoming assignments — next 5, scoped to the child's active enrollments
- Live classes — attended this month, missed this month, and the next 5 upcoming
- Gamification — current streak, longest streak, total points, badges
- Certificates — every issued certificate (with PDF link)
Parents cannot:
- Submit assignments or quizzes on behalf of the child
- Edit notes or bookmarks
- See another parent's children
- Access the leaderboard / catalogue / forum (those are student-only)
Notifications
Parents have their own notification preference set (4 keys):
| Key | Trigger |
|---|---|
PARENT_CHILD_GRADED | Child's assignment graded |
PARENT_CHILD_LOW_GRADE | Child's average drops below passing threshold |
PARENT_CHILD_ABSENT | Child missed a live class they registered for |
PARENT_WEEKLY_DIGEST | Weekly progress summary |
Fan-out: when a relevant student event fires, OptiLearn calls getParentsForStudent(childContactId) and dispatches one notification per linked parent through the same NotificationService pipeline as student notifications. Each parent's own preferences apply.
Parents see and edit their preferences at /settings/notifications like any other user.
Multi-child households
Households with multiple children get one row per child in the dashboard switcher. Notifications are per-child — a parent with two children gets two PARENT_WEEKLY_DIGEST emails on Sunday morning, one per child.
Related
- Parent API — endpoint reference
- OptiCRM Integration — the
/api/lms/parent/*and/api/lms/student/*/parentscontracts - Notifications System — fan-out engine