//go:build go1.18
// +build go1.18

// 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) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
// DO NOT EDIT.

package armproviderhub_test

import (
	"context"
	"log"

	"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/providerhub/armproviderhub/v2"
)

// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7611bb6c9bad11244f4351eecfc50b2c46a86fde/specification/providerhub/resource-manager/Microsoft.ProviderHub/stable/2024-09-01/examples/NewRegionFrontloadRelease_GenerateManifest.json
func ExampleNewRegionFrontloadReleaseClient_GenerateManifest() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armproviderhub.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewNewRegionFrontloadReleaseClient().GenerateManifest(ctx, "Microsoft.Contoso", armproviderhub.FrontloadPayload{
		Properties: &armproviderhub.FrontloadPayloadProperties{
			CopyFromLocation: to.Ptr("eastus"),
			EnvironmentType:  to.Ptr(armproviderhub.AvailableCheckInManifestEnvironmentProd),
			ExcludeResourceTypes: []*string{
				to.Ptr("monitors")},
			FrontloadLocation: to.Ptr("Israel Central"),
			IgnoreFields: []*string{
				to.Ptr("apiversion")},
			IncludeResourceTypes: []*string{
				to.Ptr("servers")},
			OperationType: to.Ptr("Rollout"),
			OverrideEndpointLevelFields: &armproviderhub.FrontloadPayloadPropertiesOverrideEndpointLevelFields{
				APIVersion: to.Ptr("2024-04-01-preview"),
				APIVersions: []*string{
					to.Ptr("2024-04-01-preview")},
				DstsConfiguration: &armproviderhub.ResourceTypeEndpointBaseDstsConfiguration{
					ServiceDNSName: to.Ptr("messaging.azure-ppe.net"),
					ServiceName:    to.Ptr("resourceprovider"),
				},
				Enabled:      to.Ptr(true),
				EndpointType: to.Ptr(armproviderhub.EndpointTypeProduction),
				EndpointURI:  to.Ptr("https://resource-endpoint.com/"),
				FeaturesRule: &armproviderhub.ResourceTypeEndpointBaseFeaturesRule{},
				Locations: []*string{
					to.Ptr("East US")},
				RequiredFeatures: []*string{
					to.Ptr("<feature flag>")},
				SKULink: to.Ptr("http://endpointuri/westus/skus"),
				Timeout: to.Ptr("PT20S"),
				Zones: []*string{
					to.Ptr("zone1")},
			},
			OverrideManifestLevelFields: &armproviderhub.FrontloadPayloadPropertiesOverrideManifestLevelFields{
				ResourceHydrationAccounts: []*armproviderhub.ResourceHydrationAccount{
					{
						AccountName:    to.Ptr("classichydrationprodsn01"),
						SubscriptionID: to.Ptr("e4eae963-2d15-43e6-a097-98bd75b33edd"),
					}},
			},
			ProviderNamespace:  to.Ptr("Microsoft.Contoso"),
			ServiceFeatureFlag: to.Ptr(armproviderhub.ServiceFeatureFlagActionDoNotCreate),
		},
	}, 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.ResourceProviderManifest = armproviderhub.ResourceProviderManifest{
	// 	Capabilities: []*armproviderhub.ResourceProviderCapabilities{
	// 		{
	// 			Effect: to.Ptr(armproviderhub.ResourceProviderCapabilitiesEffectAllow),
	// 			QuotaID: to.Ptr("CSP_2015-05-01"),
	// 		},
	// 		{
	// 			Effect: to.Ptr(armproviderhub.ResourceProviderCapabilitiesEffectAllow),
	// 			QuotaID: to.Ptr("CSP_MG_2017-12-01"),
	// 	}},
	// 	CrossTenantTokenValidation: to.Ptr(armproviderhub.CrossTenantTokenValidationEnsureSecureValidation),
	// 	GlobalNotificationEndpoints: []*armproviderhub.ResourceProviderEndpoint{
	// 		{
	// 			Enabled: to.Ptr(true),
	// 			EndpointURI: to.Ptr("https://notificationendpoint.com"),
	// 	}},
	// 	Management: &armproviderhub.ResourceProviderManifestManagement{
	// 		AuthorizationOwners: []*string{
	// 			to.Ptr("authorizationOwners-group")},
	// 			IncidentContactEmail: to.Ptr("helpme@contoso.com"),
	// 			IncidentRoutingService: to.Ptr(""),
	// 			IncidentRoutingTeam: to.Ptr(""),
	// 			ManifestOwners: []*string{
	// 				to.Ptr("manifestOwners-group")},
	// 				ResourceAccessPolicy: to.Ptr(armproviderhub.ResourceAccessPolicyNotSpecified),
	// 			},
	// 			Metadata: map[string]any{
	// 				"onboardedVia": "ProviderHub",
	// 			},
	// 			Namespace: to.Ptr("microsoft.contoso"),
	// 			ProviderAuthorizations: []*armproviderhub.ResourceProviderAuthorization{
	// 				{
	// 					ApplicationID: to.Ptr("1a3b5c7d-8e9f-10g1-1h12-i13j14k1"),
	// 					RoleDefinitionID: to.Ptr("123456bf-gkur-2098-b890-98da392a00b2"),
	// 			}},
	// 			ProviderType: to.Ptr(armproviderhub.ResourceProviderType("Internal, Hidden")),
	// 			ProviderVersion: to.Ptr("2.0"),
	// 			ReRegisterSubscriptionMetadata: &armproviderhub.ResourceProviderManifestReRegisterSubscriptionMetadata{
	// 				ConcurrencyLimit: to.Ptr[int32](100),
	// 				Enabled: to.Ptr(true),
	// 			},
	// 			ResourceProviderAuthorizationRules: &armproviderhub.ResourceProviderAuthorizationRules{
	// 				AsyncOperationPollingRules: &armproviderhub.AsyncOperationPollingRules{
	// 					AuthorizationActions: []*string{
	// 						to.Ptr("Microsoft.Contoso/classicAdministrators/operationStatuses/read")},
	// 					},
	// 				},
	// 				ResourceTypes: []*armproviderhub.ResourceType{
	// 					{
	// 						Name: to.Ptr("Operations"),
	// 						AllowedUnauthorizedActions: []*string{
	// 							to.Ptr("microsoft.contoso/operations/read")},
	// 							AllowedUnauthorizedActionsExtensions: []*armproviderhub.AllowedUnauthorizedActionsExtension{
	// 								{
	// 									Action: to.Ptr("Microsoft.BizTalkServices/bizTalk/read"),
	// 									Intent: to.Ptr(armproviderhub.IntentDEFERREDACCESSCHECK),
	// 							}},
	// 							Endpoints: []*armproviderhub.ResourceProviderEndpoint{
	// 								{
	// 									APIVersions: []*string{
	// 										to.Ptr("2020-01-01-preview")},
	// 										EndpointURI: to.Ptr("https://resource-endpoint.com/"),
	// 										Locations: []*string{
	// 											to.Ptr("")},
	// 											Timeout: to.Ptr("PT20S"),
	// 									}},
	// 									LinkedOperationRules: []*armproviderhub.LinkedOperationRule{
	// 									},
	// 									ResourceValidation: to.Ptr(armproviderhub.ResourceValidation("ReservedWords, ProfaneWords")),
	// 									RoutingType: to.Ptr(armproviderhub.RoutingType("ProxyOnly, Tenant")),
	// 								},
	// 								{
	// 									Name: to.Ptr("Locations"),
	// 									Endpoints: []*armproviderhub.ResourceProviderEndpoint{
	// 										{
	// 											APIVersions: []*string{
	// 												to.Ptr("2020-01-01-preview")},
	// 												EndpointURI: to.Ptr("https://resource-endpoint.com/"),
	// 												Locations: []*string{
	// 													to.Ptr("")},
	// 													Timeout: to.Ptr("PT20S"),
	// 											}},
	// 											LinkedOperationRules: []*armproviderhub.LinkedOperationRule{
	// 											},
	// 											ResourceValidation: to.Ptr(armproviderhub.ResourceValidation("ReservedWords, ProfaneWords")),
	// 											RoutingType: to.Ptr(armproviderhub.RoutingTypeProxyOnly),
	// 										},
	// 										{
	// 											Name: to.Ptr("Locations/OperationStatuses"),
	// 											AdditionalOptions: to.Ptr(armproviderhub.AdditionalOptionsProtectedAsyncOperationPolling),
	// 											Endpoints: []*armproviderhub.ResourceProviderEndpoint{
	// 												{
	// 													APIVersions: []*string{
	// 														to.Ptr("2020-01-01-preview")},
	// 														EndpointURI: to.Ptr("https://resource-endpoint.com/"),
	// 														Locations: []*string{
	// 															to.Ptr("")},
	// 															Timeout: to.Ptr("PT20S"),
	// 													}},
	// 													LinkedOperationRules: []*armproviderhub.LinkedOperationRule{
	// 													},
	// 													ResourceValidation: to.Ptr(armproviderhub.ResourceValidation("ReservedWords, ProfaneWords")),
	// 													RoutingType: to.Ptr(armproviderhub.RoutingType("ProxyOnly, LocationBased")),
	// 											}},
	// 											ServiceName: to.Ptr("root"),
	// 											Services: []*armproviderhub.ResourceProviderService{
	// 												{
	// 													ServiceName: to.Ptr("tags"),
	// 													Status: to.Ptr(armproviderhub.ServiceStatusInactive),
	// 											}},
	// 										}
}

// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7611bb6c9bad11244f4351eecfc50b2c46a86fde/specification/providerhub/resource-manager/Microsoft.ProviderHub/stable/2024-09-01/examples/NewRegionFrontloadRelease_CreateOrUpdate.json
func ExampleNewRegionFrontloadReleaseClient_CreateOrUpdate() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armproviderhub.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewNewRegionFrontloadReleaseClient().CreateOrUpdate(ctx, "Microsoft.Contoso", "2020week10", armproviderhub.FrontloadPayload{
		Properties: &armproviderhub.FrontloadPayloadProperties{
			CopyFromLocation: to.Ptr("eastus"),
			EnvironmentType:  to.Ptr(armproviderhub.AvailableCheckInManifestEnvironmentProd),
			ExcludeResourceTypes: []*string{
				to.Ptr("monitors")},
			FrontloadLocation: to.Ptr("Israel Central"),
			IgnoreFields: []*string{
				to.Ptr("apiversion")},
			IncludeResourceTypes: []*string{
				to.Ptr("servers")},
			OperationType: to.Ptr("Rollout"),
			OverrideEndpointLevelFields: &armproviderhub.FrontloadPayloadPropertiesOverrideEndpointLevelFields{
				APIVersion: to.Ptr("2024-04-01-preview"),
				APIVersions: []*string{
					to.Ptr("2024-04-01-preview")},
				DstsConfiguration: &armproviderhub.ResourceTypeEndpointBaseDstsConfiguration{
					ServiceDNSName: to.Ptr("messaging.azure-ppe.net"),
					ServiceName:    to.Ptr("resourceprovider"),
				},
				Enabled:      to.Ptr(true),
				EndpointType: to.Ptr(armproviderhub.EndpointTypeProduction),
				EndpointURI:  to.Ptr("https://resource-endpoint.com/"),
				FeaturesRule: &armproviderhub.ResourceTypeEndpointBaseFeaturesRule{},
				Locations: []*string{
					to.Ptr("East US")},
				RequiredFeatures: []*string{
					to.Ptr("<feature flag>")},
				SKULink: to.Ptr("http://endpointuri/westus/skus"),
				Timeout: to.Ptr("PT20S"),
				Zones: []*string{
					to.Ptr("zone1")},
			},
			OverrideManifestLevelFields: &armproviderhub.FrontloadPayloadPropertiesOverrideManifestLevelFields{
				ResourceHydrationAccounts: []*armproviderhub.ResourceHydrationAccount{
					{
						AccountName:    to.Ptr("classichydrationprodsn01"),
						SubscriptionID: to.Ptr("e4eae963-2d15-43e6-a097-98bd75b33edd"),
					}},
			},
			ProviderNamespace:  to.Ptr("Microsoft.Contoso"),
			ServiceFeatureFlag: to.Ptr(armproviderhub.ServiceFeatureFlagActionDoNotCreate),
		},
	}, 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.DefaultRollout = armproviderhub.DefaultRollout{
	// 	Name: to.Ptr("Microsoft.Contoso/2020week10"),
	// 	Type: to.Ptr("Microsoft.ProviderHub/providerRegistrations/defaultRollouts"),
	// 	ID: to.Ptr("/subscriptions/ab7a8701-f7ef-471a-a2f4-d0ebbf494f77/providers/Microsoft.ProviderHub/providerRegistrations/Microsoft.Contoso/defaultRollouts/2020week10"),
	// 	SystemData: &armproviderhub.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2020-02-01T01:01:01.107Z"); return t}()),
	// 		CreatedBy: to.Ptr("string"),
	// 		CreatedByType: to.Ptr(armproviderhub.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2020-02-01T01:01:01.107Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("string"),
	// 		LastModifiedByType: to.Ptr(armproviderhub.CreatedByTypeUser),
	// 	},
	// 	Properties: &armproviderhub.DefaultRolloutProperties{
	// 		ProvisioningState: to.Ptr(armproviderhub.ProvisioningStateSucceeded),
	// 		Specification: &armproviderhub.DefaultRolloutPropertiesSpecification{
	// 			Canary: &armproviderhub.DefaultRolloutSpecificationCanary{
	// 				Regions: []*string{
	// 					to.Ptr("brazilus"),
	// 					to.Ptr("eastus2euap"),
	// 					to.Ptr("centraluseuap")},
	// 				},
	// 				HighTraffic: &armproviderhub.DefaultRolloutSpecificationHighTraffic{
	// 					Regions: []*string{
	// 						to.Ptr("australiasoutheast"),
	// 						to.Ptr("otherhightraficregions")},
	// 						WaitDuration: to.Ptr("PT24H"),
	// 					},
	// 					LowTraffic: &armproviderhub.DefaultRolloutSpecificationLowTraffic{
	// 						Regions: []*string{
	// 							to.Ptr("southeastasia")},
	// 							WaitDuration: to.Ptr("PT24H"),
	// 						},
	// 						MediumTraffic: &armproviderhub.DefaultRolloutSpecificationMediumTraffic{
	// 							Regions: []*string{
	// 								to.Ptr("uksouth"),
	// 								to.Ptr("indiawest")},
	// 								WaitDuration: to.Ptr("PT24H"),
	// 							},
	// 							RestOfTheWorldGroupOne: &armproviderhub.DefaultRolloutSpecificationRestOfTheWorldGroupOne{
	// 								Regions: []*string{
	// 									to.Ptr("koreacentral"),
	// 									to.Ptr("francecentral"),
	// 									to.Ptr("australiacentral"),
	// 									to.Ptr("westus"),
	// 									to.Ptr("allotherregions")},
	// 									WaitDuration: to.Ptr("PT4H"),
	// 								},
	// 								RestOfTheWorldGroupTwo: &armproviderhub.DefaultRolloutSpecificationRestOfTheWorldGroupTwo{
	// 									Regions: []*string{
	// 										to.Ptr("germanynorth"),
	// 										to.Ptr("norwayeast"),
	// 										to.Ptr("allotherregions")},
	// 										WaitDuration: to.Ptr("PT4H"),
	// 									},
	// 								},
	// 								Status: &armproviderhub.DefaultRolloutPropertiesStatus{
	// 									CompletedRegions: []*string{
	// 										to.Ptr("brazilus"),
	// 										to.Ptr("eastus2euap"),
	// 										to.Ptr("centraluseuap"),
	// 										to.Ptr("allcompletedregions")},
	// 										ManifestCheckinStatus: &armproviderhub.DefaultRolloutStatusManifestCheckinStatus{
	// 											CommitID: to.Ptr("47317892d4edf22f08704f6b595105c4fd7a8db7"),
	// 											IsCheckedIn: to.Ptr(true),
	// 											StatusMessage: to.Ptr("Manifest is successfully merged. Use the Default/Custom rollout (http://aka.ms/rpaasrollout) to roll out the manifest in ARM."),
	// 										},
	// 									},
	// 								},
	// 							}
}

// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7611bb6c9bad11244f4351eecfc50b2c46a86fde/specification/providerhub/resource-manager/Microsoft.ProviderHub/stable/2024-09-01/examples/NewRegionFrontloadRelease_Get.json
func ExampleNewRegionFrontloadReleaseClient_Get() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armproviderhub.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewNewRegionFrontloadReleaseClient().Get(ctx, "Microsoft.Contoso", "2020week10", 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.DefaultRollout = armproviderhub.DefaultRollout{
	// 	Name: to.Ptr("Microsoft.Contoso/2020week10"),
	// 	Type: to.Ptr("Microsoft.ProviderHub/providerRegistrations/defaultRollouts"),
	// 	ID: to.Ptr("/subscriptions/ab7a8701-f7ef-471a-a2f4-d0ebbf494f77/providers/Microsoft.ProviderHub/providerRegistrations/Microsoft.Contoso/defaultRollouts/2020week10"),
	// 	SystemData: &armproviderhub.SystemData{
	// 		CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2020-02-01T01:01:01.107Z"); return t}()),
	// 		CreatedBy: to.Ptr("string"),
	// 		CreatedByType: to.Ptr(armproviderhub.CreatedByTypeUser),
	// 		LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2020-02-01T01:01:01.107Z"); return t}()),
	// 		LastModifiedBy: to.Ptr("string"),
	// 		LastModifiedByType: to.Ptr(armproviderhub.CreatedByTypeUser),
	// 	},
	// 	Properties: &armproviderhub.DefaultRolloutProperties{
	// 		ProvisioningState: to.Ptr(armproviderhub.ProvisioningStateSucceeded),
	// 		Specification: &armproviderhub.DefaultRolloutPropertiesSpecification{
	// 			Canary: &armproviderhub.DefaultRolloutSpecificationCanary{
	// 				Regions: []*string{
	// 					to.Ptr("eastus2euap"),
	// 					to.Ptr("centraluseuap")},
	// 					SkipRegions: []*string{
	// 						to.Ptr("brazilus")},
	// 					},
	// 					ExpeditedRollout: &armproviderhub.DefaultRolloutSpecificationExpeditedRollout{
	// 						Enabled: to.Ptr(true),
	// 					},
	// 					HighTraffic: &armproviderhub.DefaultRolloutSpecificationHighTraffic{
	// 						Regions: []*string{
	// 							to.Ptr("australiasoutheast"),
	// 							to.Ptr("otherhightraficregions")},
	// 							WaitDuration: to.Ptr("PT24H"),
	// 						},
	// 						LowTraffic: &armproviderhub.DefaultRolloutSpecificationLowTraffic{
	// 							Regions: []*string{
	// 								to.Ptr("southeastasia")},
	// 								WaitDuration: to.Ptr("PT24H"),
	// 							},
	// 							MediumTraffic: &armproviderhub.DefaultRolloutSpecificationMediumTraffic{
	// 								Regions: []*string{
	// 									to.Ptr("uksouth"),
	// 									to.Ptr("indiawest")},
	// 									WaitDuration: to.Ptr("PT24H"),
	// 								},
	// 								ProviderRegistration: &armproviderhub.DefaultRolloutSpecificationProviderRegistration{
	// 									Name: to.Ptr("Microsoft.Contoso"),
	// 									Type: to.Ptr("Microsoft.ProviderHub/providerRegistrations"),
	// 									ID: to.Ptr("/subscriptions/ab7a8701-f7ef-471a-a2f4-d0ebbf494f77/providers/Microsoft.ProviderHub/providerRegistrations/Microsoft.Contoso"),
	// 									Properties: &armproviderhub.ProviderRegistrationProperties{
	// 										Capabilities: []*armproviderhub.ResourceProviderCapabilities{
	// 											{
	// 												Effect: to.Ptr(armproviderhub.ResourceProviderCapabilitiesEffectAllow),
	// 												QuotaID: to.Ptr("CSP_2015-05-01"),
	// 											},
	// 											{
	// 												Effect: to.Ptr(armproviderhub.ResourceProviderCapabilitiesEffectAllow),
	// 												QuotaID: to.Ptr("CSP_MG_2017-12-01"),
	// 										}},
	// 										Management: &armproviderhub.ResourceProviderManifestPropertiesManagement{
	// 											AuthorizationOwners: []*string{
	// 												to.Ptr("RPAAS-PlatformServiceAdministrator")},
	// 												IncidentContactEmail: to.Ptr("helpme@contoso.com"),
	// 												IncidentRoutingService: to.Ptr(""),
	// 												IncidentRoutingTeam: to.Ptr(""),
	// 												ManifestOwners: []*string{
	// 													to.Ptr("SPARTA-PlatformServiceAdministrator")},
	// 													ResourceAccessPolicy: to.Ptr(armproviderhub.ResourceAccessPolicyNotSpecified),
	// 												},
	// 												Namespace: to.Ptr("microsoft.contoso"),
	// 												ProviderAuthorizations: []*armproviderhub.ResourceProviderAuthorization{
	// 													{
	// 														ApplicationID: to.Ptr("1a3b5c7d-8e9f-10g1-1h12-i13j14k1"),
	// 														RoleDefinitionID: to.Ptr("123456bf-gkur-2098-b890-98da392a00b2"),
	// 												}},
	// 												ProviderType: to.Ptr(armproviderhub.ResourceProviderType("Internal, Hidden")),
	// 												ProviderVersion: to.Ptr("2.0"),
	// 												ProviderHubMetadata: &armproviderhub.ProviderRegistrationPropertiesProviderHubMetadata{
	// 													ProviderAuthentication: &armproviderhub.MetadataProviderAuthentication{
	// 														AllowedAudiences: []*string{
	// 															to.Ptr("https://management.core.windows.net/")},
	// 														},
	// 													},
	// 													ProvisioningState: to.Ptr(armproviderhub.ProvisioningStateSucceeded),
	// 												},
	// 											},
	// 											ResourceTypeRegistrations: []*armproviderhub.ResourceTypeRegistration{
	// 												{
	// 													Name: to.Ptr("Microsoft.Contoso/employees"),
	// 													Type: to.Ptr("Microsoft.ProviderHub/providerRegistrations/resourceTypeRegistrations"),
	// 													ID: to.Ptr("/subscriptions/ab7a8701-f7ef-471a-a2f4-d0ebbf494f77/providers/Microsoft.ProviderHub/providerRegistrations/Microsoft.Contoso/resourceTypeRegistrations/employees"),
	// 													Properties: &armproviderhub.ResourceTypeRegistrationProperties{
	// 														EnableAsyncOperation: to.Ptr(false),
	// 														EnableThirdPartyS2S: to.Ptr(false),
	// 														Endpoints: []*armproviderhub.ResourceTypeEndpoint{
	// 															{
	// 																APIVersions: []*string{
	// 																	to.Ptr("2018-11-01-preview"),
	// 																	to.Ptr("2020-01-01-preview"),
	// 																	to.Ptr("2019-01-01")},
	// 																	Locations: []*string{
	// 																		to.Ptr("East Asia"),
	// 																		to.Ptr("East US"),
	// 																		to.Ptr("North Europe"),
	// 																		to.Ptr("Southeast Asia"),
	// 																		to.Ptr("East US 2 EUAP"),
	// 																		to.Ptr("Central US EUAP"),
	// 																		to.Ptr("West Europe"),
	// 																		to.Ptr("West US"),
	// 																		to.Ptr("West Central US"),
	// 																		to.Ptr("West US 2")},
	// 																		RequiredFeatures: []*string{
	// 																			to.Ptr("Microsoft.Contoso/RPaaSSampleApp")},
	// 																	}},
	// 																	ProvisioningState: to.Ptr(armproviderhub.ProvisioningStateSucceeded),
	// 																	Regionality: to.Ptr(armproviderhub.RegionalityRegional),
	// 																	RoutingType: to.Ptr(armproviderhub.RoutingTypeDefault),
	// 																	SwaggerSpecifications: []*armproviderhub.SwaggerSpecification{
	// 																		{
	// 																			APIVersions: []*string{
	// 																				to.Ptr("2018-11-01-preview"),
	// 																				to.Ptr("2020-01-01-preview"),
	// 																				to.Ptr("2019-01-01")},
	// 																				SwaggerSpecFolderURI: to.Ptr("https://github.com/Azure/azure-rest-api-specs/blob/feature/azure/contoso/specification/contoso/resource-manager/Microsoft.SampleRP/"),
	// 																		}},
	// 																	},
	// 															}},
	// 															RestOfTheWorldGroupOne: &armproviderhub.DefaultRolloutSpecificationRestOfTheWorldGroupOne{
	// 																Regions: []*string{
	// 																	to.Ptr("koreacentral"),
	// 																	to.Ptr("francecentral"),
	// 																	to.Ptr("australiacentral"),
	// 																	to.Ptr("westus"),
	// 																	to.Ptr("allotherregions")},
	// 																	WaitDuration: to.Ptr("PT4H"),
	// 																},
	// 																RestOfTheWorldGroupTwo: &armproviderhub.DefaultRolloutSpecificationRestOfTheWorldGroupTwo{
	// 																	Regions: []*string{
	// 																		to.Ptr("germanynorth"),
	// 																		to.Ptr("norwayeast"),
	// 																		to.Ptr("allotherregions")},
	// 																		WaitDuration: to.Ptr("PT4H"),
	// 																	},
	// 																},
	// 																Status: &armproviderhub.DefaultRolloutPropertiesStatus{
	// 																	CompletedRegions: []*string{
	// 																		to.Ptr("brazilus"),
	// 																		to.Ptr("eastus2euap"),
	// 																		to.Ptr("centraluseuap"),
	// 																		to.Ptr("allcompletedregions")},
	// 																		FailedOrSkippedRegions: map[string]*armproviderhub.ExtendedErrorInfo{
	// 																			"westus2": &armproviderhub.ExtendedErrorInfo{
	// 																				Code: to.Ptr("RolloutStoppedByUser"),
	// 																				Message: to.Ptr("Rollout was explicitly stopped by the user."),
	// 																			},
	// 																		},
	// 																		ManifestCheckinStatus: &armproviderhub.DefaultRolloutStatusManifestCheckinStatus{
	// 																			CommitID: to.Ptr("47317892d4edf22f08704f6b595105c4fd7a8db7"),
	// 																			IsCheckedIn: to.Ptr(true),
	// 																			StatusMessage: to.Ptr("Manifest is successfully merged. Use the Default/Custom rollout (http://aka.ms/rpaasrollout) to roll out the manifest in ARM."),
	// 																		},
	// 																		SubscriptionReregistrationResult: to.Ptr(armproviderhub.SubscriptionReregistrationResultConditionalUpdate),
	// 																	},
	// 																},
	// 															}
}

// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7611bb6c9bad11244f4351eecfc50b2c46a86fde/specification/providerhub/resource-manager/Microsoft.ProviderHub/stable/2024-09-01/examples/NewRegionFrontloadRelease_Stop.json
func ExampleNewRegionFrontloadReleaseClient_Stop() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armproviderhub.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewNewRegionFrontloadReleaseClient().Stop(ctx, "Microsoft.Contoso", "2020week10", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
