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

# Installing the n8n node

> Install the VARIOS AI n8n node, set up credentials and use it as a language model in workflows

The VARIOS AI n8n node makes the chat models and assistants of your VARIOS AI installation available as a language model in [n8n](https://n8n.io). It connects through the OpenAI-compatible endpoint of your instance and provides a language model on its **Model** output, which you connect to an AI Agent or a chain. Automations in n8n therefore run on the models released in VARIOS AI, with the budgets and DLP rules configured there.

The package is published as a community node under [`@varios-ai/n8n-nodes-varios-ai`](https://www.npmjs.com/package/@varios-ai/n8n-nodes-varios-ai); the source code lives at [github.com/varios-ai/n8n](https://github.com/varios-ai/n8n) (MIT).

## Requirements

* A current n8n installation. The node requires a minimum version and cannot be installed in older n8n versions; the version required is stated in the [package description on npm](https://www.npmjs.com/package/@varios-ai/n8n-nodes-varios-ai).
* Permission to install community nodes in n8n. n8n Cloud restricts the installation of your own community nodes, so use a self-hosted instance there.
* An [API key](/en/monthly/admin/apikeys) from VARIOS AI with the desired chat models or assistants assigned to it.
* The VARIOS AI instance must be reachable over HTTPS from the n8n server.

<Note>
  Every API key requires its own license. Include the license for the n8n integration in your planning.
</Note>

## Installation

<Steps>
  <Step title="Install the community node">
    In n8n, open **Settings → Community nodes → Install** and enter the package name:

    ```text theme={null}
    @varios-ai/n8n-nodes-varios-ai
    ```

    Accept the terms for community nodes and complete the installation. Afterwards the **VARIOS AI** node is available in the node search under **AI → Language Models**.
  </Step>

  <Step title="Create an API key in VARIOS AI">
    Under Administration → [API keys](/en/monthly/admin/apikeys), create a key for n8n, for example named "n8n". Assign the chat models that should be usable in n8n to the key and set a cost limit. Copy the key immediately, it is shown only once.
  </Step>

  <Step title="Set up the credentials in n8n">
    In n8n, create credentials of type **VARIOS AI API** with these two values:

    | Field    | Value                             |
    | -------- | --------------------------------- |
    | Base URL | `https://<PROJECT_DOMAIN>/api/v1` |
    | API Key  | The API key created in VARIOS AI  |

    Replace `<PROJECT_DOMAIN>` with the domain of your installation, i.e. the value of `PROJECT_DOMAIN` from the `.env`; the path `/api/v1` stays unchanged. Example for the domain `ki.example.com`: `https://ki.example.com/api/v1`.

    Using **Test**, n8n checks the credentials against `/models`. The key is sent as a bearer token in the `Authorization` header on every request.
  </Step>

  <Step title="Use the node in a workflow">
    Add the **VARIOS AI** node and select the credentials. Under **Model**, either choose **From List** – n8n then loads the models assigned to the key – or enter an ID manually via **Name**. Optionally, **System Prompt** holds a system message that is prepended to every conversation.

    Then connect the **Model** output to an **AI Agent** or another node that expects a language model. The node itself has no data input.

    <Info>
      As an ID, the API accepts the **chat model ID** of a preconfigured model or an **assistant ID**. Only assistants and models assigned to the API key in use are available, see [API keys](/en/monthly/admin/apikeys).
    </Info>
  </Step>
</Steps>

## Node options

Under **Options** you can add individual parameters as needed. Without an entry, the default values apply.

| Option            | Default | Meaning                                                      |
| ----------------- | ------- | ------------------------------------------------------------ |
| Temperature       | `0.7`   | Spread of the answers, `0` is deterministic, `2` very random |
| Top P             | `1`     | Nucleus sampling, probability mass of the tokens considered  |
| Maximum Tokens    | `2048`  | Upper limit of generated tokens                              |
| Frequency Penalty | `0`     | Penalty for frequently repeated tokens, `-2` to `2`          |
| Presence Penalty  | `0`     | Penalty for tokens already used, `-2` to `2`                 |
| Streaming         | enabled | Return the answer token by token                             |
| Timeout (Ms)      | `60000` | Time limit of a request in milliseconds                      |
| Max Retries       | `2`     | Retries after a failed request                               |

## Troubleshooting

| Symptom                                           | Check                                                                                                                    |
| ------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
| The credentials test fails                        | Base URL ends in `/api/v1`, instance reachable from the n8n server, valid HTTPS certificate                              |
| 401 or 403 on every request                       | API key valid and not deleted, key copied in full                                                                        |
| The model list stays empty                        | Chat models supporting the Chat Completions API are assigned to the API key                                              |
| A model is missing from the list                  | Model configured with Chat Completions support in the [model settings](/en/monthly/admin/models) and assigned to the key |
| Requests are rejected although the key is correct | Monthly cost limit of the key reached, see [API keys](/en/monthly/admin/apikeys)                                         |
| Answers stop short on long tasks                  | Increase `Timeout (Ms)` and `Maximum Tokens`                                                                             |
| The node does not appear in the node search       | n8n version meets the minimum stated in the package description, community node installed successfully, n8n restarted    |
