# RedPandaServerResource.WithKafkaUI

- Module: [CommunityToolkit.Aspire.Hosting.RedPanda](/reference/api/go/communitytoolkit.aspire.hosting.redpanda.md)
- Defined on: [RedPandaServerResource](/reference/api/go/communitytoolkit.aspire.hosting.redpanda/redpandaserverresource.md)
- Version: `13.6.1`
- Kind: `method`

Adds a Kafka UI container to the application, configured to connect to the Redpanda broker. This is the same Kafka management UI (the `kafbat/kafka-ui` image) used by the official Aspire Kafka integration, so it works against any Kafka API compatible broker.

## Remarks

This version of the package defaults to the tag of the container image.

## Definition

```go
type RedPandaServerResource interface {
    // ... omitted for brevity
    WithKafkaUI(options ...*WithKafkaUIOptions) RedPandaServerResource
}
```

## Signature

```go
WithKafkaUI(options ...*WithKafkaUIOptions) RedPandaServerResource
```

## Parameters

- `options` (`...*WithKafkaUIOptions`) -- optional settings, see [Options](#options)

## Options

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

- `ConfigureContainer` (`func(obj RedPandaKafkaUiContainerResource)`) `callback` -- An optional callback to configure the Kafka UI container resource.
- `ContainerName` (`*string`) -- The name of the container (optional).

## Returns

[`RedPandaServerResource`](/reference/api/go/communitytoolkit.aspire.hosting.redpanda/redpandaserverresource.md) -- A reference to the `IResourceBuilder` for the Redpanda server resource.

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

## Defined on

- [RedPandaServerResource](/reference/api/go/communitytoolkit.aspire.hosting.redpanda/redpandaserverresource.md) -- `handle`
