
AMQP DeclareExchange
CertifiedCreate an AMQP exchange
AMQP DeclareExchange
Create an AMQP exchange
Declares an exchange on the broker, creating it with the given type and durability if it does not already exist.
type: io.kestra.plugin.amqp.DeclareExchangeExamples
id: amqp_declare_exchange
namespace: company.team
tasks:
- id: declare_exchange
type: io.kestra.plugin.amqp.DeclareExchange
host: localhost
port: 5672
username: guest
password: "{{ secret('AMQP_PASSWORD') }}"
virtualHost: /my_vhost
name: kestramqp.exchange
Properties
host *Requiredstring
Broker host
Hostname or IP of the RabbitMQ broker; required unless using the deprecated url.
name *Requiredstring
The name of the exchange
args object
Other properties (construction arguments) for the exchange
autoDelete booleanstring
falseSpecifies if the server should delete the exchange when it is no longer in use
durability booleanstring
trueSpecifies if declaring a durable exchange (the exchange will survive a server restart)
exchangeType string
DIRECTDIRECTFANOUTTOPICHEADERSCONSISTENT_HASHMODULUS_HASHLOCAL_RANDOMRANDOMThe exchange type
internal booleanstring
falseSpecifies if the exchange is internal, i.e., can't be directly published to by a client
password string
Password
Password for the connection; required when the broker enforces authentication.
pluginDefaultsRef Non-dynamicstring
Reference (ref) of the pluginDefaults to apply to this task.
port string
5672Broker port
TCP port for AMQP connections; defaults to 5672.
username string
Username
Username for the connection; uses broker default (often guest) when not set.
virtualHost string
/Virtual host
Broker virtual host path; defaults to /.
Outputs
exchange string
The exchange name