Nodes

Nodes are the building blocks of MindedJS flows - discrete processing units that handle different aspects of your agent's workflow.

Common Node Properties

All nodes require these fields:

  • name (string, required): Unique identifier for the node

  • type (NodeType, required): The node type (see table below)

  • displayName (string, required): Human-readable label shown in the editor

Node Types Overview

Node Type (NodeType)

Purpose

Description

Entry Points

Start flows from various sources

LLM Processing

Generate responses using language models

Actions

Execute external functions and APIs

Flow Control

Route and organize flow logic

Flow Control

Jump to specific nodes or subflows

Automation

AI-powered web page interactions

Trigger Nodes

Trigger nodes are entry points that start your flows and initialize them with memory and messages.

Trigger Nodes Properties

  • type (NodeType, required): Always trigger

  • triggerType (string, required): The type of trigger to use. See the table below for details.

triggerType

Description

webhook

Triggered by HTTP webhook calls

app

Triggered by external app events (e.g., Zendesk ticket created)

schedule

Triggered on a cron schedule

Webhook Trigger (webhook)

Triggered by HTTP requests to the agent's webhook endpoint.

Properties:

  • autoTrigger (boolean, optional): Auto-execute when testing flows in the UI editor

  • defaultPayload (string, optional): Default JSON payload for testing in the UI editor

App Trigger (app)

Triggered by external application events.

Schedule Trigger (schedule)

Triggered on a cron schedule.

Properties:

  • cronExpression (string, required): Cron expression (e.g., 0 9 * * * for daily at 9 AM)

  • timezone (string, optional): Timezone for the schedule (defaults to UTC)

Trigger Implementation

Handle triggers in your agent code:

Prompt Nodes

Prompt nodes process input through LLM to generate intelligent responses or invoke tools. Prompt nodes are commonly used to notify and collect information.

Use Cases

  • Notify the user about the result of a previous node.

  • Collect information from the user.

  • Invoke (scoped) tools.

Prompt Nodes Properties

  • type: (NodeType, required) Always promptNode

  • prompt (string, required): The prompt to be sent to the LLM. The prompt is an instruction for what AI message to generate or a (scoped) tool to invoke. This is not general instruction for what the agent should do (e.g. "wait for x").

  • humanInTheLoop (boolean, optional): When true, pauses execution after this node for human input before continuing. Use this property only if you need to gather an input from the user. Usually combined with a promptCondition edge to allow for iterative processing over human input.

  • canStayOnNode (boolean, optional): When true, allows the node to route back to itself for iterative processing. Usually combined with humanInTheLoop: true to allow for iteration over human input.

  • llmConfig (boolean, optional): Used to customize the LLM used by the prompt node. Leave empty to use the default LLM configured.

  • sendAiMessage (boolean, optional): Default: true. When true emits AgentEvents.AI_MESSAGE event to send the response to the user. When false, the AI response is processed internally without sending to the user. Set to false for internal calculations, reasoning, or decision-making logic that shouldn't be visible to users.

Handle AI message (sendAiMessage)

Prompt nodes usually result in an AI message being sent to the user. Use the AgentEvents.AI_MESSAGE event to route the message according to user requirement (e.g., send email, send a Slack message, update Jira ticket, etc.).

In development mode (playground), the message is automatically shown in the chat regardless of the message handler.

Context

  • Prompt nodes automatically have access to previous nodes' output as context.

  • You can inject dynamic values into prompts using placeholders that reference memory, environment variables, tool outputs, and system values.

Available Placeholders

Memory Placeholders

Access values from the agent's memory state using {memory.propertyName}:

Nested objects:

Array access:

Complex objects:

When referencing entire objects or arrays, they will be serialized to JSON:

Tool/Node Output Placeholders

Access output from previous tool or operator nodes using {tools.NodeName.propertyName}:

With operator/browser task nodes:

Environment Variable Placeholders

Access environment variables using {env.VARIABLE_NAME}:

Common use cases:

System Placeholders

Access built-in system values using {system.propertyName}:

Placeholder Behavior

  • String values: Inserted directly into the prompt

  • Numbers and booleans: Converted to strings

  • Objects and arrays: Serialized to JSON format

  • Undefined values: If a placeholder references a non-existent property, it returns the original placeholder unchanged (e.g., {memory.nonexistent} stays as {memory.nonexistent})

  • Null values: Rendered as "null"

Complete Example

Limitations

  • Prompt nodes can not save information to memory directly. Rather the user & agent messages are stored in the messages array of the state object. Making user's input available to the next prompt nodes or tools in the form of input schema.

  • Image recognition is only supported when a user attaches an image to the message. If you need to extract information from an image, use a tool with agent.llm to process the image. Return the result in the tool response so following prompt nodes can use it.

  • By default, prompt nodes send a message to the user. Set sendAiMessage: false if you want internal processing without user-facing output.

Prompt examples

  • "Draft a professional email to the merchant requesting verification of the dispute"

  • "Ask the user for their contact information (name, email, phone)"

Common Prompt Patterns

Extract Information from User

Use humanInTheLoop: true and canStayOnNode: true with promptCondition edges for iterative information gathering:

Notify User

Use standard prompt nodes with stepForward edges for one-way notifications:

Custom LLM Configuration

Provide a custom LLM configuration to the prompt node using the llmConfig property with the following fields:

  • name: (required) name of the LLM to use, must be one of ChatOpenAI, AzureChatOpenAI, MindedChatOpenAI.

  • properties: (optional) LLM configuration properties

Internal Processing (No User Message)

To process logic internally without sending a message to the user, set sendAiMessage: false:

Use cases for sendAiMessage: false:

  • Internal calculations and reasoning: Determining refund amounts, calculating discounts, analyzing data

  • Decision-making logic: Evaluating conditions before taking actions

  • Information extraction: Processing and structuring data for subsequent nodes

  • Pre-processing: Preparing inputs for tools or other nodes

The AI response is added to conversation history and available to subsequent nodes, but not sent to the user.

Tool Nodes

Tool nodes execute functions to perform actions like API calls, database queries, or external integrations.

Tool Nodes Properties

  • type (NodeType, required): Always tool

  • toolName (string, required): The name of the registered tool function to execute. Must match a tool defined in your agent's tools configuration.

  • prompt (string, optional): The prompt to be sent to the LLM to hint how tool parameters should be inferred.

  • parameters (object, optional): The parameters to pass to the tool function. Tool parameters values are inferred by an LLM during runtime. You can override specific input parameters directly to ensure deterministic values. Parameters support placeholder syntax to inject dynamic values from memory, environment variables, other tool outputs, and system values. See Context for more details.

Tool Implementation

Tools are registered in your agent code. See Tools for implementation details.

Junction Nodes

Junction nodes provide flow control without processing, useful for organizing routing logic.

Basic Junction

Routing Example

Jump To Nodes

Jump To nodes provide direct navigation to specific nodes, enabling flow transitions and subflow execution.

Jump To Node Properties

  • type (NodeType, required): Always jumpToNode

  • targetNodeId (string, required) The name of the node to jump to. The target node is resolved across all loaded flows at runtime. If the target node doesn't exist, the flow will error.

Basic Jump To Node

Cross-Flow Navigation

Jump To nodes enable navigation between flows. Target nodes can exist in different flow files, and state is preserved during jumps:

Browser Task Nodes

Browser task nodes allow your agent to interact with web pages using AI-powered automation.

Browser Task Properties

  • type (NodeType, required): Always browserTask

  • prompt (string, required): The prompt to be sent to the LLM to instruct the browser task.

Basic Browser Task

Custom Model

Specify which AI model to use (default: gpt-5.2):

Best Practices

  • Use descriptive names: technical-support-specialist not agent-1

  • Keep prompts focused: Define specific roles and context, avoid overly broad prompts

  • Always include displayName: Required for prompt nodes, recommended for all nodes

Next Steps

Last updated