---
schema_version: "1"
id: 02a9f0e6728f8985288ba7e4b1f3062acc539c23b6106637acd77ac281dfe413
title: Bindings and Parametrized Channels in APIkit for AsyncAPI
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/apikit/latest/apikit-for-asyncapi-supported-bindings.md
canonical_url: https://docs.mulesoft.com/apikit/latest/apikit-for-asyncapi-supported-bindings
source_site: docs.mulesoft.com
content_type: documentation
content_hash: a101f5f77a1b067cf87d8a45799004c94daaf9fe44cf865c5b15e6df7a828ea9
description: MuleSoft Documentation Site
release: 4.x
latest: true
---
---
product: APIkit
version: 4.x
is-latest-version: true
---

# Bindings and Parametrized Channels in APIkit for AsyncAPI

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

APIkit for AsyncAPI maps AsyncAPI channel bindings to Anypoint connectors such as Anypoint MQ,
Kafka, and Solace PubSub+. Use binding parameters to tune publish and subscribe behavior for each
channel. Parametrized channel names let you reuse one channel pattern across many topics or
destinations without duplicating the specification.

## Supported Bindings

### Anypoint Connector for MQ (Anypoint MQ Connector)

<table><colgroup><col> <col> <col> <col> <col></colgroup><thead><tr><th>Binding</th><th>Publish</th><th>Message Listener</th><th>Description</th><th>Reference</th></tr></thead><tbody><tr><td><div><div><p><code>Destination</code></p></div></div></td><td><div><div><p><code>Destination</code></p></div></div></td><td><div><div><p><code>Destination</code></p></div></div></td><td><div><div><p><code>Destination</code> (queue or exchange) name for this channel. It’s optional and defaults to the channel name. Specify it if the channel name differs from the actual <code>destination</code> name. For example, if the channel name isn’t a valid <code>destination</code> name in Anypoint MQ.</p></div></div></td><td rowspan="2"><div><div><p>See <a href="https://github.com/asyncapi/bindings/blob/b1e7736071ccddc6c3d652bb2071cad4549f8a08/anypointmq/README.md">Anypoint MQ Bindings</a>.</p></div></div></td></tr><tr><td><div><div><p><code>DestinationType</code></p></div></div></td><td><div><div><p><code>DestinationType</code></p></div></div></td><td><div><div><p><code>DestinationType</code></p></div></div></td><td><div><div><p>Type of destination (queue or exchange, or FIFO queue). It’s optional and defaults to <code>queue</code>. Specifies the messaging model supported by this channel:</p></div><div><ul><li><p>Publish/subscribe</p></li><li><p>Point-to-point</p></li><li><p>Strict message ordering</p></li></ul></div></div></td></tr></tbody></table>

### Kafka Connector

<table><colgroup><col> <col> <col> <col> <col></colgroup><thead><tr><th>Binding</th><th>Publish</th><th>Message Listener</th><th>Description</th><th>Reference</th></tr></thead><tbody><tr><td><div><div><p><code>Key</code></p></div></div></td><td><div><div><p><code>Key</code></p></div></div></td><td><div><div><p><code>Key</code></p></div></div></td><td><div><div><p>Key associated with the message in this channel. It’s optional and defaults to <code>no key</code>. Specifies if the message requires a specific key for partitioning or message grouping.</p></div></div></td><td><div><div><p>See <a href="https://github.com/asyncapi/bindings/blob/master/kafka/README.md">Kafka bindings</a>.</p></div></div></td></tr></tbody></table>

### Solace PubSub+ Connector

<table><colgroup><col> <col> <col> <col> <col></colgroup><thead><tr><th>Binding</th><th>Publish</th><th>Message Listener</th><th>Description</th><th>Reference</th></tr></thead><tbody><tr><td><div><div><p><code>deliveryMode</code></p></div></div></td><td><div><div><p><code>deliveryMode</code></p></div></div></td><td><div><div><p><code>deliveryMode</code></p></div></div></td><td><div><div><p>Solace PubSub+ Connector operates in <code>direct</code> or <code>persistent</code> mode. The default mode is <code>persistent</code>. The <code>deliveryMode</code> parameter determines the quality of service for publishing messages. The <code>Direct</code> mode offers lower latency but doesn’t guarantee message delivery. The <code>persistent</code> mode ensures that messages are reliably delivered, even in the event of a broker failure.</p></div></div></td><td rowspan="3"><div><div><p>See <a href="https://github.com/asyncapi/bindings/blob/master/solace/README.md">Solace bindings</a>.</p></div></div></td></tr><tr><td><div><div><p><code>destinationType</code></p></div></div></td><td><div><div><p><code>destinationType</code></p></div></div></td><td><div><div><p><code>destinationType</code></p></div></div></td><td><div><div><p>Solace PubSub+ Connector supports <code>queue</code> in APIkit for AsyncAPI.</p></div></div></td></tr><tr><td><div><div><p><code>topicSubscriptions</code></p></div></div></td><td><div><div><p>Not available</p></div></div></td><td><div><div><p><code>topicSubscriptions</code></p></div></div></td><td><div><div><p>Solace PubSub+ Connector specifies the list of topics the queue subscribes to when the <code>destinationType</code> is <code>queue</code>. If you specify no topic, the <code>queue</code> automatically subscribes to the topic the channel name represents.</p></div></div></td></tr></tbody></table>

> [!NOTE] Anypoint Connector for Apache Kafka (Apache Kafka Connector) and Solace PubSub+ Connector
> don’t support bindings.

## Parametrized Channels

APIkit for AsyncAPI supports parametrized channels so you can define dynamic and reusable
configurations, scale your integrations more effectively, and create consistent configurations
across different parts of the integration.

APIkit for AsyncAPI doesn’t support parameters if they’re defined in a binding. For example, a
`destination` in AnypointMQ.

This code provides a partial API spec example with a parameterized `destination`:

```yaml
channels:
  orderAcknowledgement:
    description: new Order Acknowledgment
    servers:
      - anypointMQ
    bindings:
      anypointmq:
        destination: "{env}.amq-asyncapi-poc.orderAcknowledgement"
        destinationType: queue
    parameters:
      env:
        $ref: "#/components/parameters/env"
    publish:
      operationId: listen-order-ack
      description: publish a new Order Acknowledgment event to this channel and we will process it
      message:
        $ref: "#/components/messages/orderAckMessage"
```

You must set the parametrized channel at design time. You can’t set the parametrized channel at
runtime.

See the complete API example using parametrized channels:

asyncapi: '2.6.0' info: title: AMQ-AsyncAPI-PoC version: '1.0.11' description: Proof of Concept for
Anypoint MQ AsyncAPI interface contact: name: Example Company email: address@example.com tags:

- name: WMS description: Warehouse Management System
- name: PoC description: Proof of Concept
- name: Order Acknowledgement

servers: anypointMQ: url:
https://{region}.anypoint.mulesoft.com/api/{version}/organizations/{organizationId}/environments/{environmentId}
protocol: anypointmq protocolVersion: v1 description: The Anypoint MQ broker variables: region:
$ref: '#/components/serverVariables/region'
      version:
        $ref:
'#/components/serverVariables/version' organizationId:
$ref: '#/components/serverVariables/organizationId'
      environmentId:
        $ref:
'#/components/serverVariables/environmentId'

channels: orderAcknowledgement: description: new Order Acknowledgment servers: - anypointMQ
bindings: anypointmq: destination: '{env}.amq-asyncapi-poc.orderAcknowledgement' destinationType:
queue parameters: env:
$ref: '#/components/parameters/env'
    publish:
      operationId: listen-order-ack
      description: publish a new Order Acknowledgment event to this channel and we will process it
      message:
        $ref:
'#/components/messages/orderAckMessage'

components: parameters: env: description: The Mule runtime environment schema: type: string enum: -
dev - tst - acc - prd default: tst serverVariables: region: description: the CloudHub region where
the endpoint is situated enum: - mq-eu-west-1 default: mq-eu-west-1 version: description: the
version of the Anypoint MQ API enum: - v1 default: v1 organizationId: description: the identifier of
our organization (business group) enum: - 7a2b1c3d-4e5f-6g7h-8i9j-0k1l2m3n4o5p environmentId:
description: the identifier of the runtime environment within the organization enum: -
a1b2c3d4-5e6f-7g8h-9i0j-1k2l3m4n5o6p - b2c3d4e5-6f7g-8h9i-0j1k-2l3m4n5o6p -
c3d4e5f6-7g8h-9i0j-1k2l-3m4n5o6p default: a1b2c3d4-5e6f-7g8h-9i0j-1k2l3m4n5o6p messages:
orderAckMessage: name: OrderAckMessage description: an order acknowledgment message. payload: $ref:
'schemas/orderAcknowledgement.json'

> [!NOTE] APIkit for AsyncAPI uses the parametrized channels only on `listeners`.
