// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
// Code generated by Microsoft (R) Go Code Generator. DO NOT EDIT.

package armazurestackhcivm_test

import (
	"context"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/azurestackhci/armazurestackhcivm"
	"log"
)

// Generated from example definition: 2025-06-01-preview/AttestationStatuses_Get.json
func ExampleAttestationStatusesClient_Get() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armazurestackhcivm.NewClientFactory("<subscriptionID>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewAttestationStatusesClient().Get(ctx, "subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.HybridCompute/machines/DemoVM", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res = armazurestackhcivm.AttestationStatusesClientGetResponse{
	// 	AttestationStatus: armazurestackhcivm.AttestationStatus{
	// 		Name: to.Ptr("default"),
	// 		Type: to.Ptr("Microsoft.AzureStackHCI/virtualMachineInstances/AttestationStatus"),
	// 		ID: to.Ptr("/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.HybridCompute/machines/DemoVM/providers/Microsoft.AzureStackHCI/virtualMachineInstances/default/attestationStatus/default"),
	// 		Properties: &armazurestackhcivm.AttestationStatusProperties{
	// 			AttestSecureBootEnabled: to.Ptr(armazurestackhcivm.AttestSecureBootPropertyEnumDisabled),
	// 			AttestationCertValidated: to.Ptr(armazurestackhcivm.AttestCertPropertyEnumInvalid),
	// 			BootIntegrityValidated: to.Ptr(armazurestackhcivm.AttestBootIntegrityPropertyEnumInvalid),
	// 			ErrorMessage: to.Ptr("Attestation token has invalid signature"),
	// 			HealthStatus: to.Ptr(armazurestackhcivm.AttestHealthStatusEnumUnhealthy),
	// 			LinuxKernelVersion: to.Ptr("1.0.0.0"),
	// 			Timestamp: to.Ptr("2023/11/10 9:48"),
	// 		},
	// 	},
	// }
}
