# AzureContainerRegistryResource

- Kind: `class`
- Package: [Aspire.Hosting.Azure.ContainerRegistry](/reference/api/csharp/aspire.hosting.azure.containerregistry.md)
- Version: `13.4.0`
- Namespace: `Aspire.Hosting.Azure`
- Target framework: `net8.0`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/cbc352350f1a9bafbaff10d14a2c8de4ac186a48/src/Aspire.Hosting.Azure.ContainerRegistry/AzureContainerRegistryResource.cs)
- Inherits: `AzureProvisioningResource`
- Implements: `IAzureResource`, `IContainerRegistry`, `IResource`, `IAzureContainerRegistryResource`, `IAzurePrivateEndpointTarget`

Represents an Azure Container Registry resource.

## Definition

```csharp
namespace Aspire.Hosting.Azure;

public class AzureContainerRegistryResource
    : Aspire.Hosting.Azure.AzureProvisioningResource,
      Aspire.Hosting.ApplicationModel.IAzureResource,
      Aspire.Hosting.ApplicationModel.IContainerRegistry,
      Aspire.Hosting.ApplicationModel.IResource,
      Aspire.Hosting.Azure.IAzureContainerRegistryResource,
      Aspire.Hosting.Azure.IAzurePrivateEndpointTarget
{
    // ...
}
```

## Constructors

- [AzureContainerRegistryResource(string, Action<AzureResourceInfrastructure>)](/reference/api/csharp/aspire.hosting.azure.containerregistry/azurecontainerregistryresource/constructors.md#constructor-string-action-azureresourceinfrastructure) -- Initializes a new instance of the [AzureContainerRegistryResource](/reference/api/csharp/aspire.hosting.azure.containerregistry/azurecontainerregistryresource.md) class.

## Properties

- [Id](/reference/api/csharp/aspire.hosting.azure.containerregistry/azurecontainerregistryresource/properties.md#id) : `BicepOutputReference` `get` -- Gets the "id" output reference for the Azure Container Registry resource.
- [NameOutputReference](/reference/api/csharp/aspire.hosting.azure.containerregistry/azurecontainerregistryresource/properties.md#nameoutputreference) : `BicepOutputReference` `get` -- The name of the Azure Container Registry.
- [RegistryEndpoint](/reference/api/csharp/aspire.hosting.azure.containerregistry/azurecontainerregistryresource/properties.md#registryendpoint) : `BicepOutputReference` `get` -- The endpoint of the Azure Container Registry.

## Methods

- [AddAsExistingResource(AzureResourceInfrastructure)](/reference/api/csharp/aspire.hosting.azure.containerregistry/azurecontainerregistryresource/methods.md#addasexistingresource-azureresourceinfrastructure) : `ProvisionableResource`
