Sync / roster
Bidirectional roster and grade synchronization between PeopleSoft Campus Solutions and Moodle LMS using Moodle Web Services and LTI Advantage for automated enrollment and grade passback.
This integration connects Oracle PeopleSoft Campus Solutions (the system-of-record for student demographics, course sections, and academic standing) with Moodle LMS (the institution's learning management system) via a bidirectional sync layer. The solution exposes PeopleSoft-delivered web services (such as STUDENT_SECTION_DATES and PERSON_BASIC_PERSONAL) and maps them to Moodle's core webservice API, handling user creation, course enrollment, section-to-course mapping, and LTI Advantage Gradebook Services for grade passback.
The primary challenge lies in bridging the semantic gap between PeopleSoft's section-based scheduling model and Moodle's course-based enrollment model—particularly when cross-listed sections, multiple enrollment components, or waitlisted students must be represented correctly in Moodle without creating duplicate accounts or incorrect enrollments. Additionally, Moodle's webservice authentication requires careful token management and role mapping to ensure instructors and students receive appropriate permissions without exposing admin-level access.
A working piece from this integration — no sign-up. The full build handles the edge cases, safeguards, and cutover.
PeopleSoft publishes enrollment events via Integration Broker; a middleware connector transforms them to Moodle Web Services calls.// Moodle Web Services: core_enrol_enrol_users POSThttps://moodle.example.edu/webservice/rest/server.php?wstoken=MOODLE_WS_TOKEN &moodlewsrestformat=json { "enrolments": [ { "roleid": 5, "userid": "EMPLID:{EMPLID}", "courseid": "CRSE_ID:{CRSE_ID}:{STRM}:{CLASS_SECTION}", "timestart": 1735689600, "timeend": 1743811200 } ] } // PeopleSoft Integration Broker Service Operation (PS campus) Service Operation:LMSSYNC_ENROLLMENT_OUT Message:LM_ENROLLMENT_SYNCHandler:OnNotify// PeopleSoft Query — source for enrollment sync SELECT E.EMPLID, E.STRM, C.CRSE_ID, C.CLASS_SECTION, E.CLASS_NBR, E.ENRL_STATUS, E.ENRL_ADD_DT FROM PS_STDNT_ENRL E JOIN PS_CLASS_TBL C ON (C.CLASS_NBR = E.CLASS_NBR AND C.STRM = E.STRM) WHERE E.ENRL_STATUS = 'E' AND C.INSTITUTION = :1 // LTI Advantage Grade Passback — AGSS Claim { "https://purl.imsglobal.org/spec/lti-gs/claim/endpoint": { "lineitem":https://moodle.example.edu/mod/lti/services.php/1/lineitem, "lineitems":https://moodle.example.edu/mod/lti/services.php/1/lineitems}, "https://purl.imsglobal.org/spec/lti-ags/claim/endpoint": { "lineitem": { "scoreMaximum": 100, "label": "CRSE_ID:{CRSE_ID}:{STRM}", "resourceId": "MOODLE_COURSE_ID" }, "results":https://moodle.example.edu/mod/lti/services.php/1/lineitem/-results} }
How we'd take this from discovery to a production-safe cutover — the phases, the canonical mapping, and the edge cases that bite.
Bidirectional synchronization between PeopleSoft Campus Solutions and Moodle LMS requires orchestrating enrollment provisioning via LTI Advantage and grade passback via Moodle Web Services, with PeopleSoft as the system of record. The integration respects PeopleSoft's section-based class model and maps it to Moodle's course structure, using CRSE_ID, CRSE_OFFER_NBR, CLASS_NBR, and STRM as the canonical composite key for section identity.
idnumber as {STRM}-{CRSE_ID}-{CRSE_OFFER_NBR}-{CLASS_NBR}. Run the batch job SSR_CLASS_MTG_PAT nightly to keep the map current. Validate that every active section in the current term has a Moodle counterpart before proceeding.GET /nrps/{context_jid}/memberships on a configurable schedule (recommended: every 15 minutes). For each membership record, upsert the Moodle user (matching email or id from PeopleSoft EMAIL_ADDR) and assign the role (student → roleid=5, instructor → roleid=3, TA → roleid=4).gradereport_user and local_wstemplate services in Moodle. Create a Web Services token scoped to grade write. PeopleSoft delivers final grades via stdnt_enrl / STDNT_CRSE_GRADE fields. Map GRADE_POINTS and CRSE_GRADE_OFF to the Moodle grade item using local_o365_grade_passback or a custom SOAP/REST endpoint. Set sync_on_cron = true in the PeopleSoft integration record.PS_INT_BP_LOG extension). The middleware requeues with exponential backoff (max 3 attempts). Alert on entries older than 48 hours via PeopleSoft Workflow. Log INT_RUN_CNTL_ID and PRCSINSTANCE for audit traceability.SSS_STUDENT_ENRL vs. mdl_user_enrolments) showing matches, orphans, and gaps. Run this for at least two full business cycles before enabling live passback. Require sign-off from the Registrar and LMS administrator.mdl_grade_items and ps_sf_grade_api logs daily.| PeopleSoft Field / Record | Moodle Target | Transform / Logic |
|---|---|---|
PERSON.EMPLID |
mdl_user.idnumber |
Direct map; use EMPLID as idnumber for deterministic matching. Fallback to PERSON.EMAIL_ADDR if EMPLID is empty. |
STRM (Term) |
mdl_course.shortname suffix |
Append {STRM} to shortname; e.g., PSYC-101-001-2241. Strip leading zero from STRM for display consistency. |
CRSE_ID + CRSE_OFFER_NBR + CLASS_NBR + STRM |
mdl_course.idnumber |
Composite key: {STRM}-{CRSE_ID}-{CRSE_OFFER_NBR}-{CLASS_NBR}. Ensure uniqueness via PeopleSoft unique index. |
ENRL_STATUS_CODE in STDNT_ENRL |
mdl_user_enrolments.status |
E → active (enrolled); D/W → suspended; C → deleted. Trigger sync within 15-minute cron cycle. |
STDNT_CRSE_GRADE.GRADE_POINTS |
mdl_grade_grades.finalgrade |
Map via grading scheme; CRSE_GRADE_OFF (letter grade) used for display; GRADE_POINTS (numeric) written to grade item. Apply grade_item.itemtype = 'manual' for passback. |
CLASS_INSTR.EMPLID + INSTR_ROLE |
mdl_role_assignments.roleid |
PI → roleid 3 (editingteacher); TA → roleid 4; GA → roleid 5. Sync instructor assignments on every enrollment batch. |
ACAD_PLAN + ACAD_CAREER |
mdl_enrol.meta_enrol_courseid |
Optionally cross-list into program-specific sections. Use ENRL_ACTION = 'PERM' to trigger meta-enrollment; skip PROV (provisional) enrollments. |
ENRL_STATUS_CODE = 'D'. The middleware must delete the Moodle enrollment AND remove any existing grade row in mdl_grade_grades to avoid a stranded grade after re-enrollment.NAME without changing EMPLID. The middleware must upsert on idnumber, not re-create the user, or duplicate accounts will proliferate in Moodle.CRSE_GRADE_BASIS switches from Letter to Pass/Fail mid-term, the grade scale changes. Moodle's grade item must be updated via grade_item_update before the next passback, or grades will be stored against the wrong scale.mdl_user_enrolments rows and two separate grade entries keyed to the correct CLASS_NBR.9999 or blank require a separate mapping bucket; hard-code these into the configuration table to prevent empty idnumber values.hidden = 1 in Moodle per institutional repeat-policy rules.COUNT(*) of mdl_user_enrolments against STDNT_ENRL filtered by current term; the delta must be zero (allow for W-withdrawn students counted in PeopleSoft but not in Moodle, which is correct). Freeze the integration configuration record (INT_CONFIG_CD) until the first grading cycle completes. Schedule a 48-hour rollback window post-go-live: if more than 5% of grade passback calls fail, or if the reconciliation report shows unmatched grades, re-enable manual entry and re-run the PeopleSoft SCC_SF_GRADE_LOAD batch to restore PeopleSoft as the sole authoritative grade store until the root cause is resolved. Reading the reference is free. Delivering it under liability — with the safeguards that keep production running through the cutover — is what we do.