# AddActiveMQArtemis

- Module: [CommunityToolkit.Aspire.Hosting.ActiveMQ](/reference/api/go/communitytoolkit.aspire.hosting.activemq.md)
- Version: `13.6.1`
- Kind: `method`
- Defined on: `DistributedApplicationBuilder`
- Source: [GitHub](https://github.com/CommunityToolkit/Aspire/tree/d9c2addac6f527ef2e33712d290b84574b455a3b)

Adds a ActiveMQ Artemis container to the application model.

## Remarks

The default image and tag are "apache/activemq-artemis" and "2.42.0".

## Definition

```go
func (DistributedApplicationBuilder) AddActiveMQArtemis(
    name string,
    options ...*AddActiveMQArtemisOptions,
) ActiveMQArtemisServerResource
```

## Parameters

- `name` (`string`) -- The name of the resource. This name will be used as the connection string name when referenced in a dependency.
- `options` (`...*AddActiveMQArtemisOptions`) -- optional settings, see [Options](#options)

## Options

Optional parameters are passed in a trailing `options ...*AddActiveMQArtemisOptions` argument.

- `UserName` (`*ParameterResource`) -- The parameter used to provide the username for the ActiveMQ resource. If `null` a default value will be used.
- `Password` (`*ParameterResource`) -- The parameter used to provide the password for the ActiveMQ resource. If `null` a random password will be generated.
- `Port` (`*float64`) -- The host port that the underlying container is bound to when running locally.
- `Scheme` (`*string`) -- The scheme of the endpoint, e.g. tcp or activemq (for masstransit). Defaults to tcp.
- `WebPort` (`*float64`) -- The host port that the underlying webconsole is bound to when running locally.

## Returns

[`ActiveMQArtemisServerResource`](/reference/api/go/communitytoolkit.aspire.hosting.activemq/activemqartemisserverresource.md) -- A reference to the `IResourceBuilder`.

Returns a handle; failures surface later via `Err()`.

## Applies to

- `DistributedApplicationBuilder`
