Skip to main content
Home > “Admin Menu” > “API Keys”

API Keys

API keys enable direct access to assistants and pre-configured chat models through the API, so you can integrate VARIOS AI into third-party applications such as chatbots, helpdesk systems, or web portals. Assistants and chat models configured in VARIOS AI can be wired into existing workflows behind a single OpenAI-compatible endpoint.
Info: The VARIOS AI API is OpenAI compatible.
Note: Each API key requires its own license. Make sure that sufficient licenses are available for the planned integrations.

Features at a glance

  • List view: Displays all existing API keys with names. Each key can be edited or deleted.
  • Search: Enables quick retrieval of individual keys.
  • New API Key: Use the “New API Key” button to create an additional key.

Create API key

When creating or editing an API key, the following options are available:
  1. Name
    Freely chosen label to identify the API key, e.g., Shopware Integration.
  2. Maximum costs per month ($)
    • Limit the monthly costs for this key.
    • Value 0 means that no costs are allowed.
    • Value -1 means no limit.
Note Projection based on tokens and may differ from actual billing costs.
  1. DLP
    Defines how Data Loss Prevention (DLP) is applied for all assistants and models on this API key:
    • Use assistant/model settings: DLP follows the setting of the respective assistant or model.
    • Enforce DLP: DLP is active for all requests with this key, regardless of assistant, model, or request settings.
  2. Assistants
    Select which assistants can be used with this key. Only shared assistants can be accessed by the connected application. Assistant cards show the assistant’s DLP setting (including model combination), not the behaviour overridden by Enforce DLP on the key.
    You can also configure whether assistant responses are Chat Completions API compatible.
  3. Models & tools
    Select which chat models can be used with this key. Only models that support the Chat Completions API are compatible with the API. Model cards show the model’s DLP setting, not the behaviour overridden by Enforce DLP on the key.
    The actual DLP behaviour for API requests follows from the key setting and the entity setting (see table below). In the Tools (model API) section, choose connectors and knowledge bases for direct model access via the API. In Tool options, you can block client-defined tools or expose all selected application tools to the model by default.

Typical use cases

  • Web chatbots with access to internal knowledge bases
  • Integration into CRM or ERP systems for automated processing of customer inquiries
  • Customer support portals that provide assistants for FAQs or self-service
  • Integration into automation tools for the intelligent control of automated workflows, for example with the n8n node
  • Integration into IDEs for AI-supported assistance during development

Calling the Chat Completions API

Use the OpenAI-compatible endpoint /api/v1/chat/completions. Replace the base URL with your VARIOS AI instance address (e.g. https://varios-ai.example.com). Authentication: Pass the API key in the Authorization header as a Bearer token. Model parameter: Set model to either an assistant ID or a chat model ID (a pre-configured model that supports Chat Completions). Only assistants and chat models assigned to the API key can be used.
  • The chat model ID can be found in the URL of the respective model settings page. (e.g. varios-ai.example.com/admin/models/**782d877e-b54f-4598-a32e-4a7d16e221e3**)
  • The assistant ID can be found in the URL of the respective assistant settings page. (e.g. varios-ai.example.com/admin/assistants/**584ab525-7988-4e5d-8140-b03e4c9ee66c**)
Optional parameters:
  • stream: true for streaming responses, false for a complete response in a single reply.
  • stream_options: With {"include_usage": true}, a stream ends with a chunk that has an empty choices array and the token usage under usage, as with OpenAI.
  • dlp_active: Controls DLP only when the API key uses assistant/model settings and the assistant or model DLP is set to optional. true enables DLP, false disables it. If omitted, DLP defaults to on for optional (same as in chat).
Token usage: usage.prompt_tokens counts all prompt tokens, including the tokens read from and written to the prompt cache. usage.prompt_tokens_details breaks them down into cached_tokens (read from the cache) and cache_write_tokens (written to the cache). For assistants, usage sums up all model calls of the request; for chat models, VARIOS AI passes on the figures reported by the provider.

DLP behaviour for API requests

When Enforce DLP is active on the API key, dlp_active in the request is ignored. All requests with this key are subject to VARIOS AI data-protection guardrails.
Tools: Unlike assistant-only flows, requests against a chat model may include a tools array in the JSON body with your own function definitions and references to application tools. To attach an application tool, add a tool whose name is only the reserved name; VARIOS AI resolves it to the full schema. Name formats:
  • Knowledge base: kb_<knowledge-base-id>
  • MCP tool: mcp_<mcp-tool-id>
  • OpenAPI endpoint: openapi_<openapi-endpoint-id>
  • Code connector (e.g. FLUX connector): pf_<connector-id>
Custom tools are passed in the same way as with OpenAI, including parameters (JSON Schema). The ID can be taken from the URL of the respective tool, analogous to the chat model ID and assistant ID.

Example: assistant

Set model to the assistant ID. Tooling follows the assistant configuration; a tools array in the request is not used for assistant calls in the same way as for chat models.

Example: chat model

Set model to the chat model ID. You may send tools with application tool names and your own function definitions as described above.
Note Chat completions using chat models do not remove unused fields from the request. This means that any provider‑specific parameters, such as response_format, safety_identifier, or similar, are forwarded exactly as provided. VARIOS AI acts solely as a middleware layer between the client and the model provider and only processes a limited set of predefined fields.

Listing available assistants and models

The /api/v1/models endpoint returns every assistant and chat model assigned to this API key. Authentication works as for the Chat Completions endpoint, via the Authorization header. If the API key is invalid, the endpoint responds with status code 401.
boolean
default:"false"
Adds the type field to each entry.
boolean
default:"false"
Adds the dlp, dlp_active and dlp_enforced fields to each entry.
With these parameters, each entry in the data array additionally contains the following fields:
string
assistant for assistants, model for chat models.
string
The model’s DLP setting or, for assistants, the combination of assistant and model settings (dlp_on, dlp_off or dlp_optional). It does not reflect Enforce DLP on the API key; use dlp_active for the effective state.
boolean
States whether DLP applies to a request that does not send its own dlp_active parameter. The value already accounts for the DLP setting of the API key as well as that of the assistant or model (see DLP behaviour for API requests).
boolean
true when the DLP state is fixed and can no longer be changed through dlp_active in the request.
Clients such as the Office Add-ins use this to show the DLP status of the current selection.

Management

  • Edit: Adjust name, cost limit, DLP setting, assigned assistants, chat models, and tools.
  • Delete: Permanently removes the API key (access is immediately revoked).