---
title: "send message · RUAL Documentation"
description: "Send a message to Claude and get the reply, with built-in cost guard, model allowlist and typed error reporting."
canonical: https://docs.rual.nl/block-types/anthropic/anthropicconnection_message
language: en
---

# send message

This block is part of the [`anthropic`](https://docs.rual.nl/block-types/anthropic) group and was last modified in core [`v15.0.0`](https://docs.rual.nl/core-versions/150000).

Send a message to Claude and get the reply, with built-in cost guard, model allowlist and typed error reporting.

- flow `flow`

- connection required `anthropicconnection`

- memory `anthropicmemory` Optional. A memory (from create memory); prior turns are loaded in and this exchange is appended, so the chat continues across runs.

- prompt required `value` The user message to send to Claude.

- system `value` Optional frozen system prompt. Keep it stable to benefit from prompt caching.

- attachments `file` Images and/or PDFs to send with the prompt; wire any file block (upload, generate PDF, download…). Claude reads them as part of the message. Tip: for large or expensive runs (e.g. Opus), run documents through preflight first to convert and shrink them cheaply.

- model `value` Model ID. Defaults to claude-opus-4-8. Newer IDs are accepted even if not listed. • Suggestions: `claude-opus-4-8` `claude-fable-5` `claude-opus-4-7` `claude-sonnet-4-6` `claude-haiku-4-5`

- max tokens `number` Maximum output tokens. Default 16000.

- thinking `condition` Enable adaptive thinking.

- citations `condition` Enable source citations on document attachments: the reply cites the passages it used (see the citations out-pin).

- cache `condition` Cache the system prompt (ephemeral) for repeated calls.

- effort `value` Reasoning effort: low | medium | high | xhigh | max. • Suggestions: `low` `medium` `high` `xhigh` `max`

- output template `anthropicschema` Output template. When set, the reply is constrained to valid JSON matching it and parsed onto the response pin (structured output). Build it with the 'build output template' block (or cast raw JSON with 'output template from JSON'). Cannot be combined with tools. • Hidden when other fields are filled

- tools `anthropictool` A tool Claude may call (build tool, web search tool, code execution tool, memory tool). For several tools use the 'multiple' block; for conditional tools use the tool if / switch blocks. Cannot be combined with an output template. • Hidden when other fields are filled

- max tool iterations `number` Safety cap on tool-call rounds in the agentic loop. Default 10. • Hidden when unused

- flow `flow`

- connection `anthropicconnection`

- memory `anthropicmemory` The memory, passed through with this turn appended; chain it into the next send message.

- success `condition` Claude replied normally.

- text `value` The reply text.

- response `object` The parsed object when an output template was set (structured output).

- citations `array ` Source references (when citations enabled): {cited_text, document_index, document_title?, start/end_char_index?, start/end_page?}.

- usage `object` Token counts plus the call cost: input_tokens, output_tokens, cache_read_input_tokens, cache_creation_input_tokens, cost_usd.

- stop reason `value`

- partial `value` Truncated text when stopped at max_tokens.

- errors `array ` Error codes when the call fails (success=false): config_error, internal_error, model_not_allowed, budget_exceeded, concurrency_limit_exceeded, rate_limited, refused, max_tokens, max_iterations, transport_error.

- warnings `array ` Non-fatal notices: cost_unknown (served model not in the price table, cost reported as 0); schema_ignored (output template dropped because tools were also set).

- error detail `value` Human-readable detail for the first error.

- tool calls `array ` Trace of every tool the agentic loop ran: {name, input, result, error}.

| `claude` |
| --- |
| `anthropic` |
| `llm` |
| `ai` |
| `ask ai` |
| `prompt claude` |
| `ask claude` |

The standard AI endpoint shape: a [function trigger](https://docs.rual.nl/block-types/globals/trigger_custom_function) runs the chain, [open connection](https://docs.rual.nl/block-types/anthropic/function_create_anthropicconnection) creates the Anthropic connection, and [send message](https://docs.rual.nl/block-types/anthropic/anthropicconnection_message) asks Claude with the request body text as the prompt, read off the body by [get fields](https://docs.rual.nl/block-types/object/object_field_getter_multiple). An [output template](https://docs.rual.nl/block-types/anthropic/anthropicconnection_build_schema) on the output_schema pin keeps the answer valid JSON, and [reply in JSON](https://docs.rual.nl/block-types/http%20connection/httpconnection_set_json) returns it to the caller with a 200.

![Studio canvas example for the send message block: from API request to AI answer to JSON reply.](https://docs.rual.nl/canvas-examples/anthropicconnection_message.png)

### Version history

Introduced in [`v15.0.0`](https://docs.rual.nl/core-versions/150000).
