SDK Overview & Installation
The Woolf SDK enables real-time tracking of student activities within your LMS, ensuring compliance with Woolfโs Academic Management System (AMS). The SDK automates the capture of educational events - such as resource consumption, attendance, submissions, and gradingโand synchronizes them with Woolfโs accreditation workflows.
Key Capabilities
- Tracks resource consumption across PDFs, videos, markup, and other media
- Captures assignment submissions and meeting attendance with verifiable evidence
- Synchronizes grades and feedback from teachers with AMS records
- Signs events in real time to support compliance and verification
- Provides secure, extensible access via a modern JavaScript client
๐ก All events require correct user context. Authorize the SDK using a User Token to track actions reliably.
Supported Environments
The SDK and API work across multiple deployment environments:
| Environment | Env Key | Purpose |
|---|---|---|
university |
env: "university" |
Production environment for live data |
sandbox |
env: "sandbox" |
Testing environment with test tokens and data |
Installation Options
Generating a User Token
Each user must be authenticated using a User Token signed with your College Secret.
Sign JWT on Your Server (Recommended)
You may generate tokens server-side with JSON Web Tokens (JWT). It gives you complete control over token lifetime, revocation, and security.
import jwt from "jsonwebtoken";
const COLLEGE_SECRET = "YOUR_SECRET_KEY";
const token = jwt.sign({
id: "USER_ID",
collegeId: "COLLEGE_ID"
}, COLLEGE_SECRET);
console.log("User Token:", token);
Generate via Woolf API
Alternatively, you may also generate a token using our API endpoint.
โ ๏ธ Tokens generated using API expire after 7 days. For more control, it is recommended to use server-side JWT signing.
๐ Do not expose your College Secret in frontend code. Always sign tokens on the server.
After Initialization
- The
woolf.userobject becomes available for accessing user profile data. - The
woolf.widgetinterface allows programmatic control of onboarding and dashboard flows. - Use methods like
woolf.trackSubmission,trackAttendance,trackGrade, andtrackFeedbackto log events. - The SDK emits a
woolf:createdevent on successful initialization.