# IAzureKeyVaultResource

- Kind: `interface`
- Package: [Aspire.Hosting.Azure](/reference/api/csharp/aspire.hosting.azure.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/IAzureKeyVaultResource.cs)
- Implements: [IAzureResource](/reference/api/csharp/aspire.hosting.azure/iazureresource.md), `IResource`

Represents a resource that represents an Azure Key Vault.

## Definition

```csharp
namespace Aspire.Hosting.Azure;

public interface IAzureKeyVaultResource
    : Aspire.Hosting.ApplicationModel.IAzureResource,
      Aspire.Hosting.ApplicationModel.IResource
{
    // ...
}
```

## ATS metadata

### ATS export

- Type ID: `Aspire.Hosting.Azure/IAzureKeyVaultResource`

## Properties

- [NameOutputReference](/reference/api/csharp/aspire.hosting.azure/iazurekeyvaultresource/properties.md#nameoutputreference) : [BicepOutputReference](/reference/api/csharp/aspire.hosting.azure/bicepoutputreference.md) `abstract` `get` -- Gets the output reference that represents the name of Azure Key Vault resource.
- [SecretResolver](/reference/api/csharp/aspire.hosting.azure/iazurekeyvaultresource/properties.md#secretresolver) : `Func<IAzureKeyVaultSecretReference, CancellationToken, Task<string?>>` `abstract` `get; set` -- Gets or sets the secret resolver function used to resolve secrets at runtime.
- [VaultUriOutputReference](/reference/api/csharp/aspire.hosting.azure/iazurekeyvaultresource/properties.md#vaulturioutputreference) : [BicepOutputReference](/reference/api/csharp/aspire.hosting.azure/bicepoutputreference.md) `abstract` `get` -- Gets the output reference that represents the vault uri for the Azure Key Vault resource.

## Methods

- [GetSecret(string)](/reference/api/csharp/aspire.hosting.azure/iazurekeyvaultresource/methods.md#getsecret-string) : [IAzureKeyVaultSecretReference](/reference/api/csharp/aspire.hosting.azure/iazurekeyvaultsecretreference.md) `abstract` -- Gets a secret reference for the specified secret name.
