POST /scorm/packages/:packageId/launch

POST /scorm/packages/:packageId/launch

Use production SCORM API URL - can be overridden with env var for local development localhost:3001'; SCORM API key (for production - should be stored securely, per-tenant ideally) POST /api/scorm/packages/[packageId]/launch - Launch SCORM session Use service role client to bypass RLS for profile lookup Verify authentication with Clerk Get user profile for user_id (Supabase UUID) Parse request body (may include session_id for resuming) Body is optional - will use profile.id as user_id Use user_id from body if provided, otherwise use profile.id Forward request to SCORM API Add API key if configured (for production SCORM API) Check if it's a connection error

Endpoint

POST /scorm/packages/:packageId/launch

Authentication

This endpoint requires authentication. Include your authentication token in the request headers.

Path Parameters

ParameterTypeDescription
packageIdstringPath parameter

Error Responses

Status CodeError CodeDescription
401HTTP_401Unauthorized
404HTTP_404Not Found
503HTTP_503Error
503HTTP_503Error
500HTTP_500Internal Server Error

Example Request

curl -X POST "https://api.allurelms.com/scorm/packages/packageId-value/launch" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}'