> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cognigy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# LLM Prompt

<a href="/release-notes/2026.3"><Badge className="version-badge" color="blue">Updated in 2026.3</Badge></a>

<Frame>
  <img class="image-center" src="https://mintcdn.com/cognigy-15abf2ba/eCWTpPMMSEqv9wTC/_assets/ai/develop/node-reference/services/llm-prompt.png?fit=max&auto=format&n=eCWTpPMMSEqv9wTC&q=85&s=eb8d2aac8186aa9acdd0e64fc6cb193b" alt="LLM Prompt Node" style={{ width: 'auto' }} width="464" height="124" data-path="_assets/ai/develop/node-reference/services/llm-prompt.png" />
</Frame>

## Description

The LLM Prompt Node lets you configure the system prompt for your LLM calls, generating both text and structured content. With this Node, you can also:

* Include tools in your LLM calls.
* Enable image handling.
* Set advanced LLM request options.

Additionally, you can refer to your AI Agent configuration using the [Load AI Agent Node](/ai/agents/develop/node-reference/ai/load-ai-agent).

Before using this Node, set the LLM provider in the [Settings](/ai/agents/develop/gen-ai-and-llms/generative-ai).

## Limitations

* The **Description** and **Enum** fields in the **Parameters** section of an [AI Agent tool](#parameters) don't support CognigyScript.

## Parameters

### Parent Node

<AccordionGroup>
  <Accordion title="Large Language Model">
    The selected **Default** model is the model that you specified in **Settings > Generative AI Settings** of your Project.

    You can select a different model from the list or override the selected model using the Custom Model Options parameter.
  </Accordion>

  <Accordion title="System Prompt">
    The system prompt is the message sent to the LLM to guide its responses. The parameter supports CognigyScript, allowing dynamic content and logic within the prompt. This prompt can work either as the input for completion tasks or as the system message in chat-based interactions, setting context and behavior for the AI Agent.

    Additionally, you can inject the recent conversation into the **System Prompt** field by using these tags:

    * `@cognigyRecentConversation` — the tag is replaced with a string that can contain up to 10 recent AI Agent and 10 user outputs, for example:
      ```text theme={null}
      Bot: agentOutput1
      User: userOutput1
      Bot: agentOutput2
      User: userOutput2
      ```
    * `@cognigyRecentUserInputs` — the tag is replaced with a string that can contain up to 10 recent user outputs, for example:

      ```text theme={null}
      User: userOutput1
      User: userOutput2
      ```

    If you want to access only the last user input, specify the `Text` token in the **System Prompt** field.

    When adding a tag, ensure that you leave a line break before and after the tag, for example:

    ```text theme={null}
    A user had a conversation with a chatbot. The conversation history so far is:
    @cognigyRecentConversation

    Describe the user sentiment in one very short line.
    ```

    Both tags can include an optional turn limit parameter, which is appended to the tag.

    Examples:

    ```typescript theme={null}
    @cognigyRecentConversation:3 // returns the last 3 turns of the conversation.
    @cognigyRecentUserInputs:2 // returns the last 2 user inputs.
    ```
  </Accordion>

  <Accordion title="Advanced">
    | Parameter                  | Type   | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
    | -------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Maximal Tokens             | Slider | The maximum number of tokens to generate in the completion.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
    | Use Single Prompt Mode     | Toggle | Sends a prompt from the **System Prompt** parameter to the model without any conversation context. The **Use Single Prompt Mode** parameter is deactivated by default and doesn't support multi-turn conversations, making it suitable for simple, one-off completions. When the parameter is activated, the **System Prompt** parameter must not be empty. Empty prompts return no data and may produce empty responses or errors depending on the model you use.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
    | Transcript Turns           | Slider | The number of conversation turns to include in the LLM chat completion request. By default, the value is `50`.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
    | Response Format            | Select | Choose the format for the model's output result. You can select one of the following options:<ul><li>**None** — no response format is specified, or do not request with an LLM provider that does not accept any response format or does not support it or could use provider's default in-built response format. This option is selected by default.</li><li>**Text** — the model returns messages in text format.</li><li>**JSON Object** — the model returns messages in JSON format. To use this option, instruct the model to generate JSON via a system or user message in the **Instruction (System Message/Prompt)** field. For example, `Take the user message and return it as JSON in the following format {"message": "THE_MESSAGE"}`. Note that this parameter may not be supported by all LLMs. For more information, refer to the LLM provider's API documentation.</li></ul>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
    | Timeout                    | Number | The maximum number of milliseconds to wait for a response from the LLM provider.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
    | Sampling Method            | Select | Methods:<ul><li>**Temperature** — determines the level of randomness in the generated text. A higher temperature allows for more diverse and creative outputs, while a lower temperature leads to more predictable and consistent outputs with the training data.</li><li>**Top Percentage** — specifies the percentage of the most probable outputs for generation, resulting in more consistent output.</li></ul>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
    | Temperature                | Slider | Define the sampling temperature, which ranges between 0 and 1. Higher values, such as 0.8, make the output more random, while lower values, such as 0.2, make it more focused and deterministic.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
    | Top Percentage             | Slider | Control the Top-p (nucleus) sampling, ranging from 0 to 1. Higher values allow more diverse word choices, while lower values make the output more focused. For example, 0.9 means the model selects from the smallest set of words with a combined probability of 90%.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
    | Presence Penalty           | Slider | Number between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood of talking about new topics.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
    | Frequency Penalty          | Slider | Number between -2.0 and 2.0. The penalty assigns a lower probability to tokens frequently appearing in the generated text, encouraging the model to generate more diverse and unique content.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
    | Use Stops                  | Toggle | Whether to use a list of stop words to let Generative AI know where the sentence stops.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
    | Stops                      | Text   | Up to 4 sequences where the API will stop generating further tokens. The returned text will not contain the stop sequence.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
    | Seed                       | Number | Use this parameter for consistent output when referring to the same LLM Prompt Node multiple times. Specify any integer number, for example, `123`. The number in the Seed field and the prompt in the **Instruction (System Message/Prompt)** field should remain unchanged during subsequent references to the Node.<br />Note that in OpenAI, this parameter is in [Beta](https://platform.openai.com/docs/api-reference/chat/create#chat-create-seed) and is supported only by [certain models](https://cookbook.openai.com/examples/reproducible_outputs_with_the_seed_parameter).                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
    | Include Rich Media Context | Toggle | Controls whether the text from the [Textual Description](/ai/agents/develop/node-reference/basic/say#output-type) field in Say, Question, and Optional Questions Nodes is added to the AI Agent's prompt. This text provides AI Agents with additional information, improving their responses.<br /><br />If you have filled in a **Textual Description** field in other Nodes, this text is added to the prompt as context for rich media, such as Text with Quick Replies. If the **Textual Description** field is empty, the button titles and alt text from the rich media are added to the prompt. By default, the **Include Rich Media Context** parameter is active. When this parameter is inactive, nothing related to the rich media is added to the prompt.<br /><br />**Examples**:<ul><li>If **Textual Description** is filled in:<p>Textual Description: `Select your preferred delivery option: Standard Delivery or Express Delivery`.</p><p>Quick Replies buttons: `Standard Delivery`, `Express Delivery`.</p><p>Context added to the prompt: `Select your preferred delivery option: Standard Delivery or Express Delivery`.</p></li><li>If **Textual Description** is empty:<p>Textual Description: empty.</p><p>Quick Replies buttons: `Standard Delivery`, `Express Delivery`.</p><p>Context added to the prompt: `Standard Delivery`, `Express Delivery`.</p></li><li>If **Include Rich Media Context** is inactive:<p>No information related to the rich media is added to the prompt.</p></li></ul> |
  </Accordion>

  <Accordion title="Storage & Streaming Options">
    | Parameter                     | Type          | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
    | ----------------------------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
    | How to handle the result      | Select        | Determine how to handle the prompt result:<ul><li>**Store in Input** — stores the result in the Input object. To print the prompt result, use the LLM Prompt Result Token in the Say Node or enable the **Output result immediately** option.</li><li>**Store in Context** — stores the result in the Context object. To print the prompt result, use the LLM Prompt Result Token in the Say Node or enable the **Output result immediately** option.</li><li>**Stream to Output** — streams the result directly into the output. This means that the model provides prompts directly into the conversation chat, as soon as a Stream Buffer Flush Token is matched, and you don't need to use the LLM Prompt Result token and Say Node. By default, this result won't be stored in either the Input or the Context. You can change this behavior by activating the **Store Copy in Input** option. Note that streaming may not be supported by all [Cognigy LLM Prompt Node](/ai/agents/develop/gen-ai-and-llms/model-support-by-feature) providers, such as Google<sup>[1](#footnote1)</sup>. If streaming is not supported, enabling the **Store Copy in Input** option will save the result to the Input object.</li></ul> |
    | Input Key to store Result     | CognigyScript | The parameter appears when **Store in Input** is selected. The result is stored in the `promptResult` Input object by default. You can specify another key.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
    | Context Key to store Result   | CognigyScript | The parameter appears when **Store in Context** is selected. The result is stored in the `promptResult` Context object by default. You can specify another key.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
    | Stream Buffer Flush Tokens    | Text Array    | The parameter appears when **Stream to Output** is selected. It defines tokens that trigger the stream buffer to flush to the output. The tokens can be punctuation marks or symbols, such as `\n`.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
    | Stream Buffer Flush Overrides | Text Array    | The parameter appears when **Stream to Output** is selected. It allows using regular expressions (without leading or trailing slashes) to control stream buffer flushing. A trailing `$` is automatically added to match patterns at the end of the buffer. For example, `\d+\.` checks for a number followed by a dot at the end of the string.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
    | Output result immediately     | Toggle        | The parameter appears when you select either **Store in Input** or **Store in Context**. This parameter allows you to output results immediately without using the Say Node and LLM Prompt token.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
    | Store Detailed Results        | Toggle        | The parameter appears when you select either **Store in Input** or **Store in Context**, or when you enable **Store Copy in Input**. This parameter allows you to save detailed results of the LLM's generated output. By default, the result is stored in the `promptResult` object. You can specify another value in the **Context Key for the Result** field to save it in the Context object, or in the **Input Key for the Result** to save it in the Input object. The object contains keys such as `result`, `finishReason`, and `usage`. It may also include `detailedResult` if completion models are used, as well as `firstChunk` and `lastChunk` in some streaming results, depending on the LLM provider.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
    | Store Copy in Input           | Toggle        | The parameter appears when **Stream to Output** is selected. In addition to streaming the result to the output, store a copy in the Input object by specifying a value in the **Input Key to store Result** field.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |

    **Streaming Results**

    In Stream mode, LLM generates tokens and returns them one by one to Cognigy.AI to ensure low-latency responses.
    Cognigy.AI monitors delimiter tokens (Stream Buffer Flush Tokens),
    which serve as markers indicating when to output the token buffer.
    These tokens could be `.`, `!`, `?`, or any other symbols that act as delimiters for complete logical statements.
    When Cognigy.AI detects one of these tokens, it promptly flushes the token buffer into the voice or text chat.

    The preconfigured overrides are listed in the table.

    | Regex                                       | Description                                | Example        |
    | ------------------------------------------- | ------------------------------------------ | -------------- |
    | `\d+\.`                                     | A number followed by a dot.                | `26.08`        |
    | `\b(?:Dr\|Ms\|Mr\|Mrs\|Prof\|Sr\|Jr\|ca)\.` | Common abbreviations followed by a dot.    | `Mr.`          |
    | `\b[A-Z]\.`                                 | A single capital letter followed by a dot. | `M. Smith`     |
    | `\.\.\.`                                    | Three dots used for omission.              | `...`          |
    | `\b.\..\.`                                  | Two-letter abbreviations.                  | `i.e.`, `e.g.` |
  </Accordion>

  <Accordion title="Tool Settings">
    The process of setting up a tool is the same as for the AI Agent Node. See the example in the [AI Agent Tool Settings](/ai/agents/develop/node-reference/ai/ai-agent#child-nodes) section.

    | Parameter       | Type     | Description                                                                                                                                                                                                                                                                                                                         |
    | --------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Tool Choice     | Selector | If supported by your LLM Model, this will determine how tools should be selected by the AI Agent:<ul><li>**Auto** — tools (or none) are automatically selected by the AI Agent when needed.</li><li>**Required** — your AI Agent will always use one of its Tools.</li><li>**None** — your AI Agent won't use a tool.</li></ul>     |
    | Use Strict mode | Toggle   | When the parameter is enabled, strict mode (if supported by the LLM provider) ensures that the arguments passed to a tool call precisely match the expected parameters. Enabling this feature can help prevent errors. However, it may cause a slight delay in the response, especially during the first call after making changes. |
  </Accordion>

  <Accordion title="Image Handling">
    | Parameter            | Type     | Description                                                                                                                                                                                                                                                                                                                                        |
    | -------------------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Process Images       | Toggle   | Enable the AI Agent to read and understand image attachments. Make sure that your LLM provider supports image processing; refer to your provider's documentation. In addition, make sure that attachments are supported by and activated in your Endpoint, for example, Webchat.                                                                   |
    | Images in Transcript | Selector | Configure how images older than the last turn are handled to reduce token usage:{" "}<ul><li>**Minify** — reduces the size of these images to 512x512px.</li><li>**Drop** — excludes the images.</li><li>**Keep** — sends the max size (this option consumes more tokens).</li></ul>{" "}Limitations and token consumption depend on the LLM used. |
  </Accordion>

  <Accordion title="Error Handling">
    | Parameter                      | Type   | Description                                                                                                                                                                                                                                                                                                                                                                                                              |
    | ------------------------------ | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
    | Log to System Logs             | Toggle | Log errors to the system logs. They can be viewed on the [Logs](/ai/agents/test/logs) page of your Project. The parameter is inactive by default.                                                                                                                                                                                                                                                                        |
    | Select Error Handling Approach | Select | You can select one of the Error Handling options:<ul><li>**Stop Flow Execution** — terminate the current Flow execution.</li><li>**Continue Flow Execution** — allow the Flow to continue executing, bypassing the error and proceeding to the next steps.</li><li>**Go to Node** — redirect the workflow to a specific Node in the Flow, which can be useful for error recovery or customized error handling.</li></ul> |
    | Error Message (optional)       | Text   | The parameter appears when **Continue Flow Execution** is selected. Add a message to output if the LLM Prompt Node fails.                                                                                                                                                                                                                                                                                                |
    | Select Flow                    | Select | The parameter appears when **Go to Node** is selected. Select a Flow from the available options.                                                                                                                                                                                                                                                                                                                         |
    | Select Node                    | Select | The parameter appears when **Go to Node** is selected. Select a Node from the available options.                                                                                                                                                                                                                                                                                                                         |
  </Accordion>

  <Accordion title="Custom Options">
    These options let you use parameters that aren't included in the LLM Prompt Node or overwrite set configurations.

    | Parameter              | Type | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | Example                                                                      |
    | ---------------------- | ---- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------- |
    | Custom Options         | JSON | Set custom parameters to the LLM configuration. You can set individual parameters as well as entire functions. These parameters customize the behavior of the model, such as adjusting `temperature`, `top_k`, or `presence_penalty`. This field overrides the parameters set in the LLM Prompt Node. To view the full list of available parameters for your model, refer to the LLM provider's API documentation, for example, [OpenAI](https://platform.openai.com/docs/api-reference/chat/create) or [Azure OpenAI](https://learn.microsoft.com/en-us/azure/ai-services/openai/). | `{ "model": "gpt-4o", "temperature": 0.7, "max_tokens": 4000 }`              |
    | Custom Request Options | JSON | Set custom parameters to customize the request to the LLM provider. These parameters override the configurations set in this Node. For example, setting a `{ "stream": true }` parameter overrides the **Output result immediately** option. For more information, refer to the LLM provider's API documentation.                                                                                                                                                                                                                                                                    | `{ "stream": true }`, `{ "headers": { "Authorization": "Bearer <token>" } }` |

    **Forcing Model Versions**

    You can force the LLM Prompt Node to use a specific model version by including it in the Custom Options.
    This means that the LLM Prompt Node will use the specified version of the language model instead of the default or any other available versions. This allows for more control over the behavior of the LLM Prompt Node, ensuring it uses the desired model version for generating prompts or responses.

    You can use models from any LLM provider supported by Cognigy, including those not yet directly integrated.
    However, you can only replace a model with another from the same provider.

    Let's consider an example with Anthropic:
    You can force the LLM Prompt Node to use the model version `claude-opus-4-1-20250805`, despite the LLM resource defaulting to the `claude-opus-4-5-20251101` model:

    1. [Create an Anthropic LLM resource](/ai/agents/develop/gen-ai-and-llms/providers/anthropic) for Claude, for example, `claude-opus-4-5-20251101`.
    2. Create a Flow and add an LLM Prompt Node to it.
    3. In the LLM Prompt Node, select the model `claude-opus-4-5-20251101` from the **Large Language Model** list.
    4. In the **Custom Model Options** field, add `{ "model": "claude-opus-4-1-20250805" }` to force the use of the `claude-opus-4-1-20250805` model.
    5. Click **Save Node**.

    The LLM Prompt Node now utilizes the `claude-opus-4-1-20250805` model.

    Below, you'll find documentation for supported models:

    * [Aleph Alpha Models](https://docs.aleph-alpha.com/)
    * [Anthropic Models](https://docs.anthropic.com/claude/docs/models-overview)
    * [Azure OpenAI](https://learn.microsoft.com/en-us/azure/ai-services/openai/concepts/models)
    * [OpenAI Models](https://platform.openai.com/docs/models)
  </Accordion>

  <Accordion title="Debugging Settings">
    When using the Interaction Panel, you can trigger two types of debug logs. These logs are only available when using the Interaction Panel and are not intended for production debugging. You can also combine both log types.

    | Parameter                      | Type          | Description                                                                                                                                                                                                                                                                                                                                                                                            |
    | ------------------------------ | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
    | Show Token Count               | Toggle        | Sends a debug message containing the input, output, and total token count. The message appears in the Interaction Panel when [debug mode](/ai/agents/test/interaction-panel/chat#debug-mode) is enabled. Cognigy.AI uses the GPT-3 tokenizer algorithm, so actual token usage may vary depending on the model used. The parameter is inactive by default.                                              |
    | Log System Prompt & Completion | Toggle        | Sends a debug message containing the system prompt sent to the LLM provider and the subsequent completion. The message appears in the Interaction Panel when [debug mode](/ai/agents/test/interaction-panel/chat#debug-mode) is enabled. The parameter is inactive by default.                                                                                                                         |
    | Log Tool Definitions           | Toggle        | Sends a debug message containing information about the configured AI Agent tools. The message appears in the Interaction Panel when [debug mode](/ai/agents/test/interaction-panel/chat#debug-mode) is enabled. The parameter is inactive by default.                                                                                                                                                  |
    | Log LLM Latency                | Toggle        | Sends a debug message containing key latency metrics for the request to the model, including the time taken for the first output and the total time to complete the request. The message appears in the Interaction Panel when [debug mode](/ai/agents/test/interaction-panel/chat#debug-mode) is enabled. The parameter is inactive by default.                                                       |
    | Send request logs to Webhook   | Toggle        | Sends the request sent to the LLM provider and the subsequent completion to a webhook service, including metadata, the request body, and custom logging data. With this parameter, you can use a webhook service to view detailed logs of the request to the LLM. The parameter is inactive by default.                                                                                                |
    | Webhook URL                    | CognigyScript | Sets the URL of the webhook service to send the request logs to.                                                                                                                                                                                                                                                                                                                                       |
    | Custom Logging Data            | CognigyScript | Sets custom data to send with the request to the webhook service.                                                                                                                                                                                                                                                                                                                                      |
    | Condition for Webhook Logging  | CognigyScript | Sets the condition for the webhook logging.                                                                                                                                                                                                                                                                                                                                                            |
    | Webhook Headers                | Input fields  | Sets the headers to send with the request to the webhook service. Use the **Key** and **Value** fields to enter a header. The **Value** field supports CognigyScript. After entering the header key, new empty **Key** and **Value** fields are automatically added, in case you need to add more headers. Alternatively, you can click **Show JSON Editor** and add input examples in the code field. |
  </Accordion>
</AccordionGroup>

### Child Nodes

#### Tool

Tools are child Nodes of AI Agent Nodes. They define the actions the AI Agent can take. If an AI Agent wants to execute the tool, the branch below the child Node is executed.

At the end of a tool branch, it is advisable to use a [Resolve Tool Action](/ai/agents/develop/node-reference/ai/resolve-tool-action) Node to return to the AI Agent.

Clicking the Tool Node lets you define a tool, set its parameters, and allows debugging by enabling detailed messages about the tool's execution.

<AccordionGroup>
  <Accordion title="Tool">
    | Parameter   | Type          | Description                                                                                                                                          |
    | ----------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Tool ID     | CognigyScript | Provide a meaningful name as a Tool ID. This ID can contain only letters, numbers, underscores (`_`), or dashes (`-`). For example, `update_user-1`. |
    | Description | CognigyScript | Provide a detailed description of what the tool does, when it should be used, and its parameters.                                                    |
  </Accordion>

  <Accordion title="Parameters">
    Configure the parameters that the AI Agent will collect before the tool is called. You can switch between the Graphical and JSON editors. When editing the JSON, follow the [JSON Schema specification](https://json-schema.org).

    | Parameter       | Type     | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
    | --------------- | -------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Use Parameters  | Toggle   | Activate this toggle to add parameters in addition to the tool name and description. The AI Agent will collect all data it needs and call a Tool with these parameters filled as arguments. These values can be accessed directly in the `input.aiAgent.toolArgs` object.                                                                                                                                                                                                                                                                                                                                                                           |
    | Name            | Text     | Specify the name of the parameter. The name should be clear and concise, and describe the purpose of the parameter.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
    | Type            | Selector | Select a type of the parameter:<ul><li>**String** — a sequence of characters. For example, `"hello"`, `"123"`.</li><li>**Number** — a numerical value, which can be either an integer (for example,`5`) or a floating point number (for example, `3.14`).</li><li>**Boolean** — a logical value representing `true` or `false`.</li><li>**Array** — a collection of elements, which can contain multiple values of any type. For example, `["apple", "banana", "cherry"]`.</li><li>**Object** — a collection of key-value pairs, where each key is a string and the value can be of any type. For example, `{"name": "John", "age": 30}`.</li></ul> |
    | Description     | Text     | Explain what the parameter means by providing a brief description of the parameter's usage.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
    | Enum (optional) | Enum     | Define a set of values that the parameter can accept. The enum restricts the input to one of the specified values, ensuring only valid options are chosen. The enum is only available for string-type parameters in the Graphical editor. For other types, use the JSON editor. May not be supported by all LLM providers.                                                                                                                                                                                                                                                                                                                          |
    | Add Parameter   | Button   | Add a new parameter.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
  </Accordion>

  <Accordion title="Debug Settings">
    | Parameter                 | Type   | Description                                                                                                       |
    | ------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------- |
    | Debug Message when called | Toggle | Enable the output of a debug message when the tool is called to provide detailed information about the tool call. |
  </Accordion>

  <Accordion title="Advanced">
    | Parameter | Type          | Description                                                                                                                                                                                                                                                                                                                                                                        |
    | --------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Condition | CognigyScript | The tool will be enabled only if the condition is evaluated as true. If false, the tool isn't part of the AI Agent's Tools within this execution. For example, when using the `unlock_account` tool, you can specify a condition like `context.accountStatus === "locked"`. This checks the value in the context, and if it is missing or different, the tool will not be enabled. |
  </Accordion>
</AccordionGroup>

#### MCP Tool

MCP Tool Nodes are child Nodes of AI Agent Nodes. The MCP Tool Nodes connect to a remote [MCP server](https://modelcontextprotocol.io/introduction) to load tools that the AI Agent can execute. If an AI Agent wants to execute one of the loaded tools, the branch below the MCP Tool Node is triggered.

Clicking the MCP Tool Node lets you define the connection, filter loaded tools, and allows debugging by enabling detailed messages about the tool's execution.

<AccordionGroup>
  <Accordion title="MCP Tool">
    | Parameter          | Type          | Description                                                                                                                                                                            |
    | ------------------ | ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Name               | CognigyScript | Provide a name for the MCP connection. This name helps you identify the source of the loaded tool.                                                                                     |
    | MCP Server SSE URL | CognigyScript | Provide the URL to an SSE (Server-Sent Events) endpoint from a remote [MCP server](https://modelcontextprotocol.io/introduction). Ensure that you connect only to trusted MCP servers. |
    | Timeout            | Slider        | Set the timeout time for the MCP connection in seconds.                                                                                                                                |
  </Accordion>

  <Accordion title="Authentication">
    | Parameter           | Type     | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
    | ------------------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Authentication Type | Selector | The authentication type to use for the MCP server connection. Select one of the following options: <ul><li>**None** — no authentication. This option is used by default.</li><li>**OAuth2** — authenticate using OAuth 2.0, which provides improved security and control compared to API keys. OAuth 2.0 supports scoped permissions, expiring tokens, and reduced exposure through short-lived tokens.</li></ul> If you want to use a different authentication method, such as an API key, you can add it as a custom header in **Custom Headers** of the **Advanced** section.                                                                                                                                                                                                                                                             |
    | OAuth2 Parameters   | Selector | Opens the fields required to configure OAuth 2.0 authentication. These fields allow the AI Agent to securely request and use access tokens when communicating with the MCP server. Configure the following fields: <ul><li>**Connection Name** — enter a descriptive name for the connection, for example, `MCP Tool OAuth`.</li><li>**OAuth URL** — enter the token endpoint URL exposed by the MCP server, for example: `https://mcp.example.com/oauth2/token`.</li><li>**Client ID** — enter the application (client) ID issued by the MCP server.</li><li>**Client Secret** — enter the application secret issued by the MCP server. Keep it secure.</li><li>**Scope** — add a list of scopes that define the permissions required by your application, for example: `read write admin`. Separate multiple scopes with spaces.</li></ul> |
  </Accordion>

  <Accordion title="Debug Settings">
    | Parameter             | Type   | Description                                                                                                                                                                                                                                                               |
    | --------------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Debug Loaded Tools    | Toggle | Enable this parameter to display a debug message listing all tools loaded from the MCP server. The debug message also includes tools filtered out in the Advanced section. This parameter shows whether tools were loaded from the cache or directly from the MCP server. |
    | Debug with Parameters | Toggle | Enable this parameter to include the Tool Parameters in the debug message.                                                                                                                                                                                                |
    | Debug calling Tool    | Toggle | Enable the output of a debug message when the tool is called to provide detailed information about the tool call.                                                                                                                                                         |
  </Accordion>

  <Accordion title="Advanced">
    | Parameter      | Type          | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
    | -------------- | ------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Cache Tools    | Toggle        | Disables caching of loaded tools while developing. Ensure that caching is enabled in production for performance reasons. The caching time is 10 minutes. In debug mode, you can verify whether the cache was used. To do this, make sure **Debug Loaded Tools** is enabled. For more information, see the [Debug Settings](#debug-settings) section.                                                                                                                    |
    | Condition      | CognigyScript | Sets the condition under which the tool will be activated. If the condition is evaluated as false, the tool isn't part of the AI Agent's Tools during execution. For example, when using the `unlock_account` tool, you can specify a condition like `context.accountStatus === "locked"`. This checks the value in the context, and if it is missing or different, the tool will not be enabled.                                                                       |
    | Tool Filter    | Select        | Controls if tools should be excluded from execution. You can select one of the following options:<ul><li>**None** — no tool filtering is applied, and all tools are available for execution. This option is selected by default.</li><li>**Whitelist** — only tools on the list are allowed for execution, while all other tools are excluded.</li><li>**Blacklist** — tools on the list are excluded from execution, while all other tools remain available.</li></ul> |
    | Blacklist      | CognigyScript | This parameter appears if you select **Blacklist** in **Tool Filter**. Specify the tools that should be blocked from execution. Specify only one tool per field.                                                                                                                                                                                                                                                                                                        |
    | Whitelist      | CognigyScript | This parameter appears if you select **Whitelist** in **Tool Filter**. Specify the tools you want to allow for execution. Specify only one tool per field.                                                                                                                                                                                                                                                                                                              |
    | Custom Headers | -             | Sets custom authentication headers to send with the request to the MCP server. Use the **Key** and **Value** fields to enter a header. The **Value** field supports CognigyScript. After entering the header key, new empty **Key** and **Value** fields are automatically added, in case you need to add more headers. Alternatively, you can click **Show JSON Editor** and enter the headers in the code field.                                                      |
  </Accordion>
</AccordionGroup>

#### Call MCP Tool

In the Flow editor, when you add an MCP Tool Node, a Call MCP Tool Node is automatically created below it. These two Nodes work together to define and execute the chosen tool. The Call MCP Tool Node sets the actual execution point of the chosen tool. This way, you can verify or modify the tool call arguments in the `input.aiAgent.toolArgs` object, or add a Say Node before the tool call. When the Call MCP Tool Node is executed, the tool call is sent to the remote MCP server, where the Tool is executed remotely with any arguments set by the AI Agent.

To return the tool result to the AI Agent, the **Resolve Immediately** setting can be enabled to send the full result returned from the remote MCP server to the AI Agent.

As an alternative, use a [Resolve Tool Action](/ai/agents/develop/node-reference/ai/resolve-tool-action) Node to return a specific result to the AI Agent.

<AccordionGroup>
  <Accordion title="Call MCP Tool">
    | Parameter           | Type   | Description                                                                                           |
    | ------------------- | ------ | ----------------------------------------------------------------------------------------------------- |
    | Resolve Immediately | Toggle | Enable this parameter to immediately resolve the tool action with the full result as the tool answer. |
  </Accordion>

  <Accordion title="Storage Options">
    | Parameter                   | Type          | Description                                                                                                                                                                                                                               |
    | --------------------------- | ------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | How to handle the result    | Select        | Determine how to handle the MCP tool call result:<ul><li>**Store in Input** — stores the result in the Input object.</li><li>**Store in Context** — stores the result in the Context object.</li></ul>                                    |
    | Input Key to store Result   | CognigyScript | The parameter appears when **Store in Input** is selected. The result is stored in the `input.aiAgent.toolResult` object by default. You can specify another value, but the **MCP Tool Result** Token won't work if the value is changed. |
    | Context Key to store Result | CognigyScript | The parameter appears when **Store in Context** is selected. The result is stored in the `context.aiAgent.toolResult` object by default.                                                                                                  |
  </Accordion>

  <Accordion title="Debug Settings">
    | Parameter         | Type   | Description                                                                             |
    | ----------------- | ------ | --------------------------------------------------------------------------------------- |
    | Debug Tool Result | Toggle | Enable the output of a debug message with the tool call result after a successful call. |
  </Accordion>
</AccordionGroup>

#### Knowledge Tool

The Knowledge Tool Node is a child Node of the AI Agent Node. It allows the AI Agent to directly access [Knowledge Stores](/ai/agents/develop/knowledge-ai/knowledge-store) to provide context-aware responses.

In the Knowledge Tool Node, you can select the [Knowledge Store](/ai/agents/develop/knowledge-ai/knowledge-store) to search, [Source Tags](/ai/agents/develop/knowledge-ai/knowledge-source/knowledge-source-tags) to refine the search, and allows for detailed debug messages about the tool's execution.

<AccordionGroup>
  <Accordion title="Knowledge Tool">
    | Parameter       | Type          | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
    | --------------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Knowledge Store | Selector      | Select a Knowledge Store.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
    | Tool ID         | CognigyScript | Enter a name as a tool ID. This ID can contain only letters, numbers, underscores (`_`), or dashes (`-`). If you use more than one Knowledge tool, the tool ID provides context to trigger the correct Knowledge tool. In this case, enter a clear tool ID for each Knowledge tool, for example, `search_appliances`                                                                                                                                                                                                                                                                                                                        |
    | Description     | CognigyScript | Enter instructions to guide the AI Agent to call the Knowledge tool. The description field provides context to trigger the Knowledge tool. If you want to use more than one Knowledge tool, enter clear instructions for the cases when each Knowledge tool should be used. For example, `Find the answer to prompts or questions about appliances by searching the attached data sources. Use this tool when a customer asks about appliance items such as washing machines, dryers, and other household appliances. Focus exclusively on a knowledge search and does not execute tasks like small talk, calculations, or script running.` |
  </Accordion>

  <Accordion title="Debug Settings">
    | Parameter                 | Type   | Description                                                                                                       |
    | ------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------- |
    | Debug Message when called | Toggle | Enable the output of a debug message when the tool is called to provide detailed information about the tool call. |
  </Accordion>

  <Accordion title="Advanced">
    | Parameter                   | Type          | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
    | --------------------------- | ------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Top K                       | Slider        | Set how many Knowledge Chunks to return. Providing more results gives the AI Agent additional context, but it also increases noise and token usage.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
    | Store Location              | Selector      | Select whether and where to store the knowledge search results. Select one of the following options:<ul><li>**Don't store** — the content isn't stored. This option is set by default.</li><li>**Input** — the content is stored in the Input object.</li><li>**Context** — the content is stored in the Context object.</li></ul>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
    | Input Key to store result   | CognigyScript | Appears when **Store Location** is set to **Input**. The property in the Input object where the result is stored. For example, `input.knowledgeSearch`.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
    | Context Key to store result | CognigyScript | Appears when **Store Location** is set to **Context**. The property in the Context object where the result is stored. For example, `context.knowledgeSearch`.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
    | Source Tags                 | CognigyScript | Enter [Knowledge Source Tags](/ai/agents/develop/knowledge-ai/knowledge-source/knowledge-source-tags) to refine the scope of your knowledge search, including only the most relevant Knowledge Chunks in the Knowledge Store. Before entering tags, ensure they are included in the Knowledge Sources. Add tags by entering each separately and pressing <kbd>Enter</kbd>. Max 5 tags. When multiple Source Tags are specified, the Search Extract Output Node defaults to the `AND` operator, meaning it only considers Sources that have all specified tags. To change this behavior, adjust the **Match Type for Source Tags** parameter.                                                                                                                                                                      |
    | Match type for Source Tags  | Selector      | The operator to filter Knowledge Sources by Source Tags. Select one of the following options:<ul><li>**AND** — the default value, requires all Source Tags to match across multiple Knowledge Sources. Consider the following example: there are Knowledge Sources with Source Tags `S-a`, `S-b`, and `S-c`. When you use the `AND` operator to filter by `S-a` and `S-b`, only Sources with both Tags `S-a` and `S-b` are included in the search results.</li><li>**OR** — requires at least one Source Tag to match across multiple Knowledge Sources. Consider the following example: there are Knowledge Sources with Source Tags `S-a`, `S-b`, and `S-c`. When you use the `OR` operator to filter by `S-a` or `S-b`, any Source with either Tag `S-a` or `S-b` is included in the search results.</li></ul> |
    | Condition                   | CognigyScript | The Knowledge tool is activated only if the condition is evaluated as true. If false, the tool isn't included in the current execution. For example, when using the Knowledge tool, you can enter a condition such as `context.productCategory === "appliances"`. This checks the value in the context, and if it is missing or different, the tool isn't activated.                                                                                                                                                                                                                                                                                                                                                                                                                                              |
  </Accordion>
</AccordionGroup>

#### Send Email Tool

The Send Email tool lets your AI Agent send emails directly to users. The Send Email tool uses the same configuration and restrictions as the [Email Notification Node](/ai/agents/develop/node-reference/data/email-notification) but adds more flexibility. While the Email Notification Node sends emails at a fixed step in a Flow, the Send Email tool allows the AI Agent to send emails dynamically, based on user input, conversation context, or instructions. This tool makes automation more flexible and minimizes extra Flow steps.

<AccordionGroup>
  <Accordion title="Tool">
    | Parameter                    | Type          | Description                                                                                                                                              |
    | ---------------------------- | ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Tool ID                      | CognigyScript | Provide a meaningful name as a tool ID. This ID can contain only letters, numbers, underscores (`_`), or dashes (`-`). The default name is `send_email`. |
    | Description                  | CognigyScript | Provide a detailed description of what the tool should do. The default description is `Create and send a new email message.`                             |
    | Recipient TO Email Addresses | CognigyScript | A comma-separated list of email addresses to which the email will be sent.                                                                               |
  </Accordion>

  <Accordion title="Debug Settings">
    | Parameter                 | Type   | Description                                                                                                       |
    | ------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------- |
    | Debug Message when called | Toggle | Enable the output of a debug message when the tool is called to provide detailed information about the tool call. |
  </Accordion>

  <Accordion title="Advanced">
    | Parameter | Type          | Description                                                                                                                                                                                                                                                                                                                                                                        |
    | --------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Condition | CognigyScript | The tool will be enabled only if the condition is evaluated as true. If false, the tool isn't part of the AI Agent's Tools within this execution. For example, when using the `unlock_account` tool, you can specify a condition like `context.accountStatus === "locked"`. This checks the value in the context, and if it is missing or different, the tool will not be enabled. |
  </Accordion>
</AccordionGroup>

#### Handover to AI Agent Tool

The Handover to AI Agent tool lets you transfer a conversation to another AI Agent in the same or a different Flow. This approach ensures the conversation keeps its context, different AI Agents can handle specific tasks, and multi-step conversations run smoothly across Flows.

<AccordionGroup>
  <Accordion title="Tool">
    | Parameter   | Type          | Description                                                                                                                                                                                                                                                     |
    | ----------- | ------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Tool ID     | CognigyScript | Provide a meaningful name as a tool ID. This ID can contain only letters, numbers, underscores (`_`), or dashes (`-`). The default name is `handover_to_ai_agent`.                                                                                              |
    | Description | CognigyScript | Describe what the receiving AI Agent should do. For example: `Handle product recommendations`, `Perform technical troubleshooting`, or `Assist with billing questions`. Be specific so the handover rules clearly indicate when this AI Agent should take over. |
    | Select Flow | Selector      | Select the target Flow to hand over to. By default, all Flows in the Project are displayed in the list. The selected Flow must contain an AI Agent Node.                                                                                                        |
    | Select Node | Selector      | Select the AI Agent Node to hand over to.                                                                                                                                                                                                                       |
  </Accordion>

  <Accordion title="Debug Settings">
    | Parameter                 | Type   | Description                                                                                                       |
    | ------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------- |
    | Debug Message when called | Toggle | Enable the output of a debug message when the tool is called to provide detailed information about the tool call. |
  </Accordion>

  <Accordion title="Advanced">
    | Parameter | Type          | Description                                                                                                                                                                                                                                                                                                                                                                        |
    | --------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Condition | CognigyScript | The tool will be enabled only if the condition is evaluated as true. If false, the tool isn't part of the AI Agent's Tools within this execution. For example, when using the `unlock_account` tool, you can specify a condition like `context.accountStatus === "locked"`. This checks the value in the context, and if it is missing or different, the tool will not be enabled. |
  </Accordion>
</AccordionGroup>

#### Handover to Human Agent Tool

The Handover to Human Agent tool lets you transfer a conversation to a human agent through handover providers. This tool allows your AI Agents to refer complex tasks to a human agent if they can't address the user's request.

<AccordionGroup>
  <Accordion title="Tool">
    | Parameter                        | Type          | Description                                                                                                                                                                                                                                                                                                                                                                              |
    | -------------------------------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Tool ID                          | CognigyScript | Provide a meaningful name as a tool ID. This ID can contain only letters, numbers, underscores (`_`), or dashes (`-`). The default name is `handover_to_human_agent`.                                                                                                                                                                                                                    |
    | Description                      | CognigyScript | Describe the situation when the AI Agent should refer to a human agent. For example: `Use this tool if the user explicitly asks for a human.`, or `Use this tool if you fail to answer the user's question three times.`. Be specific so the handover rules clearly indicate when the conversation should be handed over to the receiving human agent.                                   |
    | Handover Provider                | Selector      | Select the handover provider from the list. The **Legacy** option is selected by default, meaning the node configuration points to the settings in **Deploy > Endpoints > Handover Settings**. To select a provider from the list, you need to either migrate your settings to the [Handover Providers](/ai/escalate/migration) interface or create this handover provider from scratch. |
    | Handover Accepted Message        | CognigyScript | The message to be outputted when the handover is requested.                                                                                                                                                                                                                                                                                                                              |
    | Repeat Handover Accepted Message | Toggle        | Enable to repeatedly output the Handover Accepted Message if the user sends a message while waiting in the queue for an agent.                                                                                                                                                                                                                                                           |
  </Accordion>

  <Accordion title="Live Agent Settings">
    | Parameter                       | Description                                                                                                                                                                                                                                                                                                                                                                  |
    | ------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Live Agent Inbox Id             | Enter the Inbox ID that you obtained in the [previous step](/ai/escalate/handover-reference/live-agent).                                                                                                                                                                                                                                                                     |
    | Skills                          | Enter a list of skills that should be used to filter the available agents. For example, `technical support, billing`.                                                                                                                                                                                                                                                        |
    | Languages                       | Enter a list of languages that should be used to filter the available agents. For example, `english, spanish`.                                                                                                                                                                                                                                                               |
    | Priority                        | Select a priority for the conversation from the list. For example, `Urgent`.                                                                                                                                                                                                                                                                                                 |
    | Get Queue Position              | Enable the system to retrieve the end user's current queue position. This parameter is inactive by default.                                                                                                                                                                                                                                                                  |
    | Update Interval                 | Specify the interval, in seconds, for how often to receive updates on the queue status. This parameter appears if **Get Queue Position** is selected.                                                                                                                                                                                                                        |
    | Get Estimated Wait Time         | Enable the retrieval of the estimated wait time for the end user. This parameter is inactive by default.                                                                                                                                                                                                                                                                     |
    | Wait Time Update Interval       | Set the interval, in seconds, for how often to receive updates on estimated wait time. This parameter appears if **Get Estimated Wait Time** is selected.                                                                                                                                                                                                                    |
    | Alternative Update              | The alternative update options when certain conditions are met. This parameter is inactive by default.                                                                                                                                                                                                                                                                       |
    | Maximum Queue Position          | Set the threshold for the maximum queue position. If this threshold is reached, the alternative text is sent. This parameter appears if **Alternative Update** is selected.                                                                                                                                                                                                  |
    | Maximum Estimated Wait Time     | Define the maximum estimated wait time in milliseconds. If this duration is exceeded, the alternative text is sent. This parameter appears if **Alternative Update** is selected.                                                                                                                                                                                            |
    | Alternative Text                | The message to be sent when either the maximum queue position or maximum wait time is reached. This parameter appears if **Alternative Update** is selected.                                                                                                                                                                                                                 |
    | Enable User Connects Message    | Notify human agents when an end user reconnects to the chat. The parameter is enabled by default. When the parameter is enabled, the message `User joined the conversation` appears in the chat as soon as the end user returns to the chat tab by clicking the **←** (back arrow) at the top bar in the browser, after having opened a new URL on the same tab as the chat. |
    | Enable User Disconnects Message | Notify human agents when an end user disconnects from the chat. The parameter is enabled by default. When the parameter is enabled, the message `User left the conversation` is sent as soon as the end user closes the tab with the chat or switches to a new URL address within the current tab.                                                                           |

    For more information, read the [Live Agent Handover Setup](/live-agent/getting-started/live-agent-setup/live-agent-setup-handover-flow) and [Real-Time Queue Notifications](/live-agent/conversation/conversation-queue/real-time-queue-notifications) documentation.
  </Accordion>

  <Accordion title="Chatwoot Settings">
    | Parameter         | Description                                                                                                                                                                                                                                                                                          |
    | ----------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Chatwoot Inbox Id | Enter the Chatwoot Inbox ID. You can find the Inbox ID in your Chatwoot URL. For example, `https://app.chatwoot.com/app/account/6607/inbox/5446`, where the Inbox ID is `5446`. For more information, read the [Chatwoot handover provider](/ai/escalate/handover-reference/chatwoot) documentation. |
  </Accordion>

  <Accordion title="Salesforce Chat Settings">
    | Parameter                        | Description                                                                                                                                                                                                                                        |
    | -------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Send Transcript as first message | Activate this parameter to allow Salesforce to receive the conversation transcript as the first message. This setting is turned off by default.                                                                                                    |
    | Button ID                        | Enter the ID of the Button you created in the Salesforce installation. This setting will override the default Button ID that you specified in the Endpoint configuration. You can use different Button IDs for individual Handover to Agent Nodes. |
    | Pre-chat Entities                | Enter the pre-chat entities. For more information, read the [Salesforce Handover](/ai/escalate/handover-reference/salesforce) documentation.                                                                                                       |
    | Pre-chat Details                 | Enter the pre-chat details. For more information, read the [Salesforce Handover](/ai/escalate/handover-reference/salesforce) documentation.                                                                                                        |
  </Accordion>

  <Accordion title="NiCE CXone Settings">
    | Parameter                        | Description                                                                                                                                                             |
    | -------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Send Transcript as first message | Activate this parameter to allow NiCE CXone to receive the conversation transcript as the first message when the handover begins. This setting is turned on by default. |
  </Accordion>

  <Accordion title="Genesys Settings">
    | Parameter                       | Description                                                                                                                                                                                                                                                                                                                                                                  |
    | ------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Language                        | Specify a language for the conversation. For example, `english`, `spanish`, `german`.                                                                                                                                                                                                                                                                                        |
    | Skills                          | Define skills for the conversation. For example, `escalation`.                                                                                                                                                                                                                                                                                                               |
    | Priority                        | Set the priority for the conversation. For example, `1`. <br /> If a priority is set, it triggers a flow in Genesys to prioritize or de-prioritize the conversation within the queue. <br /> Note that this functionality requires the appropriate flow to be set up in Genesys.                                                                                             |
    | Enable User Connects Message    | Notify human agents when an end user reconnects to the chat. The parameter is enabled by default. When the parameter is enabled, the message `User joined the conversation` appears in the chat as soon as the end user returns to the chat tab by clicking the **←** (back arrow) at the top bar in the browser, after having opened a new URL on the same tab as the chat. |
    | Enable User Disconnects Message | Notify human agents when an end user disconnects from the chat. The parameter is enabled by default. When the parameter is enabled, the message `User left the conversation` is sent as soon as the end user closes the tab with the chat or switches to a new URL address within the current tab.                                                                           |
    | Custom Attributes               | Add custom attributes in the `Key: Value` format, which allows you to include additional information.                                                                                                                                                                                                                                                                        |

    Example for the **Custom Attributes** parameter:

    ```json theme={null}
    {
      "section": "section A",
      "region": "Europe"
    }
    ```

    For more information,
    read
    the [Genesys Cloud Guest Chat](/ai/escalate/handover-reference/genesys-cloud-guest-chat#prerequisites) and [Genesys Cloud Open Messaging](/ai/escalate/handover-reference/genesys-cloud-open-messaging) documentation.
  </Accordion>

  <Accordion title="8x8 Settings">
    | Parameter           | Description                                                                                                                                                                                                                                                                      |
    | ------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | 8x8 Channel Id      | Specify the channel ID that you created during the 8x8 configuration. <br /> You can find this ID in the 8x8 admin console. Navigate to **Channels > Chat API**. In the channel list, find the channel that you created. Copy the **ID** from the channel row.                   |
    | 8x8 Queue Id        | Specify the header value required for authenticating API calls to the 8x8 system. <br /> You can find this ID in the 8x8 admin console. Navigate to **Channels > Chat API**. In the channel list, find the channel that you created. Copy the **Queue ID** from the channel row. |
    | 8x8 JSON properties | Extend 8x8 properties with custom JSON.                                                                                                                                                                                                                                          |

    For more information, read the [8x8 Handover Setup](/ai/escalate/handover-reference/8x8) documentation.
  </Accordion>

  <Accordion title="RingCentral Engage Settings">
    | Parameter                       | Type          | Description                                                                                                                                                                                                                                                                                                                                                                  |
    | ------------------------------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Additional Category Ids         | CognigyScript | IDs to be passed to the RingCentral Engage handover provider.                                                                                                                                                                                                                                                                                                                |
    | Enable User Connects Message    | Toggle        | Notify human agents when an end user reconnects to the chat. The parameter is enabled by default. When the parameter is enabled, the message `User joined the conversation` appears in the chat as soon as the end user returns to the chat tab by clicking the **←** (back arrow) at the top bar in the browser, after having opened a new URL on the same tab as the chat. |
    | Enable User Disconnects Message | Toggle        | Notify human agents when an end user disconnects from the chat. The parameter is enabled by default. When the parameter is enabled, the message `User left the conversation` is sent as soon as the end user closes the tab with the chat or switches to a new URL address within the current tab.                                                                           |

    For more information, read the [RingCentral Engage Integration](/ai/escalate/handover-reference/ring-central-engage) documentation.
  </Accordion>

  <Accordion title="Cancel Handover Options">
    | Parameter          | Type          | Description                                                                                          |
    | ------------------ | ------------- | ---------------------------------------------------------------------------------------------------- |
    | Cancel Intent      | CognigyScript | The Intent the user has to trigger to cancel the Handover request.                                   |
    | Cancel Button Text | CognigyScript | The text for a quick reply button that cancels the handover request when the user clicks the button. |
  </Accordion>

  <Accordion title="On Resolve Options">
    | Parameter                           | Type   | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
    | ----------------------------------- | ------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Flow Continuation                   | List   | <ul><li>**Below this Node** – the user is taken to the Node below the Handover Node once the agent resolves the conversation. In this case, the user would continue in a different flow, but the starting point would be the Node below the Handover Node.</li><li>**At current AgentInject Entrypoint** – the user continues the chat at the current agent inject entrypoint. This option allows the agent to guide the user to a specific part of the chat and then give control back to the user.</li></ul> |
    | Send resolve event to Virtual Agent | Toggle | Sending an event when the AI Agent resolves a conversation.                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
  </Accordion>

  <Accordion title="Event Settings">
    | Parameter         | Type   | Description                                             |
    | ----------------- | ------ | ------------------------------------------------------- |
    | Send Queue Event  | Toggle | Sends an event to the Flow once the handover is queued. |
    | Send Active Event | Toggle | Sends an event to the Flow once the handover is active. |
  </Accordion>

  <Accordion title="Debug Settings">
    | Parameter                 | Type   | Description                                                                                                       |
    | ------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------- |
    | Debug Message when called | Toggle | Enable the output of a debug message when the tool is called to provide detailed information about the tool call. |
  </Accordion>

  <Accordion title="Advanced">
    | Parameter | Type          | Description                                                                                                                                                                                                                                                                                                                                                                        |
    | --------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Condition | CognigyScript | The tool will be enabled only if the condition is evaluated as true. If false, the tool isn't part of the AI Agent's Tools within this execution. For example, when using the `unlock_account` tool, you can specify a condition like `context.accountStatus === "locked"`. This checks the value in the context, and if it is missing or different, the tool will not be enabled. |
  </Accordion>
</AccordionGroup>

#### Execute Workflow Tool

The Execute Workflow tool lets the AI Agent execute another Flow. After the target Flow executes, the conversation returns to the AI Agent.

The target Flow inherits the [Context object](/ai/agents/develop/ai-agent-memory/context) from the AI Agent. If the Context object is changed during the target Flow execution, these changes are also available to the AI Agent.

| Parameter   | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| ----------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Tool ID     | Enter a meaningful name as a tool ID. This ID can contain only letters, numbers, underscores (`_`), or dashes (`-`). The default name is `execute_workflow`.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| Description | Describe when to trigger the AI Agent to execute the target Flow. For example, if you have a specific Flow for dealing with package returns, enter: `Use this tool if the user explicitly asks to return a package.`. Be specific so the AI Agent only executes the target Flow when necessary.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| Target Flow | Select the target Flow that the AI Agent executes when this tool is called. Click <img src="https://mintcdn.com/cognigy-15abf2ba/I0ba9I1paCAUpGLP/_assets/icons/black-and-white/target-flow.svg?fit=max&auto=format&n=I0ba9I1paCAUpGLP&q=85&s=a829f550bb73834106c8650fba92ac3c" alt="target-flow" width="25" height="25" data-path="_assets/icons/black-and-white/target-flow.svg" /> to open the target Flow. |
| Select Node | Select the target Node that the AI Agent executes when the target Flow is called. You must set the Node you want to select as an Entrypoint with the [Set Entrypoint](/ai/agents/develop/nodes/overview#set-nodes-as-entrypoints) setting before you can select it.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |

<AccordionGroup>
  <Accordion title="Debug Settings">
    | Parameter                 | Type   | Description                                                                                                         |
    | ------------------------- | ------ | ------------------------------------------------------------------------------------------------------------------- |
    | Debug Message when called | Toggle | Activate the output of a debug message when the tool is called to provide detailed information about the tool call. |
  </Accordion>

  <Accordion title="Advanced">
    | Parameter      | Type   | Description                                                                                                                                                                                                                                                                                                                                                                                                                              |
    | -------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Parse Intents  | Toggle | Sets whether Intents should be parsed in the target Flow. This parameter is activated by default.<br /><br />If this parameter is enabled, Cognigy NLU reparses the Intents in the target Flow based on `text` in the [Input object](/ai/agents/develop/ai-agent-memory/input#accessing-input-properties) and generates Intent scores using the Intents in the target Flow instead of the ones in the Flow the AI Agent is currently in. |
    | Parse Slots    | Toggle | Sets whether Slots should be parsed in the target Flow. This parameter is activated by default.<br /><br />If this parameter is enabled, Cognigy NLU reparses the Slots in the target Flow based on `text` in the [Input object](/ai/agents/develop/ai-agent-memory/input#accessing-input-properties) and generates Slot scores using the Slots in the target Flow instead of the ones in the Flow the AI Agent is currently in.         |
    | Absorb Context | Toggle | Sets whether the [default Context object](/ai/agents/develop/ai-agent-memory/context#default-context) of the target Flow is used in the context of the Flow the AI Agent is currently in.<br /><br />If the default Context of the target Flow has a value, it is copied into the Context object of the AI Agent as soon as the target Flow is executed.                                                                                 |
  </Accordion>
</AccordionGroup>

## Examples

### Tool

In this example, the `unlock_account` tool unlocks a user account by providing the email and specifying the reason for the unlocking.

Parameter configuration in JSON:

```json theme={null}
{
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "description": "User's login email for their account."
    }
  },
  "required": ["email"],
  "additionalProperties": false
}
```

where:

* `type` — the type for a tool parameter schema, which must always be `object`.
* `properties` — defines the parameters for the tool configuration:
  * `email` — a required tool parameter for unlocking the account.
    * `type` — defines the data type for the tool parameter.
    * `description` — a brief explanation of what the property represents.
* `required` — lists `email` as a required parameter, ensuring that this value is always provided when the tool is called.
* `additionalProperties` — ensures that the input contains only the `email` tool parameter, and no others are allowed.

### MCP Tool and Call MCP Tool

#### Use Zapier's Remote MCP server

You can create a custom MCP server with personalized tools by using one of the [provided SDKs](https://github.com/modelcontextprotocol). For a quicker setup, you can use a third-party provider. For example, [Zapier](https://zapier.com/) allows you to [configure your MCP server](https://actions.zapier.com/settings/mcp/), which can be connected to multiple application APIs.

To use Zapier as a remote MCP server, follow these steps:

1. Log in to your Zapier account, go to the [MCP settings](https://actions.zapier.com/settings/mcp/) page, and configure your MCP server.
2. Copy the SSE URL and paste it into the **MCP Server SSE URL** field of your MCP Tool Node.
3. In the Zapier MCP settings, create an action to connect to various APIs. For example, you can create a Zapier action to automatically generate a Google Doc.

Once the setup is complete, the configured MCP Actions will be loaded when the AI Agent is executed.

You will see the following debug message in the Interaction Panel, indicating the result of the tool call after a successful execution:

```txt theme={null}
AI Agent: MCP Tool
Fetched tools from MCP Tool "zapier"

- google_docs_create_document_from_: Create a new document from text. Also supports limited HTML.
  Parameters:
  - title (string): Document Name
  - file (string): Document Content
```

### Knowledge Tool

In this example, you have two Knowledge tools to search two different Knowledge Stores. Each Knowledge Store refers to a different product category, in this example, appliances and furniture. To guide the AI Agent to use the correct Knowledge tool, enter a clear tool ID and description:

* Knowledge Tool 1:
  * Tool ID: `search_appliances`
  * Description: `Find the answer to prompts or questions about appliances by searching the attached data sources. Use this tool when a customer asks about appliance items such as washing machines, dryers, and other household appliances. Focus exclusively on a knowledge search and does not execute tasks like small talk, calculations, or script running.`
* Knowledge Tool 2:
  * Tool ID: `search_furniture`
  * Description: `Find the answer to prompts or questions about furniture by searching the attached data sources. Use this tool when a customer asks about furniture items such as sofas, tables, and other items. Focus exclusively on a knowledge search and does not execute tasks like small talk, calculations, or script running.`

## More Information

* [LLM](/ai/agents/develop/gen-ai-and-llms/llms)
* [Generative AI](/ai/agents/develop/gen-ai-and-llms/generative-ai)

***

<sup id="footnote1">1</sup>: Note that not all LLM models support streaming.
