Patch and upload Rise courses to LMS platforms
npm install @package-uploader/coreUpload and manage Rise course packages on LMS platforms with a web UI and optional auto-patching.
- Web UI: Browse folders, upload courses, manage documents and shared links
- Course upload: Upload SCORM, cmi5, xAPI packages with drag-and-drop
- Thin Pack links: Auto-create LMS thin pack links on upload
- Version management: Upload new versions to existing documents
- Auto-patching: Automatically patch courses with @patch-adams/core
- Feedback widget: Inject feedback forms into patched courses
``bashInstall globally
npm install -g @package-uploader/core
Open http://localhost:3002 to access the web UI.
$3
`bash
npx @package-uploader/core server
`Web UI Features
$3
- Navigate folder hierarchy
- View documents with metadata
- Expand documents to see details and shared links
- Create thin pack and shared links
- Copy launch URLs to clipboard$3
- Drag-and-drop file upload
- Auto-create LMS Thin Pack link (toggle, default ON)
- Auto-create Shared Link (toggle, default OFF)
- Custom link names with auto-generated slugsConfiguration
$3
`bash
Required - Bravais LMS connection
UPLOADER_BASE_URL=https://your-lms.bravais.com
UPLOADER_USERNAME=your-username
UPLOADER_PASSWORD=your-passwordOptional - Server settings
PORT=3002
DEFAULT_FOLDER_ID=12345Optional - CORS for split-domain deployment
CORS_ORIGINS=https://company.com,https://www.company.comOptional - Auto-patching (requires @patch-adams/core)
PATCH_ENABLED=true
PATCH_REMOTE_DOMAIN=https://cdn.example.com/rise-overrides
`$3
Install the optional peer dependency to enable auto-patching:
`bash
npm install @patch-adams/core @patch-adams/plugin-feedback
`When enabled, uploaded courses are automatically patched with:
- LRS bridge for xAPI tracking
- Feedback widget (configurable)
- Custom CSS/JS injections
Split-Domain Deployment
For deploying the UI on a main domain with the API on a subdomain:
$3
`bash
cd ui
VITE_API_URL=https://api.company.com/api npm run build
Deploy ui/dist/ to your static host
`$3
`bash
CORS_ORIGINS=https://company.com,https://www.company.com
`Programmatic Usage
`typescript
import { PackageUploaderClient } from '@package-uploader/core';const client = new PackageUploaderClient({
baseUrl: 'https://your-lms.bravais.com',
username: 'your-username',
password: 'your-password',
});
// Upload a course
const result = await client.uploadCourse(fileBuffer, 'course.zip', {
folderId: '12345',
title: 'My Course',
});
// Create a thin pack link
await client.createSharedLink(result.documentId, {
name: 'My Course - LMS Thin Pack',
isPublic: true,
isForThinPackage: true,
});
`API Reference
$3
`typescript
client.listFolders()
client.getFolder(folderId)
client.listSubfolders(folderId)
`$3
`typescript
client.listDocuments({ folderId, filterText })
client.getDocument(documentId)
client.getDocumentVersions(documentId)
`$3
`typescript
client.listSharedLinks(documentId)
client.createSharedLink(documentId, {
name: 'Link Name',
isPublic: true,
isForThinPackage: true,
})
`$3
`typescript
client.uploadCourse(buffer, filename, { folderId, title })
client.uploadVersion(buffer, filename, { documentId, note })
`CLI Commands
`bash
Start the web server
package-upload-serverUpload a course (CLI)
package-upload upload course.zip --folder 12345Upload a new version
package-upload update course.zip --document-id 67890
`Development
`bash
Clone and install
git clone https://github.com/npmbuilder/package-uploader.git
cd package-uploader
npm installBuild UI
npm run build:uiBuild TypeScript
npm run buildRun server in development
npm run server
``MIT