EzFlowEzFlow Docs
Node referenceLLM / AI

LLM_COMPLETION

Call an LLM (OpenAI/Anthropic/Gemini) with a prompt; outputs its response.

What it does

Call an LLM (OpenAI/Anthropic/Gemini) with a prompt; outputs its response.

Inputs & outputs

Input handle
userPrompt
Output handle
response

Configuration

NameTypeRequired
provider'openai' | 'anthropic' | 'gemini'Yes
integrationIdstringYes
modelstringYes
systemPromptstringNo
userPromptstringNo
temperaturenumberNo
maxTokensnumberNo
responseFormat'text' | 'json'No

Example

How it works

LLM_COMPLETION sends a prompt to an LLM provider using a bring-your-own key integration. Configure provider (openai, anthropic, or gemini), select the matching integration ID that holds the encrypted API key, and choose a model (e.g. gpt-4o, claude-3-5-sonnet-latest, or gemini-1.5-pro). The node accepts an optional systemPrompt for instructions and a userPrompt that can reference upstream values via backtick-wrapped variable references (e.g. {{text}}). Set responseFormat to json to receive a structured JSON string instead of plain text. The model's reply is available on the response output port.

Example

Scenario: A Slack bot Workflow receives an @-mention and replies with an AI-generated answer.

  1. A SLACK_TRIGGER fires when the bot is mentioned; its text output carries the message.
  2. Add an LLM_COMPLETION node. Set provider to anthropic, model to claude-3-5-sonnet-latest, and wire text from the trigger into the userPrompt input. Add a systemPrompt such as "You are a helpful support assistant.".
  3. Wire the response output to a SEND_SLACK node's message input to post the reply in the same channel.
SLACK_TRIGGER ──(text)──► LLM_COMPLETION ──(response)──► SEND_SLACK

Temperature and maxTokens are optional; leave them blank to use the provider's defaults.

On this page