Overview
This node sends messages to an AMQP 1.0 compatible message broker, such as RabbitMQ or Apache Qpid, using the AMQP protocol. It publishes raw messages to a specified queue or topic, allowing integration with messaging systems that support AMQP.
Common scenarios include:
- Sending event notifications or commands to distributed systems.
- Integrating n8n workflows with enterprise messaging infrastructures.
- Publishing data streams or logs to message queues for asynchronous processing.
For example, you can use this node to send JSON payloads to a topic in a message broker, which downstream consumers then process asynchronously.
Properties
| Name | Meaning |
|---|---|
| Queue / Topic | The name of the AMQP queue or topic to publish the message to (e.g., topic://sourcename.something). |
| Headers | Header parameters as a flat JSON object; these are sent as application properties in the AMQP message metadata. |
| Options | A collection of optional settings: |
| - Container ID | Identifier passed to the underlying AMQP client backend. |
| - Data as Object | Whether to send the data as a JavaScript object (true) or as a JSON string (false). |
| - Reconnect | Whether to automatically reconnect if the connection is lost (true/false). |
| - Reconnect Limit | Maximum number of automatic reconnect attempts allowed. |
| - Send Property | If set, only this property from each input item will be sent; otherwise, the entire item is sent. |
Output
The node outputs an array of items corresponding to the input items. Each output item contains a json field with:
id: The internal identifier of the sent AMQP message (if available).
If an error occurs and "Continue On Fail" is enabled, the output item will contain an error field describing the failure.
The node does not output binary data.
Dependencies
- Requires an AMQP 1.0 compatible message broker accessible via network.
- Requires credentials containing connection details (host, port, username, password, TLS options).
- Uses the
rhealibrary internally for AMQP communication. - The node expects proper configuration of authentication and transport (including TLS if used).
Troubleshooting
- Connection errors: If the node fails to connect, verify the AMQP broker address, port, and credentials. Check TLS settings if applicable.
- Queue or Topic missing: The node throws an error if the queue/topic name is empty.
- Message sending failures: If the connection drops and reconnect is disabled or reconnect limit is reached, the node will error out.
- Invalid headers JSON: Ensure the Headers property is valid JSON representing a flat object.
- Credential test failure: The node includes a credential test method; use it to validate connection before running the workflow.
Common error messages:
"Queue or Topic required!"— Set a valid queue or topic name.- Connection-related errors with descriptions like
"Disconnected"— Check network connectivity and credentials. - JSON parsing errors on headers — Validate JSON syntax.