--- title: "Query Component" slug: "query-component" tags: ["module-builder"] status: "update" updated: 2026-10-26T19:35:35Z published: 2026-10-26T19:35:35Z canonical: "docs.unqork.io/query-component" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.unqork.io/llms.txt > Use this file to discover all available pages before exploring further. # Query Component The Query Component runs a Query Smart Component definition inside a module. It becomes available in the component tray after a Query Smart Component is created and shared. Creators use it to retrieve and store query results. ## Adding to a Module The Build Agent places a Query Component automatically when Creators ask it to add a smart query to a module. It wires the component to the Query Smart Component definition it creates, maps the input parameters, and places the component on the canvas. Creators can also add a Query Component manually. When a Query Smart Component is Public, it displays as a preset item in the **QUERY** section of the Config View component tray. Dragging a preset onto the canvas places a Query Component pre-configured to run that definition. > [!NOTE] > The **QUERY** section in the component tray carries the UnqorkAI sparkle icon to indicate that Query Components are powered by UnqorkAI. The section displays only when UnqorkAI is enabled for the workspace. Each item in the section uses the Smart Components icon and represents a single shared Query Smart Component. > **How to read settings tables** > > > The tables below describe each configurable option as it displays in the UnqorkAI platform. Values are formatted as follows: `inline code` — a value to type exactly as shown | **Bold** — a value selected from a drop-down, radio button, tab, or choice chip | **ON**/**OFF** — toggle state | ✓ — checkbox checked | ☐ — checkbox unchecked The **Property ID** (`key`) and **Description** fields appear in the component panel header above the settings sections. ## Configuration The **Configuration** section maps module data to the query definition's input parameters. Each row binds a parameter declared in the Query Smart Component to a module component that supplies its value. | Setting | Field | Type | Default | Description | | --- | --- | --- | --- | --- | | Query Inputs | `dataInputObject` | Table | — | Maps each query input parameter to a module component by alias. Add a row for each parameter the query definition declares. | ## Outputs The **Outputs** section defines where the component stores the data the query returns. The query definition's output schema determines the shape of the results slot. | Setting | Field | Type | Default | Description | | --- | --- | --- | --- | --- | | Outputs | `dataOutputObject` | Table | — | Maps the query's return data to module component property IDs. The results slot stores data from a successful query run. The error slot stores a code, message, and optional errors detail when the query fails. | ## Triggers | Setting | Field | Type | Default | Description | | --- | --- | --- | --- | --- | | Trigger Type | `triggerType` | Radio button | **Manual** | Sets when the query runs. Options include: **Manual** or **Watch**. | | ↳ Set Debounce | `debounceSetting` | Number input | `500` | The delay in milliseconds before the query runs after an input changes. Visible when **Trigger Type** is set to **Watch**. Accepts values of `0` or greater. | | Triggered By | — | Read-only display | — | Displays the components that trigger this Query Component. Trigger wiring is set on the triggering component, not here. | | Post Trigger | `postTrigger` | Property ID | — | The component to trigger after the query runs successfully. | | Error Trigger | `errorTrigger` | Property ID | — | The component to trigger when the query returns an error. | --- **Changelog** | Date | Change | | --- | --- | | 2026-10-26 | Corrected the Trigger Type control type from drop-down to radio button. Split an overlong sentence in the introduction and removed a trailing clause. | | 2026-10-08 | Terminology: "shared (marked as discoverable)" → "Public"; See Also link text "Smart Queries" → "Query Smart Components". | | 2026-09-15 | Restructured settings — removed General Settings and Actions Settings headings (not real UI sections); Property ID and Description noted as panel header fields; Configuration, Outputs, Triggers are collapsible sections; fixed two broken See Also paths. | | 2026-08-21 | Article created. | Also known as Unqork Users, or Designer Users; is anyone who is inside the Unqork platform. A query lets you retrieve, access, manipulate, and delete data in a database. A Property ID is the unique field ID used by Unqork to track and link components in your module. Enter inputs components and actions you want the component to perform.. Enter outputs components and actions you want the component to perform. Schema is a declarative language that defines the structure, content, and constraints of the data. A JavaScript property is a member of an object that associates a key with a value. A JavaScript object is a data structure that stores a collection of properties. Deteremines how the component triggers. The Number data type accepts integer or floating point values. The number data type does not use quotes around numerical values. Triggers activate another component when certain requirements are met. Trigger types include Concurrent, Post, and Error. Some components do not have the ability to trigger others. The Post Trigger value fires after a component has completed its action. For example, post triggering a component to display the data received from a Plug-In component's API call. The UI (user interface) is a device's end-user interaction and communication point. It can include display screens, keyboards, and mouse. It is also how a user interacts with your application.