Embedded analytics SDK API
    Preparing search index...

    Interface BaseInteractiveQuestionProps

    interface BaseInteractiveQuestionProps {
        children?: ReactNode;
        entityTypeFilter?: EntityTypeFilterKeys[];
        initialSqlParameters?: SqlParameterValues;
        isSaveEnabled?: boolean;
        onBeforeSave?: (
            question: undefined | MetabaseQuestion,
            context: { isNewQuestion: boolean },
        ) => Promise<void>;
        onSave?: (
            question: undefined | MetabaseQuestion,
            context: { isNewQuestion: boolean },
        ) => void;
        plugins?: MetabasePluginsConfig;
        questionId: null | SdkQuestionId;
        targetCollection?: SdkCollectionId;
        withDownloads?: boolean;
    }
    Index

    Properties

    children?: ReactNode

    The children of the MetabaseProvider component.s

    entityTypeFilter?: EntityTypeFilterKeys[]

    An array that specifies which entity types are available in the data picker

    initialSqlParameters?: SqlParameterValues

    Initial values for the SQL parameters.

    isSaveEnabled?: boolean

    Whether to show the save button.

    onBeforeSave?: (
        question: undefined | MetabaseQuestion,
        context: { isNewQuestion: boolean },
    ) => Promise<void>

    A callback function that triggers before saving. Only relevant when isSaveEnabled = true

    onSave?: (
        question: undefined | MetabaseQuestion,
        context: { isNewQuestion: boolean },
    ) => void

    A callback function that triggers when a user saves the question. Only relevant when isSaveEnabled = true

    questionId: null | SdkQuestionId

    The ID of the question.
    This is either:

    • The numerical ID when accessing a question link, e.g., http://localhost:3000/question/1-my-question where the ID is 1
    • The entity_id key of the question object. You can find a question's Entity ID in the info panel when viewing a question
    • new to show the notebook editor for creating new questions. isSaveEnabled must be true to allow saving the question
    targetCollection?: SdkCollectionId

    The collection to save the question to. This will hide the collection picker from the save modal. Only applicable to interactive questions.

    withDownloads?: boolean

    Enables the ability to download results in the interactive question.