// 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 armiotfirmwaredefense_test

import (
	"context"
	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/iotfirmwaredefense/armiotfirmwaredefense/v2"
	"log"
)

// Generated from example definition: 2025-08-02/Workspaces_Create_MaximumSet_Gen.json
func ExampleWorkspacesClient_Create_workspacesCreateMaximumSetGenGeneratedByMaximumSetRule() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewWorkspacesClient().Create(ctx, "rgiotfirmwaredefense", "exampleWorkspaceName", armiotfirmwaredefense.Workspace{
		Properties: &armiotfirmwaredefense.WorkspaceProperties{},
		Tags: map[string]*string{
			"key4630": to.Ptr("rov"),
		},
		Location: to.Ptr("East US"),
		SKU: &armiotfirmwaredefense.SKU{
			Name:     to.Ptr("Free"),
			Tier:     to.Ptr(armiotfirmwaredefense.SKUTierFree),
			Size:     to.Ptr("Free"),
			Family:   to.Ptr("F"),
			Capacity: to.Ptr[int32](30),
		},
	}, 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 = armiotfirmwaredefense.WorkspacesClientCreateResponse{
	// 	Workspace: &armiotfirmwaredefense.Workspace{
	// 		Properties: &armiotfirmwaredefense.WorkspaceProperties{
	// 			ProvisioningState: to.Ptr(armiotfirmwaredefense.ProvisioningStateSucceeded),
	// 		},
	// 		Tags: map[string]*string{
	// 		},
	// 		Location: to.Ptr("East US"),
	// 		SKU: &armiotfirmwaredefense.SKU{
	// 			Name: to.Ptr("Free"),
	// 			Tier: to.Ptr(armiotfirmwaredefense.SKUTierFree),
	// 			Size: to.Ptr("Free"),
	// 			Family: to.Ptr("F"),
	// 			Capacity: to.Ptr[int32](30),
	// 		},
	// 		ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName/providers/Microsoft.IoTFirmwareDefense/workspaces/WorkspaceName"),
	// 		Name: to.Ptr("WorkspaceName"),
	// 		Type: to.Ptr("Microsoft.IoTFirmwareDefense/workspaces"),
	// 		SystemData: &armiotfirmwaredefense.SystemData{
	// 			CreatedBy: to.Ptr("UserName"),
	// 			CreatedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
	// 			CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
	// 			LastModifiedBy: to.Ptr("UserName"),
	// 			LastModifiedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
	// 			LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
	// 		},
	// 	},
	// }
}

// Generated from example definition: 2025-08-02/Workspaces_Create_MinimumSet_Gen.json
func ExampleWorkspacesClient_Create_workspacesCreateMinimumSetGen() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewWorkspacesClient().Create(ctx, "rgworkspaces", "exampleWorkspaceName", armiotfirmwaredefense.Workspace{
		Properties: &armiotfirmwaredefense.WorkspaceProperties{},
		Location:   to.Ptr("East US"),
	}, 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 = armiotfirmwaredefense.WorkspacesClientCreateResponse{
	// 	Workspace: &armiotfirmwaredefense.Workspace{
	// 		Name: to.Ptr("blah"),
	// 		Type: to.Ptr("Microsoft.IoTFirmwareDefense/workspaces"),
	// 		ID: to.Ptr("/subscriptions/blah/resourceGroups/blah/providers/blah/workspaces/blah"),
	// 		Location: to.Ptr("East US"),
	// 	},
	// }
}

// Generated from example definition: 2025-08-02/Workspaces_Delete_MaximumSet_Gen.json
func ExampleWorkspacesClient_BeginDelete_workspacesDeleteMaximumSetGenGeneratedByMaximumSetRule() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewWorkspacesClient().BeginDelete(ctx, "rgiotfirmwaredefense", "exampleWorkspaceName", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	_, err = poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
}

// Generated from example definition: 2025-08-02/Workspaces_Delete_MinimumSet_Gen.json
func ExampleWorkspacesClient_BeginDelete_workspacesDeleteMinimumSetGen() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewWorkspacesClient().BeginDelete(ctx, "rgworkspaces", "default", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	_, err = poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
}

// Generated from example definition: 2025-08-02/Workspaces_GenerateUploadUrl_MaximumSet_Gen.json
func ExampleWorkspacesClient_GenerateUploadURL_workspacesGenerateUploadUrlMaximumSetGenGeneratedByMaximumSetRule() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewWorkspacesClient().GenerateUploadURL(ctx, "rgiotfirmwaredefense", "exampleWorkspaceName", armiotfirmwaredefense.GenerateUploadURLRequest{
		FirmwareID: to.Ptr("00000000-0000-0000-0000-000000000000"),
	}, 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 = armiotfirmwaredefense.WorkspacesClientGenerateUploadURLResponse{
	// 	URLToken: &armiotfirmwaredefense.URLToken{
	// 		URL: to.Ptr("https://microsoft.com/a"),
	// 	},
	// }
}

// Generated from example definition: 2025-08-02/Workspaces_GenerateUploadUrl_MinimumSet_Gen.json
func ExampleWorkspacesClient_GenerateUploadURL_workspacesGenerateUploadUrlMinimumSetGen() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewWorkspacesClient().GenerateUploadURL(ctx, "rgworkspaces", "default", armiotfirmwaredefense.GenerateUploadURLRequest{
		FirmwareID: to.Ptr("00000000-0000-0000-0000-000000000000"),
	}, 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 = armiotfirmwaredefense.WorkspacesClientGenerateUploadURLResponse{
	// 	URLToken: &armiotfirmwaredefense.URLToken{
	// 	},
	// }
}

// Generated from example definition: 2025-08-02/Workspaces_Get_MaximumSet_Gen.json
func ExampleWorkspacesClient_Get_workspacesGetMaximumSetGenGeneratedByMaximumSetRule() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("5C707B5F-6130-4F71-819E-953A28942E88", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewWorkspacesClient().Get(ctx, "rgiotfirmwaredefense", "exampleWorkspaceName", 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 = armiotfirmwaredefense.WorkspacesClientGetResponse{
	// 	Workspace: &armiotfirmwaredefense.Workspace{
	// 		Properties: &armiotfirmwaredefense.WorkspaceProperties{
	// 			ProvisioningState: to.Ptr(armiotfirmwaredefense.ProvisioningStateSucceeded),
	// 		},
	// 		Tags: map[string]*string{
	// 			"key4693": to.Ptr("vjtehzjgosg"),
	// 		},
	// 		Location: to.Ptr("East US"),
	// 		SKU: &armiotfirmwaredefense.SKU{
	// 			Name: to.Ptr("Free"),
	// 			Tier: to.Ptr(armiotfirmwaredefense.SKUTierFree),
	// 			Size: to.Ptr("Free"),
	// 			Family: to.Ptr("Free"),
	// 			Capacity: to.Ptr[int32](25),
	// 		},
	// 		ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName/providers/Microsoft.IoTFirmwareDefense/workspaces/WorkspaceName"),
	// 		Name: to.Ptr("WorkspaceName"),
	// 		Type: to.Ptr("Microsoft.IoTFirmwareDefense/workspaces"),
	// 		SystemData: &armiotfirmwaredefense.SystemData{
	// 			CreatedBy: to.Ptr("UserName"),
	// 			CreatedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
	// 			CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
	// 			LastModifiedBy: to.Ptr("UserName"),
	// 			LastModifiedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
	// 			LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
	// 		},
	// 	},
	// }
}

// Generated from example definition: 2025-08-02/Workspaces_Get_MinimumSet_Gen.json
func ExampleWorkspacesClient_Get_workspacesGetMinimumSetGen() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewWorkspacesClient().Get(ctx, "rgworkspaces", "E_US", 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 = armiotfirmwaredefense.WorkspacesClientGetResponse{
	// 	Workspace: &armiotfirmwaredefense.Workspace{
	// 		Name: to.Ptr("E_US"),
	// 		Type: to.Ptr("Microsoft.IoTFirmwareDefense/workspaces"),
	// 		ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rgworkspaces/providers/Microsoft.IoTFirmwareDefense/workspaces/E_US"),
	// 		Location: to.Ptr("East US"),
	// 	},
	// }
}

// Generated from example definition: 2025-08-02/Workspaces_ListByResourceGroup_MaximumSet_Gen.json
func ExampleWorkspacesClient_NewListByResourceGroupPager_workspacesListByResourceGroupMaximumSetGenGeneratedByMaximumSetRule() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewWorkspacesClient().NewListByResourceGroupPager("rgiotfirmwaredefense", nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page = armiotfirmwaredefense.WorkspacesClientListByResourceGroupResponse{
		// 	WorkspaceListResult: armiotfirmwaredefense.WorkspaceListResult{
		// 		Value: []*armiotfirmwaredefense.Workspace{
		// 			{
		// 				Location: to.Ptr("East US"),
		// 				Properties: &armiotfirmwaredefense.WorkspaceProperties{
		// 					ProvisioningState: to.Ptr(armiotfirmwaredefense.ProvisioningStateSucceeded),
		// 				},
		// 				SKU: &armiotfirmwaredefense.SKU{
		// 					Name: to.Ptr("Free"),
		// 					Tier: to.Ptr(armiotfirmwaredefense.SKUTierFree),
		// 					Size: to.Ptr("Free"),
		// 					Family: to.Ptr("Free"),
		// 					Capacity: to.Ptr[int32](20),
		// 				},
		// 				Tags: map[string]*string{
		// 					"key48": to.Ptr("awsscelvaadnuiworjganuct"),
		// 				},
		// 				ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName/providers/Microsoft.IoTFirmwareDefense/workspaces/WorkspaceName"),
		// 				Name: to.Ptr("WorkspaceName"),
		// 				Type: to.Ptr("Microsoft.IoTFirmwareDefense/workspaces"),
		// 				SystemData: &armiotfirmwaredefense.SystemData{
		// 					CreatedBy: to.Ptr("UserName"),
		// 					CreatedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
		// 					CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
		// 					LastModifiedBy: to.Ptr("UserName"),
		// 					LastModifiedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
		// 					LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
		// 				},
		// 			},
		// 		},
		// 		NextLink: to.Ptr("https://microsoft.com/a"),
		// 	},
		// }
	}
}

// Generated from example definition: 2025-08-02/Workspaces_ListByResourceGroup_MinimumSet_Gen.json
func ExampleWorkspacesClient_NewListByResourceGroupPager_workspacesListByResourceGroupMinimumSet() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewWorkspacesClient().NewListByResourceGroupPager("rgiotfirmwaredefense", nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page = armiotfirmwaredefense.WorkspacesClientListByResourceGroupResponse{
		// 	WorkspaceListResult: armiotfirmwaredefense.WorkspaceListResult{
		// 		Value: []*armiotfirmwaredefense.Workspace{
		// 			{
		// 				Location: to.Ptr("East US"),
		// 				ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName/providers/Microsoft.IoTFirmwareDefense/workspaces/WorkspaceName"),
		// 			},
		// 		},
		// 	},
		// }
	}
}

// Generated from example definition: 2025-08-02/Workspaces_ListBySubscription_MaximumSet_Gen.json
func ExampleWorkspacesClient_NewListBySubscriptionPager_workspacesListBySubscriptionMaximumSetGenGeneratedByMaximumSetRule() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewWorkspacesClient().NewListBySubscriptionPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page = armiotfirmwaredefense.WorkspacesClientListBySubscriptionResponse{
		// 	WorkspaceListResult: armiotfirmwaredefense.WorkspaceListResult{
		// 		Value: []*armiotfirmwaredefense.Workspace{
		// 			{
		// 				Location: to.Ptr("East US"),
		// 				ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName/providers/Microsoft.IoTFirmwareDefense/workspaces/WorkspaceName"),
		// 				Properties: &armiotfirmwaredefense.WorkspaceProperties{
		// 					ProvisioningState: to.Ptr(armiotfirmwaredefense.ProvisioningStateSucceeded),
		// 				},
		// 				SKU: &armiotfirmwaredefense.SKU{
		// 					Name: to.Ptr("Free"),
		// 					Tier: to.Ptr(armiotfirmwaredefense.SKUTierFree),
		// 					Size: to.Ptr("Free"),
		// 					Family: to.Ptr("Free"),
		// 					Capacity: to.Ptr[int32](20),
		// 				},
		// 				Tags: map[string]*string{
		// 					"key9484": to.Ptr("emizfeemymb"),
		// 				},
		// 				Name: to.Ptr("WorkspaceName"),
		// 				Type: to.Ptr("Microsoft.IoTFirmwareDefense/workspaces"),
		// 				SystemData: &armiotfirmwaredefense.SystemData{
		// 					CreatedBy: to.Ptr("UserName"),
		// 					CreatedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
		// 					CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
		// 					LastModifiedBy: to.Ptr("UserName"),
		// 					LastModifiedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
		// 					LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
		// 				},
		// 			},
		// 		},
		// 		NextLink: to.Ptr("https://microsoft.com/a"),
		// 	},
		// }
	}
}

// Generated from example definition: 2025-08-02/Workspaces_ListBySubscription_MinimumSet_Gen.json
func ExampleWorkspacesClient_NewListBySubscriptionPager_workspacesListBySubscriptionMaximumSetGenGeneratedByMinimumSetRule() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewWorkspacesClient().NewListBySubscriptionPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page = armiotfirmwaredefense.WorkspacesClientListBySubscriptionResponse{
		// 	WorkspaceListResult: armiotfirmwaredefense.WorkspaceListResult{
		// 		Value: []*armiotfirmwaredefense.Workspace{
		// 			{
		// 				ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName/providers/Microsoft.IoTFirmwareDefense/workspaces/WorkspaceName"),
		// 				Location: to.Ptr("East US"),
		// 			},
		// 		},
		// 	},
		// }
	}
}

// Generated from example definition: 2025-08-02/Workspaces_Update_MaximumSet_Gen.json
func ExampleWorkspacesClient_Update_workspacesUpdateMaximumSetGenGeneratedByMaximumSetRule() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewWorkspacesClient().Update(ctx, "rgiotfirmwaredefense", "exampleWorkspaceName", armiotfirmwaredefense.WorkspaceUpdate{
		Tags: map[string]*string{},
		SKU: &armiotfirmwaredefense.SKU{
			Name:     to.Ptr("Free"),
			Tier:     to.Ptr(armiotfirmwaredefense.SKUTierFree),
			Size:     to.Ptr("Free"),
			Family:   to.Ptr("Free"),
			Capacity: to.Ptr[int32](25),
		},
	}, 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 = armiotfirmwaredefense.WorkspacesClientUpdateResponse{
	// 	Workspace: &armiotfirmwaredefense.Workspace{
	// 		Properties: &armiotfirmwaredefense.WorkspaceProperties{
	// 			ProvisioningState: to.Ptr(armiotfirmwaredefense.ProvisioningStateSucceeded),
	// 		},
	// 		Tags: map[string]*string{
	// 			"key4978": to.Ptr("ujdbllhyqeunsgpqtiq"),
	// 		},
	// 		Location: to.Ptr("East US"),
	// 		SKU: &armiotfirmwaredefense.SKU{
	// 			Name: to.Ptr("Free"),
	// 			Tier: to.Ptr(armiotfirmwaredefense.SKUTierFree),
	// 			Size: to.Ptr("Free"),
	// 			Family: to.Ptr("Free"),
	// 			Capacity: to.Ptr[int32](25),
	// 		},
	// 		ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName/providers/Microsoft.IoTFirmwareDefense/workspaces/WorkspaceName"),
	// 		Name: to.Ptr("WorkspaceName"),
	// 		Type: to.Ptr("Microsoft.IoTFirmwareDefense/workspaces"),
	// 		SystemData: &armiotfirmwaredefense.SystemData{
	// 			CreatedBy: to.Ptr("UserName"),
	// 			CreatedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
	// 			CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
	// 			LastModifiedBy: to.Ptr("UserName"),
	// 			LastModifiedByType: to.Ptr(armiotfirmwaredefense.CreatedByTypeUser),
	// 			LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2024-06-13T15:22:45.940Z"); return t}()),
	// 		},
	// 	},
	// }
}

// Generated from example definition: 2025-08-02/Workspaces_Update_MinimumSet_Gen.json
func ExampleWorkspacesClient_Update_workspacesUpdateMinimumSetGen() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armiotfirmwaredefense.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewWorkspacesClient().Update(ctx, "rgworkspaces", "WorkspaceName", armiotfirmwaredefense.WorkspaceUpdate{}, 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 = armiotfirmwaredefense.WorkspacesClientUpdateResponse{
	// 	Workspace: &armiotfirmwaredefense.Workspace{
	// 		Location: to.Ptr("East US"),
	// 	},
	// }
}
