# 7.1 LMS Integration

User Type: **Corporate**
Source: *Mi Digital Academy - Education CRM Features Document*

---

## 7.1 LMS Integration

### 7.1.1 SCORM/xAPI Content
**What it does:** Lets the organization publish its existing SCORM and xAPI packages to the platform so employees can complete them alongside native courses.

**Sub-features:**
- Upload SCORM 1.2 / 2004 packages
- xAPI (Tin Can) statement capture
- Completion reporting from packages
- Package versioning
- Available on web and mobile
- Event logging (viewed)
- Audit logging of the SCORM/xAPI content

**Corporate User Journey:**
1. The admin opens Integrations → Content → Upload Package.
2. The admin uploads a SCORM package.
3. The package is validated and published.
4. Employees complete it; completion is reported.
5. The admin uploads a new version when the content changes.
6. The admin opens Profile → "Activity" and confirms the events are recorded.

**Rules & Edge Cases:**
- Packages are validated before publishing; invalid packages are rejected.
- A new version does not reset completions of the old version.
- Events (viewed) are logged with the account and the timestamp.
- The SCORM/xAPI content is audit-logged with the account and the timestamp.

### 7.1.2 LMS Connector
**What it does:** Connects the platform to an external LMS so course completions flow both ways: external completions count toward compliance, and platform assignments can be pushed out.

**Sub-features:**
- Connector setup (endpoint, credentials)
- Inbound completion sync
- Outbound assignment push
- Connection health monitor
- Available on web and mobile
- Event logging (viewed)
- Audit logging of the LMS connector

**Corporate User Journey:**
1. The admin opens Integrations → LMS Connector.
2. The admin configures the endpoint and credentials.
3. The connection test passes.
4. External completions flow in and count toward compliance.
5. Platform assignments are pushed out.
6. The admin opens Profile → "Activity" and confirms the events are recorded.

**Rules & Edge Cases:**
- Inbound completions are deduplicated by activity ID.
- A failed sync retries with exponential backoff for 24 hours.
- Events (viewed) are logged with the account and the timestamp.
- The LMS connector is audit-logged with the account and the timestamp.

### 7.1.3 Content Sync
**What it does:** Keeps the platform's course catalog in sync with the external LMS catalog: new courses appear, retired courses are flagged, and metadata updates propagate.

**Sub-features:**
- Catalog sync (add / update / retire)
- Metadata propagation (title, duration, skills)
- Sync schedule (hourly / daily)
- Sync log with conflicts
- Available on web and mobile
- Event logging (viewed)
- Audit logging of the content sync

**Corporate User Journey:**
1. The admin opens Integrations → Content Sync.
2. The admin sets the sync schedule to daily.
3. New external courses appear in the catalog.
4. Retired courses are flagged, not deleted.
5. The sync log shows any conflicts.
6. The admin opens Profile → "Activity" and confirms the events are recorded.

**Rules & Edge Cases:**
- Retired courses keep their completion history.
- Conflicts are resolved in favor of the source of truth set by the admin.
- Events (viewed) are logged with the account and the timestamp.
- The content sync is audit-logged with the account and the timestamp.
