Skip to main content
The Agent node brings AI into your workflows using large language models (LLMs). It processes prompts with dynamic data from previous nodes, supports structured JSON outputs, maintains conversation memory across executions, and can connect to MCP servers for extended capabilities.

When to use

  • Analyze and extract insights from enterprise data (invoices, contracts, support tickets)
  • Generate summaries, recommendations, or classifications based on workflow data
  • Transform unstructured text into structured JSON for downstream processing
  • Build conversational workflows that maintain context across multiple interactions
  • Extend agent capabilities with MCP servers for external tool access
Configure your LLM API keys under Organization > Settings before using the Agent node.

Input parameters

Core configuration

Model
dropdown
required
Select the AI model to process prompts. Supports models from OpenAI (GPT-4o, GPT-4.1, GPT-5), Google (Gemini 2.0, Gemini 2.5), and Anthropic (Claude 3.5, Claude 3.7, Claude Opus 4).
User Prompt
text area
required
The input text or question to send to the AI model. Supports dynamic variables from previous nodes using {{variable}} syntax.
System Prompt
text area
Instructions that define the agent’s behavior, role, and response style. Sets context before processing the user prompt.
Structured Output
code editor
JSON schema that enforces a specific output format from the agent. When defined, the agent returns responses matching this schema structure.
Structured Output Schema Example:
{
  "name": "analysis_result",
  "strict": true,
  "schema": {
    "type": "object",
    "properties": {
      "summary": {
        "type": "string",
        "description": "Brief summary of the analysis"
      },
      "confidence_score": {
        "type": "number",
        "description": "Confidence level from 0 to 1"
      },
      "categories": {
        "type": "array",
        "items": { "type": "string" },
        "description": "Relevant categories identified"
      }
    }
  }
}

MCP servers

MCP Servers
code editor
Configure Model Context Protocol servers to extend the agent’s capabilities with external tools and data sources.
MCP Server Configuration Example:
[
  {
    "name": "WeatherMCP",
    "url": "https://api.weather.com/v3/weather/daily",
    "headers": {
      "Content-Type": "application/json"
    },
    "query_params": {
      "apiKey": "your_api_key"
    }
  }
]

Memory

Enable memory to maintain conversation context across multiple agent interactions within a workflow or across workflow executions.
Store Chat History
boolean
Enable to save conversation history for multi-turn interactions.
Chat History Identifier
string
Unique identifier to group related conversations. Use dynamic variables to create user-specific or session-specific histories.
Recent Messages to Include
number
Number of previous messages to include in the agent’s context. Default: 10

Output

The node output structure is determined by the Structured Output schema you define. If no schema is specified, the agent returns a text response. Example Output (with structured schema):
{
  "summary": "The vendor invoice contains 3 line items totaling $15,420.00",
  "confidence_score": 0.95,
  "categories": ["procurement", "accounts_payable", "vendor_management"]
}
Error Response:
{
  "status": "Errored",
  "node_id": "20",
  "node_name": "Agent",
  "body": "No API Key is provided for LLM Node, Please provide API Key in Org Settings"
}

Adding to your workflow

1

Add the Agent node

In the workflow editor, click Add Node and select Agent from the utility nodes section.
2

Select a model

Choose an AI model from the dropdown. Different models have varying capabilities, speed, and cost characteristics.
3

Configure prompts

Enter the User Prompt with your query or instruction. Use {{variable}} syntax to include data from previous nodes. Optionally add a System Prompt to define the agent’s behavior.
4

Define structured output (optional)

If you need the response in a specific JSON format, define a JSON schema in the Structured Output field.
5

Configure MCP servers (optional)

Add MCP server configurations to extend the agent’s capabilities with external tools.
6

Enable memory (optional)

Click Enable under Memory to maintain conversation history. Configure the Chat History Identifier and Recent Messages to Include.
7

Test the node

Click the Run tab to execute a test and verify the agent’s response.

Examples

Extract key information from an SAP purchase order and classify it for routing.Configuration:
FieldValue
Modelopenai/gpt-4o
User PromptAnalyze this SAP purchase order and extract key details: {{sap_po_response}}
System Prompt:
    You are a procurement analyst. Extract purchase order details and classify by urgency and department. Be concise and accurate.
Structured Output:
    {
      "name": "po_analysis",
      "strict": true,
      "schema": {
        "type": "object",
        "properties": {
          "po_number": { "type": "string" },
          "vendor_name": { "type": "string" },
          "total_amount": { "type": "number" },
          "currency": { "type": "string" },
          "urgency": { "type": "string", "enum": ["low", "medium", "high", "critical"] },
          "department": { "type": "string" },
          "requires_approval": { "type": "boolean" }
        }
      }
    }
Output:
    {
      "po_number": "4500012345",
      "vendor_name": "Acme Industrial Supplies",
      "total_amount": 24500.00,
      "currency": "USD",
      "urgency": "high",
      "department": "Manufacturing",
      "requires_approval": true
    }
Automatically categorize and prioritize incoming support tickets.Configuration:
FieldValue
Modelanthropic/claude-3.7-sonnet
User PromptClassify this support ticket: {{netsuite_case.description}}
System Prompt:
    You are a support ticket classifier. Analyze the ticket content and determine category, priority, and suggested routing. Use only the predefined categories.
Structured Output:
    {
      "name": "ticket_classification",
      "strict": true,
      "schema": {
        "type": "object",
        "properties": {
          "category": { 
            "type": "string", 
            "enum": ["billing", "technical", "account", "feature_request", "general"] 
          },
          "priority": { 
            "type": "string", 
            "enum": ["low", "medium", "high", "urgent"] 
          },
          "sentiment": { 
            "type": "string", 
            "enum": ["positive", "neutral", "negative", "angry"] 
          },
          "route_to": { "type": "string" },
          "summary": { "type": "string" }
        }
      }
    }
Output:
    {
      "category": "billing",
      "priority": "high",
      "sentiment": "negative",
      "route_to": "billing_team",
      "summary": "Customer disputing invoice charges for Q4 services"
    }
Create a human-readable summary of payment batch status.Configuration:
FieldValue
Modelgoogle/gemini-2.5-flash
User PromptSummarize this payment batch for the finance team: {{tipalti_batch_response}}
System Prompt:
    You are a finance assistant. Create clear, actionable summaries of payment batches. Highlight any issues or items requiring attention.
Structured Output:
    {
      "name": "payment_summary",
      "strict": true,
      "schema": {
        "type": "object",
        "properties": {
          "batch_id": { "type": "string" },
          "total_payments": { "type": "number" },
          "total_amount": { "type": "number" },
          "successful": { "type": "number" },
          "failed": { "type": "number" },
          "pending_review": { "type": "number" },
          "executive_summary": { "type": "string" },
          "action_items": { 
            "type": "array", 
            "items": { "type": "string" } 
          }
        }
      }
    }
Output:
    {
      "batch_id": "BATCH-2024-0142",
      "total_payments": 47,
      "total_amount": 128450.00,
      "successful": 44,
      "failed": 2,
      "pending_review": 1,
      "executive_summary": "Payment batch 94% successful. 2 failures due to invalid bank details, 1 payment pending compliance review.",
      "action_items": [
        "Contact vendor VEND-892 to update bank account information",
        "Contact vendor VEND-1204 to verify routing number",
        "Review payment to VEND-445 for compliance approval"
      ]
    }
Build a multi-turn conversation that maintains context across interactions.Configuration:
FieldValue
Modelopenai/gpt-4.1
User Prompt{{user_message}}
Store Chat HistoryEnabled
Chat History Identifier{{user_id}}_support_session
Recent Messages to Include10
System Prompt:
    You are a helpful enterprise support assistant. You have access to the user's account information and can help with integration questions. Maintain context from previous messages in the conversation.
Conversation Flow:Turn 1:
  • User: “I’m having trouble with my SAP integration”
  • Agent: “I can help with SAP integration issues. Could you describe what specific problem you’re experiencing?”
Turn 2:
  • User: “The purchase orders aren’t syncing”
  • Agent: “I see you’re having PO sync issues. Let me check a few things. Are you seeing any error messages in the workflow logs?”
Turn 3:
  • User: “Yes, it says authentication failed”
  • Agent: “Based on our conversation, it sounds like your SAP credentials may have expired. You can update them under Settings > Credentials > SAP. Would you like me to guide you through the process?”

Troubleshooting

ProblemSolution
No API Key providedConfigure LLM API keys under Organization > Settings.
Invalid API keyVerify the API key is correct and has not expired. Regenerate if needed.
Rate limit exceededCheck your LLM provider’s rate limits. Consider using a different model or adding delays between requests.
ProblemSolution
Response doesn’t match schemaReview your structured output schema for errors. Ensure property types and constraints are valid JSON Schema.
Empty or incomplete responseCheck if the prompt is clear and provides sufficient context. Verify input variables are resolving correctly.
Timeout errorsReduce prompt complexity or use a faster model variant. Check if the model is experiencing high load.
ProblemSolution
Conversation history not persistingVerify Store Chat History is enabled and Chat History Identifier is consistent across executions.
Agent losing contextIncrease Recent Messages to Include value. Check if the identifier is unique per conversation.
Unexpected context in responsesVerify the Chat History Identifier is creating separate histories for different users or sessions.
ProblemSolution
MCP server connection failedVerify the server URL is correct and accessible. Check authentication headers and query parameters.
Tool not availableEnsure the MCP server exposes the required tools. Review server documentation for available capabilities.
Use a Custom Code node before the Agent node to prepare and format complex input data for better prompt quality.

Next steps

Transform node

Process agent outputs with JSONata.

Rule node

Add conditional logic based on agent responses.

Loop node

Process multiple items with the agent.

What is MCP?

Understand how agents interact with enterprise systems.