MockableHciSubscriptionResource.GetOsImage Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Get a os image.
- Request Path. : /subscriptions/{subscriptionId}/providers/Microsoft.AzureStackHCI/locations/{location}/osImages/{osImageName}.
- Operation Id. : OsImages_Get.
- Default Api Version. : 2026-04-01-preview.
public virtual Azure.Response<Azure.ResourceManager.Hci.OsImageResource> GetOsImage(Azure.Core.AzureLocation location, string osImageName, System.Threading.CancellationToken cancellationToken = default);
abstract member GetOsImage : Azure.Core.AzureLocation * string * System.Threading.CancellationToken -> Azure.Response<Azure.ResourceManager.Hci.OsImageResource>
override this.GetOsImage : Azure.Core.AzureLocation * string * System.Threading.CancellationToken -> Azure.Response<Azure.ResourceManager.Hci.OsImageResource>
Public Overridable Function GetOsImage (location As AzureLocation, osImageName As String, Optional cancellationToken As CancellationToken = Nothing) As Response(Of OsImageResource)
Parameters
- location
- AzureLocation
The location for the resource.
- osImageName
- String
The name of the OsImage.
- cancellationToken
- CancellationToken
The cancellation token to use.
Returns
Exceptions
osImageName is null.
osImageName is an empty string, and was expected to be non-empty.