# DocumentDBVersions Properties

- Package: [Aspire.Hosting.DocumentDB](/reference/api/csharp/aspire.hosting.documentdb.md)
- Type: [DocumentDBVersions](/reference/api/csharp/aspire.hosting.documentdb/documentdbversions.md)
- Kind: `Properties`
- Members: `2`

String constants and lookup helpers for the DocumentDB versions known to this build of the package.

## All

- Name: `All`
- Modifiers: `static` `get`
- Returns: `IReadOnlyList<string>`
- Source: [GitHub](https://github.com/microsoft/azure-databases-aspire/blob/d8d44d4322ce04a98c27e15113a2ecacf12152d8//home/runner/work/azure-databases-aspire/azure-databases-aspire/src/Aspire.Hosting.DocumentDB/DocumentDBVersion.cs#L101)

All DocumentDB versions known to this build of the package, sorted ascending by numeric semantic version. The order of this list is part of the contract: `All[All.Count - 1]` is always the newest known version.

```csharp
public static IReadOnlyList<string> All { get; }
```

## Remarks

The returned instance is a read-only wrapper that cannot be downcast to a mutable array. This protects [DocumentDBVersions.Latest](/reference/api/csharp/aspire.hosting.documentdb/documentdbversions/properties.md#latest) (which reads from this list) from being silently changed at runtime.

## Latest

- Name: `Latest`
- Modifiers: `static` `get`
- Returns: `string`
- Source: [GitHub](https://github.com/microsoft/azure-databases-aspire/blob/d8d44d4322ce04a98c27e15113a2ecacf12152d8//home/runner/work/azure-databases-aspire/azure-databases-aspire/src/Aspire.Hosting.DocumentDB/DocumentDBVersion.cs#L122)

The newest DocumentDB version known to this build of the package. This is the version applied by default when no explicit version is selected via [DocumentDBBuilderExtensions.WithDocumentDBVersion(IResourceBuilder<DocumentDBServerResource>, DocumentDBVersion)](/reference/api/csharp/aspire.hosting.documentdb/documentdbbuilderextensions/methods.md#withdocumentdbversion-iresourcebuilder-documentdbserverresource-documentdbversion).

```csharp
public static string Latest { get; }
```

## Remarks

This value reflects the latest version this package was built against, not the latest upstream release at runtime. Upgrade the NuGet package to pick up newer upstream versions. Exposed as a property so consumers re-resolve it after upgrading the package, rather than inlining the value at compile time as a `const` would do.
