Embedded analytics SDK API
    Preparing search index...

    Function CreateQuestion

    • Parameters

      • Optionalprops: CreateQuestionProps
        • OptionalentityTypeFilter?: EntityTypeFilterKeys[]

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

        • OptionalinitialSqlParameters?: ParameterValues

          Initial values for the SQL parameters.

        • OptionalisSaveEnabled?: boolean

          Whether to show the save button.

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

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

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

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

        • Optionalplugins?: MetabasePluginsConfig
        • OptionaltargetCollection?: SdkCollectionId

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

        • OptionalwithDownloads?: boolean

          Enables the ability to download results in the interactive question.

      Returns Element

      Use <InteractiveQuestion questionId="new" /> instead.