Reference · Tools
Claude Chat
Chat with Anthropic Claude models using the Messages API.
The Claude Chat node sends a user message to Anthropic's Messages API and returns the model's reply along with token usage and stop reason. Each item flowing into the node triggers a separate API call, making it straightforward to run per-record summarization, classification, or drafting tasks at scale. For example, you could feed a list of customer support tickets and have Claude draft a suggested reply for each one.
- Node type
- Action
- Parameters
- 8
- Outputs
- Output, Error
- Credentials
- Anthropic
Claude Chat
Chat with Anthropic Claude models using the Messages API.
Overview
Sends a user message to Anthropic’s Claude chat completion API (POST /v1/messages) and returns the model’s response text. Supports Claude Opus, Sonnet, and Haiku models with configurable system prompt, temperature, top_p, top_k, and max_tokens. Each input item produces one API call. The response text is stored in a configurable output field (default: “response”) along with model name, token usage, and stop reason.
Category: AI
Tool Name: claude_chat
Version: 1
Appearance: Icon: anthropic | Color: #d4a574
Node Type
Action — processes input items and produces output
Input / Output
| Direction | Port(s) |
|---|---|
| Input | Input |
| Output | Output, Error |
Credentials
This tool requires Anthropic credentials. See the Credentials Guide for setup instructions.
Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Model | options | No | Claude Sonnet | The Claude model to use for chat completion. Always uses the latest version (auto-updated). |
| Options: Claude Opus (most capable — complex analysis, coding and multi-step reasoning), Claude Sonnet (balanced — strong quality at lower cost and latency), Claude Haiku (fastest — simple tasks, classification and high-volume work). Each option tracks the current release of its tier, so the underlying model ID updates without any change to your node. | ||||
| System Prompt | string | No | — | Optional system prompt to set the model’s behavior and context. Leave empty for default behavior. Supports expressions. |
| User Message | string | Yes | — | The user message to send to Claude. Falls back to item.message or item.prompt if empty. Supports expressions like {{ $json.text }}. |
| Attachment File ID | string | No | — | Optional Anthropic file_id from a previous Claude File Upload node. When set, the file is attached to the user message alongside your text. Falls back to item.fileId if empty. Supports expressions. |
| Attachment Type | options | No | document | How Claude should interpret the attached file. Ignored when Attachment File ID is empty. |
Options: document (PDF, plaintext, or other document file), image (JPG, PNG, GIF, or WebP image) | ||||
| Options | collection | No | {} | Advanced sampling and output settings. |
| — Max Tokens | number | No | 4096 | Maximum number of tokens to generate in the response. |
| — Temperature | number | No | 1 | Sampling temperature (0-1). Lower values are more deterministic, higher values more creative. |
| — Top P | number | No | — | Nucleus sampling: only consider tokens with cumulative probability up to this value. |
| — Top K | number | No | — | Only sample from the top K most likely tokens at each step. |
| — Response Field Name | string | No | response | The output field name where the Claude response text will be stored. |
| Include Input | boolean | No | false | Whether to include the original input item fields in the output alongside the response. |
| Max Concurrency | number | No | 10 | Maximum number of items to process concurrently. |
Output Data
One API call per input item, and one output item per input item. The response text lands on the field named by Response Field Name (response by default), and binary data on the input item is forwarded unchanged. With Include Input on, the original item fields are merged in alongside the result.
{
"response": "The model's reply text",
"model": "claude-...",
"usage": { "input_tokens": 412, "output_tokens": 268 },
"stopReason": "end_turn"
}
modelis the model that actually answered, as reported by Anthropic.usageis the token accounting Anthropic returned for the call.stopReasonsays why generation stopped — for exampleend_turn(finished naturally) ormax_tokens(hit the Max Tokens cap).
Reference the result downstream by expression, e.g. {{ $json.response }}.
Usage Examples
- Ask Claude a question and get a text response
- Summarize text using Claude Sonnet
- Generate creative content with a system prompt
- Classify input items using Claude Haiku for speed
- Extract structured information from unstructured text
Example Configuration
Minimal — send one message per item:
{
"type": "claude_chat",
"parameters": {
"userMessage": "Summarize the following article: {{ $json.articleText }}"
}
}
Add a system prompt to control tone and format:
{
"type": "claude_chat",
"parameters": {
"systemPrompt": "You are a concise technical writer. Respond only with well-structured bullet points.",
"userMessage": "Explain the concept of backpressure in stream processing.",
"includeInput": false,
"maxConcurrency": 10
}
}
Deterministic classification into a named output field:
{
"type": "claude_chat",
"parameters": {
"systemPrompt": "Classify the sentiment of the input text. Respond with exactly one word: POSITIVE, NEGATIVE, or NEUTRAL.",
"userMessage": "{{ $json.reviewText }}",
"includeInput": true,
"maxConcurrency": 20,
"options": {
"maxTokens": 10,
"temperature": 0,
"responseFieldName": "sentiment"
}
}
}
Ask a question about a file uploaded by a Claude File Upload node:
{
"type": "claude_chat",
"parameters": {
"userMessage": "What are the payment terms in this contract?",
"attachmentFileId": "{{ $json.fileId }}",
"attachmentType": "document",
"options": {
"maxTokens": 1024,
"temperature": 0.2,
"responseFieldName": "contractAnswer"
}
}
}
Error Handling
| Mode | Behavior |
|---|---|
| stop | Halts workflow on first error |
| continue | Skips failed items, passes successful ones through |
| errorPort | Routes failed items to Error output port |
Tips
Claude Chat sends user messages to the Anthropic Messages API and returns conversational responses from Claude Opus, Sonnet, or Haiku models. Use it when a workflow step requires natural language generation, reasoning, or instruction-following with configurable temperature, top_p, top_k, and max_tokens parameters. Each input item produces one API call, and the output fields include response text, model name, token usage counts, and stop reason.
Frequently asked questions
Which Claude models can I use with this node?
The node supports Claude Opus, Sonnet, and Haiku. Opus is the most capable, Haiku is the fastest and cheapest, and Sonnet sits in between. You choose the model in the node's parameters, so you can swap it without rewiring your workflow.
What exactly does the node output — just the response text?
No, it outputs several fields: the response text (stored in a configurable field that defaults to 'response'), the model name that was used, input and output token counts, and the stop reason. The token counts are useful if you need to track API costs or enforce usage budgets downstream.
Where do I put my Anthropic API key?
The node uses the Anthropic credential type. You add it once in BusyBot's credential manager and then select it in the node. You do not paste the key directly into node parameters.
If my workflow processes 50 records, does the node make 50 separate API calls?
Yes. Each input item produces exactly one call to POST /v1/messages. There is no batching. Keep this in mind for large datasets, both for latency and for Anthropic rate limit considerations on your account.
Can I give Claude a system prompt, or is it user messages only?
The node supports a configurable system prompt in addition to the user message. You can set it in the node parameters to give Claude standing instructions, a persona, or output formatting rules that apply to every call made by that node.
Build with the Claude Chat node
Drop it into a workflow, wire it to an agent, or call it on a schedule. You'll need Anthropic credentials first.
Open BusyBotLast updated . Spotted something wrong? Tell us.