Skip to content

Toolbox search - Connect to external API for large template libraries #7837

Description

@JaneSjs

Implement an API so toolbox search can query an external backend and show matching templates (for catalogs with 100+ items).

Usage scenario
A company has 500+ approved question templates in a backend. The Creator shows a small default toolbox.
The user types nps in the toolbox search → the app calls the API → matching templates appear under Templates → the user drags NPS Question onto the survey. When the user clears the search, API templates disappear and the standard toolbox is shown again.

Requirements:

  • Add a public toolbox API with a search(query): Promise<IQuestionToolboxItem[]> callback.
  • Integrate it into the built-in toolbox search UI (debounce, min query length, ignore/cancel stale requests).
  • Register API results as dynamic toolbox items in a dedicated category (localizable, e.g. toolboxCategories.templates).
  • Do not require the full catalog in memory — only matched items from the server are added per query.
  • When external search is enabled, allow the search box to stay visible regardless of toolbox item count.
  • Support hybrid mode: keep filtering built-in items locally while merging API results.
  • Default on clear search: remove dynamic API items and restore the standard toolbox.
  • Default on new query: replace previous API results (no accumulation).
  • Fix internal toolbox/search lifecycle so addItem / filtering does not drop hidden built-in items from actions.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions