This document describes the user interface system for configuring workflow blocks. Block configuration UI consists of interactive components (sub-blocks) that allow users to set parameters, manage credentials, define schemas, and configure deployment settings for each block in a workflow.
The Block Configuration UI system renders interactive configuration panels for workflow blocks. Each block type (Agent, Router, Tool, etc.) defines a set of sub-blocks — individual configuration fields like text inputs, dropdowns, code editors, or credential selectors. These sub-blocks are displayed both:
WorkflowBlock showing current values.The system handles value persistence via useSubBlockValue, real-time synchronization, and specialized input types for complex data structures like Knowledge Base filters or Variable assignments.
Sources: apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/hooks/use-sub-block-value.ts:1-25, apps/sim/blocks/types.ts1-435
Diagram: Block Configuration UI Architecture
The system has three main layers:
VariablesInput apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/variables-input/variables-input.tsx:78-84 or FieldFormat apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/starter/input-format.tsx:92-105 display specialized controls.useSubBlockStore manages current values, while useSubBlockInput apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/hooks/use-sub-block-input.ts:1-20 provides helpers for field-level state and tag selection.Sources: apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/hooks/use-sub-block-input.ts:1-20, apps/sim/stores/workflows/subblock/store.ts1-100 apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/variables-input/variables-input.tsx:87-89
The ToolInput component is the primary interface for configuring tool-based blocks. It dynamically renders parameters based on the tool's definition and visibility rules.
Parameters are filtered and displayed based on their visibility attribute (e.g., user-only, user-or-llm, hidden) apps/sim/tools/params.ts136-154
getToolParametersConfig resolves UI component configurations (like short-input, dropdown, or credential-selector) from the block registry for each tool parameter apps/sim/tools/params.ts221-232resolveCanonicalMode and buildCanonicalIndex apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tool-input/tool-input.tsx:97-115.ToolCredentialSelector renders a dropdown of existing credentials or a "Connect" button for new OAuth flows apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tool-input/tool-input.tsx:39-39.useWorkflowState to render an inputMapping UI apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tool-input/tool-input.tsx:121-135.Sources: apps/sim/tools/params.ts221-232 apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tool-input/tool-input.tsx:121-180, apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tool-input/components/tools/credential-selector.tsx:1-50
The UI supports a variety of specialized input components tailored for different block functionalities.
The InputMapping component allows users to map data from the current workflow to the input fields of a selected child workflow.
extractInputFieldsFromBlocks to find the trigger block of the target workflow and extract its inputFormat apps/sim/lib/workflows/input-format.ts20-29workflowId from the store or preview context to fetch the target workflow's state via useWorkflowState apps/sim/hooks/queries/workflows.ts57-65The VariablesInput component manages the assignment of workflow variables within a block.
string, number, boolean, json, and file[] apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/variables-input/variables-input.tsx:29-29.TagDropdown to allow inserting dynamic references (e.g., {{block.output}}) into variable values apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/variables-input/variables-input.tsx:187-195.Sources: apps/sim/lib/workflows/input-format.ts20-77 apps/sim/hooks/queries/workflows.ts57-65 apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/variables-input/variables-input.tsx:29-29
The UI manages the transition of workflows into deployed agents or tools, alongside the necessary credentials.
When a tool requires authentication, the UI triggers an OAuth connection flow.
ToolCredentialSelector checks for available credentials for the given serviceId apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/tool-input/tool-input.tsx:39-39./api/oauth endpoints).The Copilot and UI can check deployment status using specialized tools:
Diagram: Deployment and Credential Entity Interaction
Sources: apps/sim/lib/copilot/orchestrator/tool-executor/deployment-tools/manage.ts26-115 apps/sim/lib/copilot/orchestrator/tool-executor/deployment-tools/deploy.ts21-69 apps/sim/hooks/queries/workflows.ts57-65
The BlockMenu component provides a context-sensitive menu for blocks on the canvas.
The menu dynamically disables items based on user permissions (userCanEdit), block state (locked), or parent status (isParentLocked, isParentDisabled) apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/block-menu/block-menu.tsx:99-106.
Sources: apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/block-menu/block-menu.tsx:70-135, apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/block-menu/block-menu.tsx:191-202
Refresh this wiki