/** * Learning Event Tracking * * Unified interface for tracking learning activity across all CREATE SOMETHING properties. * Events flow to the LMS API and contribute to the learner's hermeneutic journey. * * Canon: The infrastructure disappears; only the unified journey remains. */ export type PropertyId = 'io' | 'space' | 'ltd' | 'agency'; export interface LearningEventMetadata { [key: string]: string | number | boolean | null | undefined; } export interface LearningEvent { property: PropertyId; eventType: string; metadata?: LearningEventMetadata; } export interface LearningEventResponse { success: boolean; eventId?: string; error?: string; } /** * Track a learning event * * Sends the event to the LMS API. Requires the user to be authenticated * (cookies are sent automatically). * * @example * ```typescript * await trackLearningEvent({ * property: 'io', * eventType: 'paper_completed', * metadata: { * paperId: 'code-mode-hermeneutic-analysis', * timeSpent: 1800, * reflected: true * } * }); * ``` */ export declare function trackLearningEvent(event: LearningEvent): Promise; /** * Batch track multiple learning events * * Useful for tracking multiple related actions (e.g., completing a multi-part exercise). * Events are sent sequentially to maintain order. */ export declare function trackLearningEvents(events: LearningEvent[]): Promise; /** * Property-specific event tracking helpers */ export declare const io: { paperStarted: (paperId: string) => Promise; paperCompleted: (paperId: string, timeSpent?: number) => Promise; paperReflected: (paperId: string, reflectionLength: number) => Promise; }; export declare const space: { experimentStarted: (experimentId: string) => Promise; experimentCompleted: (experimentId: string, timeSpent?: number) => Promise; challengeSubmitted: (challengeId: string, passed: boolean) => Promise; }; export declare const ltd: { canonReviewed: (principleId: string) => Promise; principleAdopted: (principleId: string, context?: string) => Promise; }; export declare const agency: { methodologyApplied: (methodologyId: string, projectId?: string) => Promise; projectCompleted: (projectId: string, methodologiesUsed: string[]) => Promise; };