# BuildImageSecretValue

- Kind: `record`
- Package: [Aspire.Hosting](/reference/api/csharp/aspire.hosting.md)
- Version: `13.3.0`
- Namespace: `Aspire.Hosting.Publishing`
- Target framework: `net8.0`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/bd20f904cde09ecb9c9ae5116a6f13614bf2d7c2/src/Aspire.Hosting/Publishing/BuildImageSecretValue.cs)
- Implements: `IEquatable<BuildImageSecretValue>`

Represents a resolved build secret with its value and type.

## Definition

```csharp
namespace Aspire.Hosting.Publishing;

public record BuildImageSecretValue
    : System.IEquatable<Aspire.Hosting.Publishing.BuildImageSecretValue>
{
    // ...
}
```

## Constructors

- [BuildImageSecretValue(string?, BuildImageSecretType)](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/constructors.md#constructor-string-buildimagesecrettype) -- Represents a resolved build secret with its value and type.

## Properties

- [Type](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/properties.md#type) : [BuildImageSecretType](/reference/api/csharp/aspire.hosting/buildimagesecrettype.md) `get; init` -- The type of the build secret, indicating whether it is environment-based or file-based.
- [Value](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/properties.md#value) : `string?` `get; init` -- The resolved secret value. For [BuildImageSecretType.Environment](/reference/api/csharp/aspire.hosting/buildimagesecrettype/fields.md) secrets, this is the secret content. For [BuildImageSecretType.File](/reference/api/csharp/aspire.hosting/buildimagesecrettype/fields.md) secrets, this is the file path.

## Methods

- [<Clone>$](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/methods.md#clone) : [BuildImageSecretValue](/reference/api/csharp/aspire.hosting/buildimagesecretvalue.md) `virtual`
- [Deconstruct(string?, BuildImageSecretType)](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/methods.md#deconstruct-string-buildimagesecrettype)
- [Equals(object?)](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/methods.md#equals-object) : `bool` -- Determines whether the specified object is equal to the current object.
- [Equals(BuildImageSecretValue?)](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/methods.md#equals-buildimagesecretvalue) : `bool` `virtual` -- Indicates whether the current object is equal to another object of the same type.
- [GetHashCode](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/methods.md#gethashcode) : `int` -- Serves as the default hash function.
- [op_Equality(BuildImageSecretValue?, BuildImageSecretValue?)](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/methods.md#op-equality-buildimagesecretvalue-buildimagesecretvalue) : `bool` `static`
- [op_Inequality(BuildImageSecretValue?, BuildImageSecretValue?)](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/methods.md#op-inequality-buildimagesecretvalue-buildimagesecretvalue) : `bool` `static`
- [ToString](/reference/api/csharp/aspire.hosting/buildimagesecretvalue/methods.md#tostring) : `string` -- Returns a string that represents the current object.
