Skip to content

SCORM rules for Claude Code, Codex and Cursor: what to put in CLAUDE.md or AGENTS.md

Updated 26 October 2026

Quick answer

Give the agent a short SCORM section in the instructions file it reads at the start of every task. Then it doesn't write SCORM code from memory, which is where AI-built courses go wrong.

The rules to paste

Put this in the agent's instructions file, as it is or with your own pass mark and file names. It assumes the course folder holds scorm.js from the packaging guide and the test from the Playwright guide.

AGENTS.md or CLAUDE.md
## SCORM: this course is uploaded to an LMS

- Standard: SCORM 1.2. imsmanifest.xml (at the top of the course folder) and the code
  must both be SCORM 1.2.
- Every call to the LMS goes through scorm.js. Don't write other code that calls the
  LMS API, and don't change scorm.js.
- Use only these names and values:
  - Status: cmi.core.lesson_status = completed, incomplete, passed or failed.
  - Score: cmi.core.score.min = 0, cmi.core.score.max = 100, then cmi.core.score.raw =
    a whole number from 0 to 100 (a percentage, never "80%" or points).
  - Set the score, then the status, then call scorm.save().
- Call scorm.start() once, when index.html opens. Send nothing after scorm.finish().
- The course is one page, index.html. Show its other screens inside that page; don't
  make separate HTML pages that each load scorm.js.
- Keep the learner's place in cmi.suspend_data (under 4,096 characters), saved with
  scorm.save(). Never in localStorage, sessionStorage or cookies.
- Every file the course uses is in the course folder. Nothing from CDNs, font
  services or other sites.
- After every change, run: npx playwright test
  If it fails, fix the course. Never change the test to make it pass.
- To package: zip the contents of the course folder, not the folder itself.

Building in a chat (ChatGPT, Claude, Claude Design) rather than with a coding agent? Paste the same rules at the start of the conversation and attach scorm.js; leave out the line about running the test.

Why each rule is there

  • One version, in the manifest and the code. A 2004 manifest over 1.2 code means the course never connects. Alder catches it as MANIFEST-012.
  • One script for the LMS. Agents mix SCORM 1.2 and 2004 names, and the LMS silently refuses them. A fixed script and a short list of names leave nothing to guess: the names each version accepts.
  • Start once, finish last, one page. A second start is refused, and data sent after the finish is dropped. Separate HTML pages end the session each time the learner moves on.
  • Score as a percentage, then the status. “80%” and points are refused; a score with no passed or failed leaves the result up to each LMS: sending a score.
  • The place in suspend_data, not the browser. Browser storage stays on one computer. SCORM 1.2 only guarantees 4,096 characters: the limit.
  • No outside files. Agents reach for CDNs and font services. Some LMSs, company networks and offline players block them.
  • Run the test; never change it. An agent told only to “make the tests pass” may change the test. Saying which side to fix keeps the test honest.
  • Zip the contents. A zip with the folder inside it is rejected by LMSs: “imsmanifest.xml not found”.

Where the file goes

  • Claude Code reads CLAUDE.md (or .claude/CLAUDE.md) in the project when it starts (Claude Code docs).
  • Codex reads AGENTS.md files from the top of the repository down to the folder it works in, before it does anything (OpenAI's docs).
  • Cursor reads AGENTS.md as plain markdown, or rules files in .cursor/rules (Cursor's docs).

Using more than one? Keep the rules in AGENTS.md and point Claude Code at it, since CLAUDE.md can import another file:

CLAUDE.md
# CLAUDE.md
@AGENTS.md

Check what the agent built (free)

The agent's test runs in seconds on every change; Alder is the check before upload; your LMS's test area is the last one.

Three checks for a course an AI agent buildsFirst, on every change, the agent runs the automated test with a pretend LMS, which takes seconds. Second, before you upload, you drop the zip into Alder, which checks the zip layout and the manifest and plays the course in its test player. Third, before learners see it, you launch it in your LMS's test area, the only test of that LMS's own rules.1. ON EVERY CHANGEThe agent runs the automatedtest with a pretend LMS.Seconds. The agent fixes what fails.2. BEFORE YOU UPLOADYou drop the zip into Alder:layout, manifest, test player.A minute. Free, nothing uploaded.3. BEFORE LEARNERS SEE ITLaunch it in your LMS's testarea, as a learner would.The only test of your LMS's own rules.
Three checks, from the one the agent runs to the one only your LMS can give.
  1. Drop the zip into Alder

    Open Alder and drop the zip the agent made. It checks the zip layout and the manifest, including the version match. It won't recognize the agent as an authoring tool, and says so; the general checks still run.

  2. Play it and press “I’m done”

    Click “Launch the course”, go through it, and press “I’m done”. If the agent's code never connected, Alder says so first:

    Alder's Must fix card: the course never connects to the LMS, so nothing is recorded. How to fix it: check that you uploaded the LMS (SCORM 1.2) version, not a web publish, and that the launch file loads the course's SCORM code.
    What Alder shows when a course never calls the LMS (its SCORM 1.2 probe, closed untouched).
  3. Give the findings back to the agent

    Each finding names the call and says how to fix it. Paste it into the agent's chat, or save the log with “Download log for your LMS admin” and give it the file.

Still not working?