/**
 * SDK Iframe Message Types
 * Shared types cho SDK Iframe và Game Bridge
 */
export declare const SDK_MESSAGE_TYPES: {
    readonly SDK_INIT: "SDK_INIT";
    readonly SDK_PUSH_DATA: "SDK_PUSH_DATA";
    readonly SDK_CHECK_ANSWER: "SDK_CHECK_ANSWER";
    readonly SDK_GET_RESULT: "SDK_GET_RESULT";
    readonly SDK_RETRY_SYNC: "SDK_RETRY_SYNC";
    readonly SDK_READY: "SDK_READY";
    readonly SDK_DATA_READY: "SDK_DATA_READY";
    readonly SDK_ANSWER_RESULT: "SDK_ANSWER_RESULT";
    readonly SDK_SYNC_STATUS: "SDK_SYNC_STATUS";
    readonly SDK_SYNC_ERROR: "SDK_SYNC_ERROR";
    readonly SDK_FINAL_RESULT: "SDK_FINAL_RESULT";
    readonly SDK_ERROR: "SDK_ERROR";
};
export type SdkMessageType = typeof SDK_MESSAGE_TYPES[keyof typeof SDK_MESSAGE_TYPES];
/** SDK_INIT - Khởi tạo SDK */
export interface SdkInitPayload {
    mode: 'preview' | 'live' | 'dev';
    game_code: string;
    assignment_id?: string | number;
    student_id?: string;
    api_base_url?: string;
    auth_token?: string;
}
/** SDK_PUSH_DATA - Push data (preview mode) */
export interface SdkPushDataPayload {
    data: any[];
    completed_question_ids?: Array<{
        id: string;
        result: 0 | 1;
    }>;
}
/** SDK_CHECK_ANSWER - Check đáp án */
export interface SdkCheckAnswerPayload {
    question_id: string;
    choice: any;
    time_spent?: number;
}
/** SDK_READY - SDK sẵn sàng */
export interface SdkReadyPayload {
    mode: 'preview' | 'live' | 'dev';
    game_code: string;
}
/** SDK_DATA_READY - Data đã sẵn sàng (sanitized) */
export interface SdkDataReadyPayload {
    items: any[];
    total_questions: number;
    completed_count: number;
    resume_data?: Array<{
        id: string;
        result: 0 | 1;
    }>;
}
/** SDK_ANSWER_RESULT - Kết quả verify local */
export interface SdkAnswerResultPayload {
    question_id: string;
    correct: boolean;
    score: number;
    synced: boolean;
}
/** SDK_SYNC_STATUS - Đã sync server OK */
export interface SdkSyncStatusPayload {
    question_id: string;
    synced: true;
    server_result?: {
        correct: boolean;
        score: number;
    };
}
/** SDK_SYNC_ERROR - Lỗi sync server */
export interface SdkSyncErrorPayload {
    question_id: string;
    error: string;
    error_code?: number;
    retryable: boolean;
}
/** SDK_FINAL_RESULT - Kết quả cuối cùng */
export interface SdkFinalResultPayload {
    score: number;
    total: number;
    correct: number;
    wrong: number;
    synced: boolean;
    details: Array<{
        question_id: string;
        choice: any;
        correct: boolean;
        synced: boolean;
        time_spent?: number;
    }>;
}
/** SDK_ERROR - Lỗi chung */
export interface SdkErrorPayload {
    code: string;
    message: string;
    details?: any;
}
export interface SdkMessage<T = any> {
    type: SdkMessageType;
    payload: T;
    timestamp: number;
    request_id?: string;
}
export declare function createSdkMessage<T>(type: SdkMessageType, payload: T, requestId?: string): SdkMessage<T>;
export declare function isSdkMessage(data: any): data is SdkMessage;
//# sourceMappingURL=types.d.ts.map