armrecoveryservices

package module
v2.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 22, 2024 License: MIT Imports: 14 Imported by: 0

README

Azure Recovery Services Module for Go

PkgGoDev

The armrecoveryservices module provides operations for working with Azure Recovery Services.

Source code

Getting started

Prerequisites

  • an Azure subscription
  • Go 1.18 or above (You could download and install the latest version of Go from here. It will replace the existing Go on your machine. If you want to install multiple Go versions on the same machine, you could refer this doc.)

Install the package

This project uses Go modules for versioning and dependency management.

Install the Azure Recovery Services module:

go get github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservices/v2

Authorization

When creating a client, you will need to provide a credential for authenticating with Azure Recovery Services. The azidentity module provides facilities for various ways of authenticating with Azure including client/secret, certificate, managed identity, and more.

cred, err := azidentity.NewDefaultAzureCredential(nil)

For more information on authentication, please see the documentation for azidentity at pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azidentity.

Client Factory

Azure Recovery Services module consists of one or more clients. We provide a client factory which could be used to create any client in this module.

clientFactory, err := armrecoveryservices.NewClientFactory(<subscription ID>, cred, nil)

You can use ClientOptions in package github.com/Azure/azure-sdk-for-go/sdk/azcore/arm to set endpoint to connect with public and sovereign clouds as well as Azure Stack. For more information, please see the documentation for azcore at pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azcore.

options := arm.ClientOptions {
    ClientOptions: azcore.ClientOptions {
        Cloud: cloud.AzureChina,
    },
}
clientFactory, err := armrecoveryservices.NewClientFactory(<subscription ID>, cred, &options)

Clients

A client groups a set of related APIs, providing access to its functionality. Create one or more clients to access the APIs you require using client factory.

client := clientFactory.NewClient()

Fakes

The fake package contains types used for constructing in-memory fake servers used in unit tests. This allows writing tests to cover various success/error conditions without the need for connecting to a live service.

Please see https://github.com/Azure/azure-sdk-for-go/tree/main/sdk/samples/fakes for details and examples on how to use fakes.

Provide Feedback

If you encounter bugs or have suggestions, please open an issue and assign the Recovery Services label.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

Documentation

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AlertsState

type AlertsState string
const (
	AlertsStateDisabled AlertsState = "Disabled"
	AlertsStateEnabled  AlertsState = "Enabled"
)

func PossibleAlertsStateValues

func PossibleAlertsStateValues() []AlertsState

PossibleAlertsStateValues returns the possible values for the AlertsState const type.

type AuthType

type AuthType string

AuthType - Specifies the authentication type.

const (
	AuthTypeAAD                  AuthType = "AAD"
	AuthTypeACS                  AuthType = "ACS"
	AuthTypeAccessControlService AuthType = "AccessControlService"
	AuthTypeAzureActiveDirectory AuthType = "AzureActiveDirectory"
	AuthTypeInvalid              AuthType = "Invalid"
)

func PossibleAuthTypeValues

func PossibleAuthTypeValues() []AuthType

PossibleAuthTypeValues returns the possible values for the AuthType const type.

type AzureMonitorAlertSettings

type AzureMonitorAlertSettings struct {
	AlertsForAllFailoverIssues    *AlertsState
	AlertsForAllJobFailures       *AlertsState
	AlertsForAllReplicationIssues *AlertsState
}

AzureMonitorAlertSettings - Settings for Azure Monitor based alerts

func (AzureMonitorAlertSettings) MarshalJSON

func (a AzureMonitorAlertSettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type AzureMonitorAlertSettings.

func (*AzureMonitorAlertSettings) UnmarshalJSON

func (a *AzureMonitorAlertSettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type AzureMonitorAlertSettings.

type BCDRSecurityLevel

type BCDRSecurityLevel string

BCDRSecurityLevel - Security levels of Recovery Services Vault for business continuity and disaster recovery

const (
	BCDRSecurityLevelExcellent BCDRSecurityLevel = "Excellent"
	BCDRSecurityLevelFair      BCDRSecurityLevel = "Fair"
	BCDRSecurityLevelGood      BCDRSecurityLevel = "Good"
	BCDRSecurityLevelPoor      BCDRSecurityLevel = "Poor"
)

func PossibleBCDRSecurityLevelValues

func PossibleBCDRSecurityLevelValues() []BCDRSecurityLevel

PossibleBCDRSecurityLevelValues returns the possible values for the BCDRSecurityLevel const type.

type BackupStorageVersion

type BackupStorageVersion string

BackupStorageVersion - Backup storage version

const (
	BackupStorageVersionUnassigned BackupStorageVersion = "Unassigned"
	BackupStorageVersionV1         BackupStorageVersion = "V1"
	BackupStorageVersionV2         BackupStorageVersion = "V2"
)

func PossibleBackupStorageVersionValues

func PossibleBackupStorageVersionValues() []BackupStorageVersion

PossibleBackupStorageVersionValues returns the possible values for the BackupStorageVersion const type.

type CapabilitiesProperties

type CapabilitiesProperties struct {
	DNSZones []*DNSZone
}

CapabilitiesProperties - Capabilities information

func (CapabilitiesProperties) MarshalJSON

func (c CapabilitiesProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CapabilitiesProperties.

func (*CapabilitiesProperties) UnmarshalJSON

func (c *CapabilitiesProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CapabilitiesProperties.

type CapabilitiesResponse

type CapabilitiesResponse struct {
	// REQUIRED; Describes the Resource type: Microsoft.RecoveryServices/Vaults
	Type *string

	// Capabilities properties in response
	Properties *CapabilitiesResponseProperties
}

CapabilitiesResponse - Capabilities response for Microsoft.RecoveryServices

func (CapabilitiesResponse) MarshalJSON

func (c CapabilitiesResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CapabilitiesResponse.

func (*CapabilitiesResponse) UnmarshalJSON

func (c *CapabilitiesResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CapabilitiesResponse.

type CapabilitiesResponseProperties

type CapabilitiesResponseProperties struct {
	DNSZones []*DNSZoneResponse
}

CapabilitiesResponseProperties - Capabilities properties in response

func (CapabilitiesResponseProperties) MarshalJSON

func (c CapabilitiesResponseProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CapabilitiesResponseProperties.

func (*CapabilitiesResponseProperties) UnmarshalJSON

func (c *CapabilitiesResponseProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CapabilitiesResponseProperties.

type CertificateRequest

type CertificateRequest struct {
	// Raw certificate data.
	Properties *RawCertificateData
}

CertificateRequest - Details of the certificate to be uploaded to the vault.

func (CertificateRequest) MarshalJSON

func (c CertificateRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CertificateRequest.

func (*CertificateRequest) UnmarshalJSON

func (c *CertificateRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CertificateRequest.

type CheckNameAvailabilityParameters

type CheckNameAvailabilityParameters struct {
	// Resource name for which availability needs to be checked
	Name *string

	// Describes the Resource type: Microsoft.RecoveryServices/Vaults
	Type *string
}

CheckNameAvailabilityParameters - Resource Name availability input parameters - Resource type and resource name

func (CheckNameAvailabilityParameters) MarshalJSON

func (c CheckNameAvailabilityParameters) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CheckNameAvailabilityParameters.

func (*CheckNameAvailabilityParameters) UnmarshalJSON

func (c *CheckNameAvailabilityParameters) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CheckNameAvailabilityParameters.

type CheckNameAvailabilityResult

type CheckNameAvailabilityResult struct {
	Message       *string
	NameAvailable *bool
	Reason        *string
}

CheckNameAvailabilityResult - Response for check name availability API. Resource provider will set availability as true | false.

func (CheckNameAvailabilityResult) MarshalJSON

func (c CheckNameAvailabilityResult) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CheckNameAvailabilityResult.

func (*CheckNameAvailabilityResult) UnmarshalJSON

func (c *CheckNameAvailabilityResult) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CheckNameAvailabilityResult.

type ClassicAlertSettings

type ClassicAlertSettings struct {
	AlertsForCriticalOperations       *AlertsState
	EmailNotificationsForSiteRecovery *AlertsState
}

ClassicAlertSettings - Settings for classic alerts

func (ClassicAlertSettings) MarshalJSON

func (c ClassicAlertSettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ClassicAlertSettings.

func (*ClassicAlertSettings) UnmarshalJSON

func (c *ClassicAlertSettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ClassicAlertSettings.

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client contains the methods for the RecoveryServices group. Don't use this type directly, use NewClient() instead.

func NewClient

func NewClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*Client, error)

NewClient creates a new instance of Client with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*Client) Capabilities

func (client *Client) Capabilities(ctx context.Context, location string, input ResourceCapabilities, options *ClientCapabilitiesOptions) (ClientCapabilitiesResponse, error)

Capabilities - API to get details about capabilities provided by Microsoft.RecoveryServices RP If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • location - Location of the resource
  • input - Contains information about Resource type and properties to get capabilities
  • options - ClientCapabilitiesOptions contains the optional parameters for the Client.Capabilities method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/Capabilities.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewClient().Capabilities(ctx, "westus", armrecoveryservices.ResourceCapabilities{
	Type: to.Ptr("Microsoft.RecoveryServices/Vaults"),
	Properties: &armrecoveryservices.CapabilitiesProperties{
		DNSZones: []*armrecoveryservices.DNSZone{
			{
				SubResource: to.Ptr(armrecoveryservices.VaultSubResourceTypeAzureBackup),
			},
			{
				SubResource: to.Ptr(armrecoveryservices.VaultSubResourceTypeAzureSiteRecovery),
			}},
	},
}, 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.CapabilitiesResponse = armrecoveryservices.CapabilitiesResponse{
// 	Type: to.Ptr("Microsoft.RecoveryServices/Vaults"),
// 	Properties: &armrecoveryservices.CapabilitiesResponseProperties{
// 		DNSZones: []*armrecoveryservices.DNSZoneResponse{
// 			{
// 				SubResource: to.Ptr(armrecoveryservices.VaultSubResourceTypeAzureBackup),
// 				RequiredZoneNames: []*string{
// 					to.Ptr("privatelink.wus.backup.windowsazure.com"),
// 					to.Ptr("privatelink.queue.core.windows.net"),
// 					to.Ptr("privatelink.blob.core.windows.net")},
// 				},
// 				{
// 					SubResource: to.Ptr(armrecoveryservices.VaultSubResourceTypeAzureSiteRecovery),
// 					RequiredZoneNames: []*string{
// 						to.Ptr("privatelink.siterecovery.windowsazure.com")},
// 				}},
// 			},
// 		}
Output:

func (*Client) CheckNameAvailability

func (client *Client) CheckNameAvailability(ctx context.Context, resourceGroupName string, location string, input CheckNameAvailabilityParameters, options *ClientCheckNameAvailabilityOptions) (ClientCheckNameAvailabilityResponse, error)

CheckNameAvailability - API to check for resource name availability. A name is available if no other resource exists that has the same SubscriptionId, Resource Name and Type or if one or more such resources exist, each of these must be GC'd and their time of deletion be more than 24 Hours Ago If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • location - Location of the resource
  • input - Contains information about Resource type and Resource name
  • options - ClientCheckNameAvailabilityOptions contains the optional parameters for the Client.CheckNameAvailability method.
Example (AvailabilityStatusOfResourceNameWhenNoResourceWithSameNameTypeAndSubscriptionExistsNorHasBeenDeletedWithinLast24Hours)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/CheckNameAvailability_Available.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewClient().CheckNameAvailability(ctx, "resGroupFoo", "westus", armrecoveryservices.CheckNameAvailabilityParameters{
	Name: to.Ptr("swaggerExample"),
	Type: to.Ptr("Microsoft.RecoveryServices/Vaults"),
}, 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.CheckNameAvailabilityResult = armrecoveryservices.CheckNameAvailabilityResult{
// 	NameAvailable: to.Ptr(true),
// }
Output:

Example (AvailabilityStatusOfResourceNameWhenResourceWithSameNameTypeAndSubscriptionExists)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/CheckNameAvailability_NotAvailable.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewClient().CheckNameAvailability(ctx, "resGroupBar", "westus", armrecoveryservices.CheckNameAvailabilityParameters{
	Name: to.Ptr("swaggerExample2"),
	Type: to.Ptr("Microsoft.RecoveryServices/Vaults"),
}, 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.CheckNameAvailabilityResult = armrecoveryservices.CheckNameAvailabilityResult{
// 	Message: to.Ptr("Resource already exists with the same name."),
// 	NameAvailable: to.Ptr(false),
// 	Reason: to.Ptr("AlreadyExists"),
// }
Output:

type ClientCapabilitiesOptions

type ClientCapabilitiesOptions struct {
}

ClientCapabilitiesOptions contains the optional parameters for the Client.Capabilities method.

type ClientCapabilitiesResponse

type ClientCapabilitiesResponse struct {
	// Capabilities response for Microsoft.RecoveryServices
	CapabilitiesResponse
}

ClientCapabilitiesResponse contains the response from method Client.Capabilities.

type ClientCheckNameAvailabilityOptions

type ClientCheckNameAvailabilityOptions struct {
}

ClientCheckNameAvailabilityOptions contains the optional parameters for the Client.CheckNameAvailability method.

type ClientCheckNameAvailabilityResponse

type ClientCheckNameAvailabilityResponse struct {
	// Response for check name availability API. Resource provider will set availability as true | false.
	CheckNameAvailabilityResult
}

ClientCheckNameAvailabilityResponse contains the response from method Client.CheckNameAvailability.

type ClientDiscoveryDisplay

type ClientDiscoveryDisplay struct {
	// Description of the operation having details of what operation is about.
	Description *string

	// Operations Name itself.
	Operation *string

	// Name of the provider for display purposes
	Provider *string

	// ResourceType for which this Operation can be performed.
	Resource *string
}

ClientDiscoveryDisplay - Localized display information of an operation.

func (ClientDiscoveryDisplay) MarshalJSON

func (c ClientDiscoveryDisplay) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ClientDiscoveryDisplay.

func (*ClientDiscoveryDisplay) UnmarshalJSON

func (c *ClientDiscoveryDisplay) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ClientDiscoveryDisplay.

type ClientDiscoveryForLogSpecification

type ClientDiscoveryForLogSpecification struct {
	// Blobs created in customer storage account per hour
	BlobDuration *string

	// Localized display name
	DisplayName *string

	// Name of the log.
	Name *string
}

ClientDiscoveryForLogSpecification - Class to represent shoebox log specification in json client discovery.

func (ClientDiscoveryForLogSpecification) MarshalJSON

func (c ClientDiscoveryForLogSpecification) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ClientDiscoveryForLogSpecification.

func (*ClientDiscoveryForLogSpecification) UnmarshalJSON

func (c *ClientDiscoveryForLogSpecification) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ClientDiscoveryForLogSpecification.

type ClientDiscoveryForProperties

type ClientDiscoveryForProperties struct {
	// Operation properties.
	ServiceSpecification *ClientDiscoveryForServiceSpecification
}

ClientDiscoveryForProperties - Class to represent shoebox properties in json client discovery.

func (ClientDiscoveryForProperties) MarshalJSON

func (c ClientDiscoveryForProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ClientDiscoveryForProperties.

func (*ClientDiscoveryForProperties) UnmarshalJSON

func (c *ClientDiscoveryForProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ClientDiscoveryForProperties.

type ClientDiscoveryForServiceSpecification

type ClientDiscoveryForServiceSpecification struct {
	// List of log specifications of this operation.
	LogSpecifications []*ClientDiscoveryForLogSpecification
}

ClientDiscoveryForServiceSpecification - Class to represent shoebox service specification in json client discovery.

func (ClientDiscoveryForServiceSpecification) MarshalJSON

func (c ClientDiscoveryForServiceSpecification) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ClientDiscoveryForServiceSpecification.

func (*ClientDiscoveryForServiceSpecification) UnmarshalJSON

func (c *ClientDiscoveryForServiceSpecification) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ClientDiscoveryForServiceSpecification.

type ClientDiscoveryResponse

type ClientDiscoveryResponse struct {
	// Link to the next chunk of the response
	NextLink *string

	// List of available operations.
	Value []*ClientDiscoveryValueForSingleAPI
}

ClientDiscoveryResponse - Operations List response which contains list of available APIs.

func (ClientDiscoveryResponse) MarshalJSON

func (c ClientDiscoveryResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ClientDiscoveryResponse.

func (*ClientDiscoveryResponse) UnmarshalJSON

func (c *ClientDiscoveryResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ClientDiscoveryResponse.

type ClientDiscoveryValueForSingleAPI

type ClientDiscoveryValueForSingleAPI struct {
	// Contains the localized display information for this particular operation
	Display *ClientDiscoveryDisplay

	// Name of the Operation.
	Name *string

	// The intended executor of the operation;governs the display of the operation in the RBAC UX and the audit logs UX
	Origin *string

	// ShoeBox properties for the given operation.
	Properties *ClientDiscoveryForProperties
}

ClientDiscoveryValueForSingleAPI - Available operation details.

func (ClientDiscoveryValueForSingleAPI) MarshalJSON

func (c ClientDiscoveryValueForSingleAPI) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ClientDiscoveryValueForSingleAPI.

func (*ClientDiscoveryValueForSingleAPI) UnmarshalJSON

func (c *ClientDiscoveryValueForSingleAPI) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ClientDiscoveryValueForSingleAPI.

type ClientFactory

type ClientFactory struct {
	// contains filtered or unexported fields
}

ClientFactory is a client factory used to create any client in this module. Don't use this type directly, use NewClientFactory instead.

func NewClientFactory

func NewClientFactory(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ClientFactory, error)

NewClientFactory creates a new instance of ClientFactory with the specified values. The parameter values will be propagated to any client created from this factory.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ClientFactory) NewClient

func (c *ClientFactory) NewClient() *Client

NewClient creates a new instance of Client.

func (*ClientFactory) NewOperationsClient

func (c *ClientFactory) NewOperationsClient() *OperationsClient

NewOperationsClient creates a new instance of OperationsClient.

func (*ClientFactory) NewPrivateLinkResourcesClient

func (c *ClientFactory) NewPrivateLinkResourcesClient() *PrivateLinkResourcesClient

NewPrivateLinkResourcesClient creates a new instance of PrivateLinkResourcesClient.

func (*ClientFactory) NewRegisteredIdentitiesClient

func (c *ClientFactory) NewRegisteredIdentitiesClient() *RegisteredIdentitiesClient

NewRegisteredIdentitiesClient creates a new instance of RegisteredIdentitiesClient.

func (*ClientFactory) NewReplicationUsagesClient

func (c *ClientFactory) NewReplicationUsagesClient() *ReplicationUsagesClient

NewReplicationUsagesClient creates a new instance of ReplicationUsagesClient.

func (*ClientFactory) NewUsagesClient

func (c *ClientFactory) NewUsagesClient() *UsagesClient

NewUsagesClient creates a new instance of UsagesClient.

func (*ClientFactory) NewVaultCertificatesClient

func (c *ClientFactory) NewVaultCertificatesClient() *VaultCertificatesClient

NewVaultCertificatesClient creates a new instance of VaultCertificatesClient.

func (*ClientFactory) NewVaultExtendedInfoClient

func (c *ClientFactory) NewVaultExtendedInfoClient() *VaultExtendedInfoClient

NewVaultExtendedInfoClient creates a new instance of VaultExtendedInfoClient.

func (*ClientFactory) NewVaultsClient

func (c *ClientFactory) NewVaultsClient() *VaultsClient

NewVaultsClient creates a new instance of VaultsClient.

type CmkKekIdentity

type CmkKekIdentity struct {
	// Indicate that system assigned identity should be used. Mutually exclusive with 'userAssignedIdentity' field
	UseSystemAssignedIdentity *bool

	// The user assigned identity to be used to grant permissions in case the type of identity used is UserAssigned
	UserAssignedIdentity *string
}

CmkKekIdentity - The details of the identity used for CMK

func (CmkKekIdentity) MarshalJSON

func (c CmkKekIdentity) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CmkKekIdentity.

func (*CmkKekIdentity) UnmarshalJSON

func (c *CmkKekIdentity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CmkKekIdentity.

type CmkKeyVaultProperties

type CmkKeyVaultProperties struct {
	// The key uri of the Customer Managed Key
	KeyURI *string
}

CmkKeyVaultProperties - The properties of the Key Vault which hosts CMK

func (CmkKeyVaultProperties) MarshalJSON

func (c CmkKeyVaultProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CmkKeyVaultProperties.

func (*CmkKeyVaultProperties) UnmarshalJSON

func (c *CmkKeyVaultProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CmkKeyVaultProperties.

type CreatedByType

type CreatedByType string

CreatedByType - The type of identity that created the resource.

const (
	CreatedByTypeApplication     CreatedByType = "Application"
	CreatedByTypeKey             CreatedByType = "Key"
	CreatedByTypeManagedIdentity CreatedByType = "ManagedIdentity"
	CreatedByTypeUser            CreatedByType = "User"
)

func PossibleCreatedByTypeValues

func PossibleCreatedByTypeValues() []CreatedByType

PossibleCreatedByTypeValues returns the possible values for the CreatedByType const type.

type CrossRegionRestore

type CrossRegionRestore string

CrossRegionRestore - Flag to show if Cross Region Restore is enabled on the Vault or not

const (
	CrossRegionRestoreDisabled CrossRegionRestore = "Disabled"
	CrossRegionRestoreEnabled  CrossRegionRestore = "Enabled"
)

func PossibleCrossRegionRestoreValues

func PossibleCrossRegionRestoreValues() []CrossRegionRestore

PossibleCrossRegionRestoreValues returns the possible values for the CrossRegionRestore const type.

type CrossSubscriptionRestoreSettings

type CrossSubscriptionRestoreSettings struct {
	CrossSubscriptionRestoreState *CrossSubscriptionRestoreState
}

CrossSubscriptionRestoreSettings - Settings for Cross Subscription Restore Settings

func (CrossSubscriptionRestoreSettings) MarshalJSON

func (c CrossSubscriptionRestoreSettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CrossSubscriptionRestoreSettings.

func (*CrossSubscriptionRestoreSettings) UnmarshalJSON

func (c *CrossSubscriptionRestoreSettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CrossSubscriptionRestoreSettings.

type CrossSubscriptionRestoreState

type CrossSubscriptionRestoreState string
const (
	CrossSubscriptionRestoreStateDisabled            CrossSubscriptionRestoreState = "Disabled"
	CrossSubscriptionRestoreStateEnabled             CrossSubscriptionRestoreState = "Enabled"
	CrossSubscriptionRestoreStatePermanentlyDisabled CrossSubscriptionRestoreState = "PermanentlyDisabled"
)

func PossibleCrossSubscriptionRestoreStateValues

func PossibleCrossSubscriptionRestoreStateValues() []CrossSubscriptionRestoreState

PossibleCrossSubscriptionRestoreStateValues returns the possible values for the CrossSubscriptionRestoreState const type.

type DNSZone

type DNSZone struct {
	// Subresource type for vault AzureBackup, AzureBackup_secondary or AzureSiteRecovery
	SubResource *VaultSubResourceType
}

DNSZone information

func (DNSZone) MarshalJSON

func (d DNSZone) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DNSZone.

func (*DNSZone) UnmarshalJSON

func (d *DNSZone) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DNSZone.

type DNSZoneResponse

type DNSZoneResponse struct {
	// The private link resource Private link DNS zone names.
	RequiredZoneNames []*string

	// Subresource type for vault AzureBackup, AzureBackup_secondary or AzureSiteRecovery
	SubResource *VaultSubResourceType
}

DNSZoneResponse - DNSZone information for Microsoft.RecoveryServices

func (DNSZoneResponse) MarshalJSON

func (d DNSZoneResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type DNSZoneResponse.

func (*DNSZoneResponse) UnmarshalJSON

func (d *DNSZoneResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type DNSZoneResponse.

type EnhancedSecurityState

type EnhancedSecurityState string
const (
	EnhancedSecurityStateAlwaysON EnhancedSecurityState = "AlwaysON"
	EnhancedSecurityStateDisabled EnhancedSecurityState = "Disabled"
	EnhancedSecurityStateEnabled  EnhancedSecurityState = "Enabled"
	EnhancedSecurityStateInvalid  EnhancedSecurityState = "Invalid"
)

func PossibleEnhancedSecurityStateValues

func PossibleEnhancedSecurityStateValues() []EnhancedSecurityState

PossibleEnhancedSecurityStateValues returns the possible values for the EnhancedSecurityState const type.

type Error

type Error struct {
	// READ-ONLY; The error additional info.
	AdditionalInfo []*ErrorAdditionalInfo

	// READ-ONLY; The error code.
	Code *string

	// READ-ONLY; The error details.
	Details []*Error

	// READ-ONLY; The error message.
	Message *string

	// READ-ONLY; The error target.
	Target *string
}

Error - The resource management error response.

func (Error) MarshalJSON

func (e Error) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Error.

func (*Error) UnmarshalJSON

func (e *Error) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Error.

type ErrorAdditionalInfo

type ErrorAdditionalInfo struct {
	// READ-ONLY; The additional info.
	Info any

	// READ-ONLY; The additional info type.
	Type *string
}

ErrorAdditionalInfo - The resource management error additional info.

func (ErrorAdditionalInfo) MarshalJSON

func (e ErrorAdditionalInfo) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ErrorAdditionalInfo.

func (*ErrorAdditionalInfo) UnmarshalJSON

func (e *ErrorAdditionalInfo) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorAdditionalInfo.

type ErrorDetail

type ErrorDetail struct {
	// READ-ONLY; The error additional info.
	AdditionalInfo []*ErrorAdditionalInfo

	// READ-ONLY; The error code.
	Code *string

	// READ-ONLY; The error details.
	Details []*ErrorDetail

	// READ-ONLY; The error message.
	Message *string

	// READ-ONLY; The error target.
	Target *string
}

ErrorDetail - The error detail.

func (ErrorDetail) MarshalJSON

func (e ErrorDetail) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ErrorDetail.

func (*ErrorDetail) UnmarshalJSON

func (e *ErrorDetail) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorDetail.

type ErrorResponse

type ErrorResponse struct {
	// The error object.
	Error *ErrorDetail
}

ErrorResponse - Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.).

func (ErrorResponse) MarshalJSON

func (e ErrorResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ErrorResponse.

func (*ErrorResponse) UnmarshalJSON

func (e *ErrorResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorResponse.

type IdentityData

type IdentityData struct {
	// REQUIRED; The type of managed identity used. The type 'SystemAssigned, UserAssigned' includes both an implicitly created
	// identity and a set of user-assigned identities. The type 'None' will remove any
	// identities.
	Type *ResourceIdentityType

	// The list of user-assigned identities associated with the resource. The user-assigned identity dictionary keys will be ARM
	// resource ids in the form:
	// '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
	UserAssignedIdentities map[string]*UserIdentity

	// READ-ONLY; The principal ID of resource identity.
	PrincipalID *string

	// READ-ONLY; The tenant ID of resource.
	TenantID *string
}

IdentityData - Identity for the resource.

func (IdentityData) MarshalJSON

func (i IdentityData) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type IdentityData.

func (*IdentityData) UnmarshalJSON

func (i *IdentityData) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type IdentityData.

type ImmutabilitySettings

type ImmutabilitySettings struct {
	State *ImmutabilityState
}

ImmutabilitySettings - Immutability Settings of vault

func (ImmutabilitySettings) MarshalJSON

func (i ImmutabilitySettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ImmutabilitySettings.

func (*ImmutabilitySettings) UnmarshalJSON

func (i *ImmutabilitySettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ImmutabilitySettings.

type ImmutabilityState

type ImmutabilityState string
const (
	ImmutabilityStateDisabled ImmutabilityState = "Disabled"
	ImmutabilityStateLocked   ImmutabilityState = "Locked"
	ImmutabilityStateUnlocked ImmutabilityState = "Unlocked"
)

func PossibleImmutabilityStateValues

func PossibleImmutabilityStateValues() []ImmutabilityState

PossibleImmutabilityStateValues returns the possible values for the ImmutabilityState const type.

type InfrastructureEncryptionState

type InfrastructureEncryptionState string

InfrastructureEncryptionState - Enabling/Disabling the Double Encryption state

const (
	InfrastructureEncryptionStateDisabled InfrastructureEncryptionState = "Disabled"
	InfrastructureEncryptionStateEnabled  InfrastructureEncryptionState = "Enabled"
)

func PossibleInfrastructureEncryptionStateValues

func PossibleInfrastructureEncryptionStateValues() []InfrastructureEncryptionState

PossibleInfrastructureEncryptionStateValues returns the possible values for the InfrastructureEncryptionState const type.

type JobsSummary

type JobsSummary struct {
	// Count of failed jobs.
	FailedJobs *int32

	// Count of in-progress jobs.
	InProgressJobs *int32

	// Count of suspended jobs.
	SuspendedJobs *int32
}

JobsSummary - Summary of the replication job data for this vault.

func (JobsSummary) MarshalJSON

func (j JobsSummary) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type JobsSummary.

func (*JobsSummary) UnmarshalJSON

func (j *JobsSummary) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type JobsSummary.

type MonitoringSettings

type MonitoringSettings struct {
	// Settings for Azure Monitor based alerts
	AzureMonitorAlertSettings *AzureMonitorAlertSettings

	// Settings for classic alerts
	ClassicAlertSettings *ClassicAlertSettings
}

MonitoringSettings - Monitoring Settings of the vault

func (MonitoringSettings) MarshalJSON

func (m MonitoringSettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type MonitoringSettings.

func (*MonitoringSettings) UnmarshalJSON

func (m *MonitoringSettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type MonitoringSettings.

type MonitoringSummary

type MonitoringSummary struct {
	// Count of all deprecated recovery service providers.
	DeprecatedProviderCount *int32

	// Count of all critical warnings.
	EventsCount *int32

	// Count of all the supported recovery service providers.
	SupportedProviderCount *int32

	// Count of unhealthy replication providers.
	UnHealthyProviderCount *int32

	// Count of unhealthy VMs.
	UnHealthyVMCount *int32

	// Count of all the unsupported recovery service providers.
	UnsupportedProviderCount *int32
}

MonitoringSummary - Summary of the replication monitoring data for this vault.

func (MonitoringSummary) MarshalJSON

func (m MonitoringSummary) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type MonitoringSummary.

func (*MonitoringSummary) UnmarshalJSON

func (m *MonitoringSummary) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type MonitoringSummary.

type MultiUserAuthorization

type MultiUserAuthorization string

MultiUserAuthorization - MUA Settings of vault

const (
	MultiUserAuthorizationDisabled MultiUserAuthorization = "Disabled"
	MultiUserAuthorizationEnabled  MultiUserAuthorization = "Enabled"
	MultiUserAuthorizationInvalid  MultiUserAuthorization = "Invalid"
)

func PossibleMultiUserAuthorizationValues

func PossibleMultiUserAuthorizationValues() []MultiUserAuthorization

PossibleMultiUserAuthorizationValues returns the possible values for the MultiUserAuthorization const type.

type NameInfo

type NameInfo struct {
	// Localized value of usage.
	LocalizedValue *string

	// Value of usage.
	Value *string
}

NameInfo - The name of usage.

func (NameInfo) MarshalJSON

func (n NameInfo) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type NameInfo.

func (*NameInfo) UnmarshalJSON

func (n *NameInfo) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type NameInfo.

type OperationResource

type OperationResource struct {
	// End time of the operation
	EndTime *time.Time

	// Required if status == failed or status == canceled. This is the OData v4 error format, used by the RPC and will go into
	// the v2.2 Azure REST API guidelines.
	Error *Error

	// It should match what is used to GET the operation result
	ID *string

	// It must match the last segment of the "id" field, and will typically be a GUID / system generated value
	Name *string

	// Start time of the operation
	StartTime *time.Time

	// The status of the operation. (InProgress/Success/Failed/Cancelled)
	Status *string
}

OperationResource - Operation Resource

func (OperationResource) MarshalJSON

func (o OperationResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationResource.

func (*OperationResource) UnmarshalJSON

func (o *OperationResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationResource.

type OperationsClient

type OperationsClient struct {
	// contains filtered or unexported fields
}

OperationsClient contains the methods for the Operations group. Don't use this type directly, use NewOperationsClient() instead.

func NewOperationsClient

func NewOperationsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*OperationsClient, error)

NewOperationsClient creates a new instance of OperationsClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*OperationsClient) GetOperationResult

func (client *OperationsClient) GetOperationResult(ctx context.Context, resourceGroupName string, vaultName string, operationID string, options *OperationsClientGetOperationResultOptions) (OperationsClientGetOperationResultResponse, error)

GetOperationResult - Gets the operation result for a resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - OperationsClientGetOperationResultOptions contains the optional parameters for the OperationsClient.GetOperationResult method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/GetOperationResult.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewOperationsClient().GetOperationResult(ctx, "HelloWorld", "swaggerExample", "YWUzNDFkMzQtZmM5OS00MmUyLWEzNDMtZGJkMDIxZjlmZjgzOzdmYzBiMzhmLTc2NmItNDM5NS05OWQ1LTVmOGEzNzg4MWQzNA==", 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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"PatchKey": to.Ptr("PatchKeyUpdated"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
// 		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
// 			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": &armrecoveryservices.UserIdentity{
// 				ClientID: to.Ptr("fbe75b66-01c5-4f87-a220-233af3270436"),
// 				PrincipalID: to.Ptr("075a0ca6-43f6-4434-9abf-c9b1b79f9219"),
// 			},
// 		},
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		ProvisioningState: to.Ptr("Succeeded"),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

func (*OperationsClient) NewListPager

NewListPager - Returns the list of available operations.

Generated from API version 2024-04-01

  • options - OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/ListOperations.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewOperationsClient().NewListPager(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.ClientDiscoveryResponse = armrecoveryservices.ClientDiscoveryResponse{
	// 	Value: []*armrecoveryservices.ClientDiscoveryValueForSingleAPI{
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/usages/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns usage details for a Recovery Services Vault."),
	// 				Operation: to.Ptr("Recovery Services Vault usage details."),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Vault Usage"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupUsageSummaries/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns summaries for Protected Items and Protected Servers for a Recovery Services ."),
	// 				Operation: to.Ptr("Recovery Services Protected Items and Protected Servers usage summaries details."),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Usages Summaries"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/storageConfig/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns Storage Configuration for Recovery Services Vault."),
	// 				Operation: to.Ptr("Get Resource Storage Config"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Vault Storage Config"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/storageConfig/write"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Updates Storage Configuration for Recovery Services Vault."),
	// 				Operation: to.Ptr("Write Resource Storage Config"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Vault Storage Config"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupconfig/vaultconfig/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns Configuration for Recovery Services Vault."),
	// 				Operation: to.Ptr("Get Resource Config"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Vault Config"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupconfig/vaultconfig/write"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Updates Configuration for Recovery Services Vault."),
	// 				Operation: to.Ptr("Update Resource Config"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Vault Config"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/tokenInfo/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns token information for Recovery Services Vault."),
	// 				Operation: to.Ptr("Get Vault Token Info"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Token Info"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupSecurityPIN/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns Security PIN Information for Recovery Services Vault."),
	// 				Operation: to.Ptr("Get Security PIN Info"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("SecurityPINInfo"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupManagementMetaData/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns Backup Management Metadata for Recovery Services Vault."),
	// 				Operation: to.Ptr("Get Backup Management Metadata"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Management Metadata"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupOperationResults/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns Backup Operation Result for Recovery Services Vault."),
	// 				Operation: to.Ptr("Get Backup Operation Result"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Operation Results"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupOperations/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns Backup Operation Status for Recovery Services Vault."),
	// 				Operation: to.Ptr("Get Backup Operation Status"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Operation Status"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupJobs/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns all Job Objects"),
	// 				Operation: to.Ptr("Get Jobs"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Jobs"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupJobs/cancel/action"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Cancel the Job"),
	// 				Operation: to.Ptr("Cancel Jobs"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Jobs"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupJobsExport/action"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Export Jobs"),
	// 				Operation: to.Ptr("Export Jobs"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Export Backup Jobs"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupJobs/operationResults/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns the Result of Job Operation."),
	// 				Operation: to.Ptr("Get Job Operation Result"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Jobs Operation Results"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupJobsExport/operationResults/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns the Result of Export Job Operation."),
	// 				Operation: to.Ptr("Get Export Job Operation Result"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Export Backup Jobs Operation Results"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/recoveryPoints/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Get Recovery Points for Protected Items."),
	// 				Operation: to.Ptr("Get Recovery Points"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Recovery Points"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/recoveryPoints/restore/action"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Restore Recovery Points for Protected Items."),
	// 				Operation: to.Ptr("Restore Recovery Points"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Recovery Points"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/recoveryPoints/provisionInstantItemRecovery/action"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Provision Instant Item Recovery for Protected Item"),
	// 				Operation: to.Ptr("Provision Instant Item Recovery for Protected Item"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Recovery Points"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/recoveryPoints/revokeInstantItemRecovery/action"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Revoke Instant Item Recovery for Protected Item"),
	// 				Operation: to.Ptr("Revoke Instant Item Recovery for Protected Item"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Recovery Points"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupPolicies/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns all Protection Policies"),
	// 				Operation: to.Ptr("Get Protection Policy"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Policies"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupPolicies/write"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Creates Protection Policy"),
	// 				Operation: to.Ptr("Create Protection Policy"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Policies"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupPolicies/delete"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Delete a Protection Policy"),
	// 				Operation: to.Ptr("Delete Protection Policy"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Policies"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupPolicies/operationResults/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Get Results of Policy Operation."),
	// 				Operation: to.Ptr("Get Policy Operation Results"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Policy Operation Results"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupPolicies/operationsStatus/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Get Status of Policy Operation."),
	// 				Operation: to.Ptr("Get Policy Operation Status"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Policy Operation Status"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns object details of the Protected Item"),
	// 				Operation: to.Ptr("Get Protected Item Details"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protected Items"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupProtectedItems/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns the list of all Protected Items."),
	// 				Operation: to.Ptr("Get All Protected Items"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protected Items"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/write"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Create a backup Protected Item"),
	// 				Operation: to.Ptr("Create Backup Protected Item"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protected Items"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/delete"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Deletes Protected Item"),
	// 				Operation: to.Ptr("Delete Protected Items"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protected Items"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/operationResults/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Gets Result of Operation Performed on Protected Items."),
	// 				Operation: to.Ptr("Get Protected Items Operation Results"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protected Item Operation Results"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/operationsStatus/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns the status of Operation performed on Protected Items."),
	// 				Operation: to.Ptr("Get Protected Items operation status"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protected Item Operation Status"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/protectedItems/backup/action"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Performs Backup for Protected Item."),
	// 				Operation: to.Ptr("Backup Protected Item"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protected Items"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupProtectableItems/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns list of all Protectable Items."),
	// 				Operation: to.Ptr("Get Protectable Items"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Protectable Items"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/refreshContainers/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Refreshes the container list"),
	// 				Operation: to.Ptr("Refresh container"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Refresh Containers"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/operationResults/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns status of the operation"),
	// 				Operation: to.Ptr("Get Operation Results"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Refresh Containers Operation Results"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupProtectionContainers/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns all containers belonging to the subscription"),
	// 				Operation: to.Ptr("Get Containers In Subscription"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Protection Containers"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns all registered containers"),
	// 				Operation: to.Ptr("Get Registered Container"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protection Containers"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/operationResults/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Gets result of Operation performed on Protection Container."),
	// 				Operation: to.Ptr("Get Container Operation Results"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protection Containers Operation Results"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupEngines"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Returns all the backup management servers registered with vault."),
	// 				Operation: to.Ptr("List of backup management servers."),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Engines"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupStatus"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Check Backup Status for Recovery Services Vaults"),
	// 				Operation: to.Ptr("Check Backup Status for Vault"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Backup Status"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupPreValidateProtection"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr(""),
	// 				Operation: to.Ptr("Pre Validate Enable Protection"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("PreValidate Protection"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupValidateFeatures"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Validate Features"),
	// 				Operation: to.Ptr("Validate Features"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Validate Features"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/backupProtectionIntent/write"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Create a backup Protection Intent"),
	// 				Operation: to.Ptr("Create backup Protection Intent"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protection Intent"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/{fabricName}/protectionContainers/{containerName}/items/read"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Get all items in a container"),
	// 				Operation: to.Ptr("Get all items in a container"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Workload Items"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 		},
	// 		{
	// 			Name: to.Ptr("microsoft.recoveryservices/vaults/backupFabrics/protectionContainers/inquire/action"),
	// 			Display: &armrecoveryservices.ClientDiscoveryDisplay{
	// 				Description: to.Ptr("Get all items in a container"),
	// 				Operation: to.Ptr("Get all items in a container"),
	// 				Provider: to.Ptr("microsoft.recoveryservices"),
	// 				Resource: to.Ptr("Protection Containers Inquire"),
	// 			},
	// 			Origin: to.Ptr("user"),
	// 	}},
	// }
}
Output:

func (*OperationsClient) OperationStatusGet

func (client *OperationsClient) OperationStatusGet(ctx context.Context, resourceGroupName string, vaultName string, operationID string, options *OperationsClientOperationStatusGetOptions) (OperationsClientOperationStatusGetResponse, error)

OperationStatusGet - Gets the operation status for a resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - OperationsClientOperationStatusGetOptions contains the optional parameters for the OperationsClient.OperationStatusGet method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/GetOperationStatus.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewOperationsClient().OperationStatusGet(ctx, "HelloWorld", "swaggerExample", "YWUzNDFkMzQtZmM5OS00MmUyLWEzNDMtZGJkMDIxZjlmZjgzOzdmYzBiMzhmLTc2NmItNDM5NS05OWQ1LTVmOGEzNzg4MWQzNA==", 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.OperationResource = armrecoveryservices.OperationResource{
// 	Name: to.Ptr("YWUzNDFkMzQtZmM5OS00MmUyLWEzNDMtZGJkMDIxZjlmZjgzOzdmYzBiMzhmLTc2NmItNDM5NS05OWQ1LTVmOGEzNzg4MWQzNA=="),
// 	EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2019-11-20T09:49:46.000Z"); return t}()),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample/operationStatus/YWUzNDFkMzQtZmM5OS00MmUyLWEzNDMtZGJkMDIxZjlmZjgzOzdmYzBiMzhmLTc2NmItNDM5NS05OWQ1LTVmOGEzNzg4MWQzNA=="),
// 	StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2019-11-20T09:49:44.047Z"); return t}()),
// 	Status: to.Ptr("Succeeded"),
// }
Output:

type OperationsClientGetOperationResultOptions

type OperationsClientGetOperationResultOptions struct {
}

OperationsClientGetOperationResultOptions contains the optional parameters for the OperationsClient.GetOperationResult method.

type OperationsClientGetOperationResultResponse

type OperationsClientGetOperationResultResponse struct {
	// Resource information, as returned by the resource provider.
	Vault
}

OperationsClientGetOperationResultResponse contains the response from method OperationsClient.GetOperationResult.

type OperationsClientListOptions

type OperationsClientListOptions struct {
}

OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.

type OperationsClientListResponse

type OperationsClientListResponse struct {
	// Operations List response which contains list of available APIs.
	ClientDiscoveryResponse
}

OperationsClientListResponse contains the response from method OperationsClient.NewListPager.

type OperationsClientOperationStatusGetOptions

type OperationsClientOperationStatusGetOptions struct {
}

OperationsClientOperationStatusGetOptions contains the optional parameters for the OperationsClient.OperationStatusGet method.

type OperationsClientOperationStatusGetResponse

type OperationsClientOperationStatusGetResponse struct {
	// Operation Resource
	OperationResource
}

OperationsClientOperationStatusGetResponse contains the response from method OperationsClient.OperationStatusGet.

type PatchTrackedResource

type PatchTrackedResource struct {
	// Optional ETag.
	Etag *string

	// Resource location.
	Location *string

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Resource Id represents the complete path to the resource.
	ID *string

	// READ-ONLY; Resource name associated with the resource.
	Name *string

	// READ-ONLY; Resource type represents the complete path of the form Namespace/ResourceType/ResourceType/…
	Type *string
}

PatchTrackedResource - Tracked resource with location.

func (PatchTrackedResource) MarshalJSON

func (p PatchTrackedResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PatchTrackedResource.

func (*PatchTrackedResource) UnmarshalJSON

func (p *PatchTrackedResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PatchTrackedResource.

type PatchVault

type PatchVault struct {
	// Optional ETag.
	Etag *string

	// Identity for the resource.
	Identity *IdentityData

	// Resource location.
	Location *string

	// Properties of the vault.
	Properties *VaultProperties

	// Identifies the unique system identifier for each Azure resource.
	SKU *SKU

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Resource Id represents the complete path to the resource.
	ID *string

	// READ-ONLY; Resource name associated with the resource.
	Name *string

	// READ-ONLY; Resource type represents the complete path of the form Namespace/ResourceType/ResourceType/…
	Type *string
}

PatchVault - Patch Resource information, as returned by the resource provider.

func (PatchVault) MarshalJSON

func (p PatchVault) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PatchVault.

func (*PatchVault) UnmarshalJSON

func (p *PatchVault) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PatchVault.

type PrivateEndpoint

type PrivateEndpoint struct {
	// READ-ONLY; Gets or sets id.
	ID *string
}

PrivateEndpoint - The Private Endpoint network resource that is linked to the Private Endpoint connection.

func (PrivateEndpoint) MarshalJSON

func (p PrivateEndpoint) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PrivateEndpoint.

func (*PrivateEndpoint) UnmarshalJSON

func (p *PrivateEndpoint) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpoint.

type PrivateEndpointConnection

type PrivateEndpointConnection struct {
	// Group Ids for the Private Endpoint
	GroupIDs []*VaultSubResourceType

	// READ-ONLY; The Private Endpoint network resource that is linked to the Private Endpoint connection.
	PrivateEndpoint *PrivateEndpoint

	// READ-ONLY; Gets or sets private link service connection state.
	PrivateLinkServiceConnectionState *PrivateLinkServiceConnectionState

	// READ-ONLY; Gets or sets provisioning state of the private endpoint connection.
	ProvisioningState *ProvisioningState
}

PrivateEndpointConnection - Private Endpoint Connection Response Properties.

func (PrivateEndpointConnection) MarshalJSON

func (p PrivateEndpointConnection) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnection.

func (*PrivateEndpointConnection) UnmarshalJSON

func (p *PrivateEndpointConnection) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnection.

type PrivateEndpointConnectionStatus

type PrivateEndpointConnectionStatus string

PrivateEndpointConnectionStatus - Gets or sets the status.

const (
	PrivateEndpointConnectionStatusApproved     PrivateEndpointConnectionStatus = "Approved"
	PrivateEndpointConnectionStatusDisconnected PrivateEndpointConnectionStatus = "Disconnected"
	PrivateEndpointConnectionStatusPending      PrivateEndpointConnectionStatus = "Pending"
	PrivateEndpointConnectionStatusRejected     PrivateEndpointConnectionStatus = "Rejected"
)

func PossiblePrivateEndpointConnectionStatusValues

func PossiblePrivateEndpointConnectionStatusValues() []PrivateEndpointConnectionStatus

PossiblePrivateEndpointConnectionStatusValues returns the possible values for the PrivateEndpointConnectionStatus const type.

type PrivateEndpointConnectionVaultProperties

type PrivateEndpointConnectionVaultProperties struct {
	// READ-ONLY; Format of id subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.[Service]/{resource}/{resourceName}/privateEndpointConnections/{connectionName}.
	ID *string

	// READ-ONLY; The location of the private Endpoint connection
	Location *string

	// READ-ONLY; The name of the private Endpoint Connection
	Name *string

	// READ-ONLY; Private Endpoint Connection Response Properties.
	Properties *PrivateEndpointConnection

	// READ-ONLY; The type, which will be of the format, Microsoft.RecoveryServices/vaults/privateEndpointConnections
	Type *string
}

PrivateEndpointConnectionVaultProperties - Information to be stored in Vault properties as an element of privateEndpointConnections List.

func (PrivateEndpointConnectionVaultProperties) MarshalJSON

MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnectionVaultProperties.

func (*PrivateEndpointConnectionVaultProperties) UnmarshalJSON

func (p *PrivateEndpointConnectionVaultProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnectionVaultProperties.

type PrivateLinkResource

type PrivateLinkResource struct {
	// Resource properties
	Properties *PrivateLinkResourceProperties

	// READ-ONLY; Fully qualified identifier of the resource.
	ID *string

	// READ-ONLY; Name of the resource.
	Name *string

	// READ-ONLY; e.g. Microsoft.RecoveryServices/vaults/privateLinkResources
	Type *string
}

PrivateLinkResource - Information of the private link resource.

func (PrivateLinkResource) MarshalJSON

func (p PrivateLinkResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PrivateLinkResource.

func (*PrivateLinkResource) UnmarshalJSON

func (p *PrivateLinkResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResource.

type PrivateLinkResourceProperties

type PrivateLinkResourceProperties struct {
	// READ-ONLY; e.g. f9ad6492-33d4-4690-9999-6bfd52a0d081 (Backup) or f9ad6492-33d4-4690-9999-6bfd52a0d082 (SiteRecovery)
	GroupID *string

	// READ-ONLY; [backup-ecs1, backup-prot1, backup-prot1b, backup-prot1c, backup-id1]
	RequiredMembers []*string

	// READ-ONLY; The private link resource Private link DNS zone name.
	RequiredZoneNames []*string
}

PrivateLinkResourceProperties - Properties of the private link resource.

func (PrivateLinkResourceProperties) MarshalJSON

func (p PrivateLinkResourceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PrivateLinkResourceProperties.

func (*PrivateLinkResourceProperties) UnmarshalJSON

func (p *PrivateLinkResourceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResourceProperties.

type PrivateLinkResources

type PrivateLinkResources struct {
	// Link to the next chunk of the response
	NextLink *string

	// A collection of private link resources
	Value []*PrivateLinkResource
}

PrivateLinkResources - Class which represent the stamps associated with the vault.

func (PrivateLinkResources) MarshalJSON

func (p PrivateLinkResources) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PrivateLinkResources.

func (*PrivateLinkResources) UnmarshalJSON

func (p *PrivateLinkResources) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResources.

type PrivateLinkResourcesClient

type PrivateLinkResourcesClient struct {
	// contains filtered or unexported fields
}

PrivateLinkResourcesClient contains the methods for the PrivateLinkResources group. Don't use this type directly, use NewPrivateLinkResourcesClient() instead.

func NewPrivateLinkResourcesClient

func NewPrivateLinkResourcesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*PrivateLinkResourcesClient, error)

NewPrivateLinkResourcesClient creates a new instance of PrivateLinkResourcesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*PrivateLinkResourcesClient) Get

func (client *PrivateLinkResourcesClient) Get(ctx context.Context, resourceGroupName string, vaultName string, privateLinkResourceName string, options *PrivateLinkResourcesClientGetOptions) (PrivateLinkResourcesClientGetResponse, error)

Get - Returns a specified private link resource that need to be created for Backup and SiteRecovery If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - PrivateLinkResourcesClientGetOptions contains the optional parameters for the PrivateLinkResourcesClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/GetPrivateLinkResources.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewPrivateLinkResourcesClient().Get(ctx, "petesting", "pemsi-ecy-rsv2", "backupResource", 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.PrivateLinkResource = armrecoveryservices.PrivateLinkResource{
// 	Name: to.Ptr("backupResource"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/Vaults/privateLinkResources"),
// 	ID: to.Ptr("/subscriptions/6c48fa17-39c7-45f1-90ac-47a587128ace/resourceGroups/petesting/providers/Microsoft.RecoveryServices/Vaults/pemsi-ecy-rsv2/privateLinkResources/backupResource"),
// 	Properties: &armrecoveryservices.PrivateLinkResourceProperties{
// 		GroupID: to.Ptr("AzureBackup"),
// 		RequiredMembers: []*string{
// 			to.Ptr("backup-fab1"),
// 			to.Ptr("backup-rec2"),
// 			to.Ptr("backup-prot1"),
// 			to.Ptr("backup-ecs1"),
// 			to.Ptr("backup-tel1"),
// 			to.Ptr("backup-wbcm1"),
// 			to.Ptr("backup-fc1"),
// 			to.Ptr("backup-id1")},
// 			RequiredZoneNames: []*string{
// 				to.Ptr("privatelink.ecy.backup.windowsazure.com"),
// 				to.Ptr("privatelink.queue.core.windows.net"),
// 				to.Ptr("privatelink.blob.core.windows.net")},
// 			},
// 		}
Output:

func (*PrivateLinkResourcesClient) NewListPager

NewListPager - Returns the list of private link resources that need to be created for Backup and SiteRecovery

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - PrivateLinkResourcesClientListOptions contains the optional parameters for the PrivateLinkResourcesClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/ListPrivateLinkResources.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewPrivateLinkResourcesClient().NewListPager("petesting", "pemsi-ecy-rsv2", 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.PrivateLinkResources = armrecoveryservices.PrivateLinkResources{
	// 	Value: []*armrecoveryservices.PrivateLinkResource{
	// 		{
	// 			Name: to.Ptr("backupResource"),
	// 			Type: to.Ptr("Microsoft.RecoveryServices/Vaults/privateLinkResources"),
	// 			ID: to.Ptr("/subscriptions/6c48fa17-39c7-45f1-90ac-47a587128ace/resourceGroups/petesting/providers/Microsoft.RecoveryServices/Vaults/pemsi-ecy-rsv2/privateLinkResources/backupResource"),
	// 			Properties: &armrecoveryservices.PrivateLinkResourceProperties{
	// 				GroupID: to.Ptr("AzureBackup"),
	// 				RequiredMembers: []*string{
	// 					to.Ptr("backup-fab1"),
	// 					to.Ptr("backup-rec2"),
	// 					to.Ptr("backup-prot1"),
	// 					to.Ptr("backup-ecs1"),
	// 					to.Ptr("backup-tel1"),
	// 					to.Ptr("backup-wbcm1"),
	// 					to.Ptr("backup-fc1"),
	// 					to.Ptr("backup-id1")},
	// 					RequiredZoneNames: []*string{
	// 						to.Ptr("privatelink.ecy.backup.windowsazure.com"),
	// 						to.Ptr("privatelink.queue.core.windows.net"),
	// 						to.Ptr("privatelink.blob.core.windows.net")},
	// 					},
	// 				},
	// 				{
	// 					Name: to.Ptr("siteRecoveryResource"),
	// 					Type: to.Ptr("Microsoft.RecoveryServices/vaults/privateLinkResources"),
	// 					ID: to.Ptr("/subscriptions/6c48fa17-39c7-45f1-90ac-47a587128ace/resourceGroups/gaallarg/providers/Microsoft.RecoveryServices/vaults/amchandnTest2702A/privateLinkResources/siteRecoveryResource"),
	// 					Properties: &armrecoveryservices.PrivateLinkResourceProperties{
	// 						GroupID: to.Ptr("AzureSiteRecovery"),
	// 						RequiredMembers: []*string{
	// 							to.Ptr("siteRecovery-rcm1"),
	// 							to.Ptr("siteRecovery-prot2"),
	// 							to.Ptr("siteRecovery-tel1"),
	// 							to.Ptr("siteRecovery-srs1"),
	// 							to.Ptr("siteRecovery-prot2b"),
	// 							to.Ptr("siteRecovery-id1")},
	// 							RequiredZoneNames: []*string{
	// 								to.Ptr("privatelink.ecy.siterecovery.windowsazure.com"),
	// 								to.Ptr("privatelink.queue.core.windows.net"),
	// 								to.Ptr("privatelink.blob.core.windows.net")},
	// 							},
	// 					}},
	// 				}
}
Output:

type PrivateLinkResourcesClientGetOptions

type PrivateLinkResourcesClientGetOptions struct {
}

PrivateLinkResourcesClientGetOptions contains the optional parameters for the PrivateLinkResourcesClient.Get method.

type PrivateLinkResourcesClientGetResponse

type PrivateLinkResourcesClientGetResponse struct {
	// Information of the private link resource.
	PrivateLinkResource
}

PrivateLinkResourcesClientGetResponse contains the response from method PrivateLinkResourcesClient.Get.

type PrivateLinkResourcesClientListOptions

type PrivateLinkResourcesClientListOptions struct {
}

PrivateLinkResourcesClientListOptions contains the optional parameters for the PrivateLinkResourcesClient.NewListPager method.

type PrivateLinkResourcesClientListResponse

type PrivateLinkResourcesClientListResponse struct {
	// Class which represent the stamps associated with the vault.
	PrivateLinkResources
}

PrivateLinkResourcesClientListResponse contains the response from method PrivateLinkResourcesClient.NewListPager.

type PrivateLinkServiceConnectionState

type PrivateLinkServiceConnectionState struct {
	// READ-ONLY; Gets or sets actions required.
	ActionsRequired *string

	// READ-ONLY; Gets or sets description.
	Description *string

	// READ-ONLY; Gets or sets the status.
	Status *PrivateEndpointConnectionStatus
}

PrivateLinkServiceConnectionState - Gets or sets private link service connection state.

func (PrivateLinkServiceConnectionState) MarshalJSON

func (p PrivateLinkServiceConnectionState) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PrivateLinkServiceConnectionState.

func (*PrivateLinkServiceConnectionState) UnmarshalJSON

func (p *PrivateLinkServiceConnectionState) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkServiceConnectionState.

type ProvisioningState

type ProvisioningState string

ProvisioningState - Gets or sets provisioning state of the private endpoint connection.

const (
	ProvisioningStateDeleting  ProvisioningState = "Deleting"
	ProvisioningStateFailed    ProvisioningState = "Failed"
	ProvisioningStatePending   ProvisioningState = "Pending"
	ProvisioningStateSucceeded ProvisioningState = "Succeeded"
)

func PossibleProvisioningStateValues

func PossibleProvisioningStateValues() []ProvisioningState

PossibleProvisioningStateValues returns the possible values for the ProvisioningState const type.

type PublicNetworkAccess

type PublicNetworkAccess string

PublicNetworkAccess - property to enable or disable resource provider inbound network traffic from public clients

const (
	PublicNetworkAccessDisabled PublicNetworkAccess = "Disabled"
	PublicNetworkAccessEnabled  PublicNetworkAccess = "Enabled"
)

func PossiblePublicNetworkAccessValues

func PossiblePublicNetworkAccessValues() []PublicNetworkAccess

PossiblePublicNetworkAccessValues returns the possible values for the PublicNetworkAccess const type.

type RawCertificateData

type RawCertificateData struct {
	// Specifies the authentication type.
	AuthType *AuthType

	// The base64 encoded certificate raw data string
	Certificate []byte
}

RawCertificateData - Raw certificate data.

func (RawCertificateData) MarshalJSON

func (r RawCertificateData) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RawCertificateData.

func (*RawCertificateData) UnmarshalJSON

func (r *RawCertificateData) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RawCertificateData.

type RegisteredIdentitiesClient

type RegisteredIdentitiesClient struct {
	// contains filtered or unexported fields
}

RegisteredIdentitiesClient contains the methods for the RegisteredIdentities group. Don't use this type directly, use NewRegisteredIdentitiesClient() instead.

func NewRegisteredIdentitiesClient

func NewRegisteredIdentitiesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*RegisteredIdentitiesClient, error)

NewRegisteredIdentitiesClient creates a new instance of RegisteredIdentitiesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*RegisteredIdentitiesClient) Delete

Delete - Unregisters the given container from your Recovery Services vault. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • identityName - Name of the protection container to unregister.
  • options - RegisteredIdentitiesClientDeleteOptions contains the optional parameters for the RegisteredIdentitiesClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/DeleteRegisteredIdentities.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
_, err = clientFactory.NewRegisteredIdentitiesClient().Delete(ctx, "BCDRIbzRG", "BCDRIbzVault", "dpmcontainer01", nil)
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
Output:

type RegisteredIdentitiesClientDeleteOptions

type RegisteredIdentitiesClientDeleteOptions struct {
}

RegisteredIdentitiesClientDeleteOptions contains the optional parameters for the RegisteredIdentitiesClient.Delete method.

type RegisteredIdentitiesClientDeleteResponse

type RegisteredIdentitiesClientDeleteResponse struct {
}

RegisteredIdentitiesClientDeleteResponse contains the response from method RegisteredIdentitiesClient.Delete.

type ReplicationUsage

type ReplicationUsage struct {
	// Summary of the replication jobs data for this vault.
	JobsSummary *JobsSummary

	// Summary of the replication monitoring data for this vault.
	MonitoringSummary *MonitoringSummary

	// Number of replication protected items for this vault.
	ProtectedItemCount *int32

	// Number of replication recovery plans for this vault.
	RecoveryPlanCount *int32

	// The authentication type of recovery service providers in the vault.
	RecoveryServicesProviderAuthType *int32

	// Number of servers registered to this vault.
	RegisteredServersCount *int32
}

ReplicationUsage - Replication usages of a vault.

func (ReplicationUsage) MarshalJSON

func (r ReplicationUsage) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ReplicationUsage.

func (*ReplicationUsage) UnmarshalJSON

func (r *ReplicationUsage) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ReplicationUsage.

type ReplicationUsageList

type ReplicationUsageList struct {
	// The list of replication usages for the given vault.
	Value []*ReplicationUsage
}

ReplicationUsageList - Replication usages for vault.

func (ReplicationUsageList) MarshalJSON

func (r ReplicationUsageList) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ReplicationUsageList.

func (*ReplicationUsageList) UnmarshalJSON

func (r *ReplicationUsageList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ReplicationUsageList.

type ReplicationUsagesClient

type ReplicationUsagesClient struct {
	// contains filtered or unexported fields
}

ReplicationUsagesClient contains the methods for the ReplicationUsages group. Don't use this type directly, use NewReplicationUsagesClient() instead.

func NewReplicationUsagesClient

func NewReplicationUsagesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ReplicationUsagesClient, error)

NewReplicationUsagesClient creates a new instance of ReplicationUsagesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ReplicationUsagesClient) NewListPager

func (client *ReplicationUsagesClient) NewListPager(resourceGroupName string, vaultName string, options *ReplicationUsagesClientListOptions) *runtime.Pager[ReplicationUsagesClientListResponse]

NewListPager - Fetches the replication usages of the vault.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - ReplicationUsagesClientListOptions contains the optional parameters for the ReplicationUsagesClient.NewListPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/ListReplicationUsages.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewReplicationUsagesClient().NewListPager("avrai7517RG1", "avrai7517Vault1", 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.ReplicationUsageList = armrecoveryservices.ReplicationUsageList{
	// 	Value: []*armrecoveryservices.ReplicationUsage{
	// 		{
	// 			JobsSummary: &armrecoveryservices.JobsSummary{
	// 				FailedJobs: to.Ptr[int32](0),
	// 				InProgressJobs: to.Ptr[int32](0),
	// 				SuspendedJobs: to.Ptr[int32](0),
	// 			},
	// 			MonitoringSummary: &armrecoveryservices.MonitoringSummary{
	// 				DeprecatedProviderCount: to.Ptr[int32](0),
	// 				EventsCount: to.Ptr[int32](0),
	// 				SupportedProviderCount: to.Ptr[int32](0),
	// 				UnHealthyProviderCount: to.Ptr[int32](0),
	// 				UnHealthyVMCount: to.Ptr[int32](0),
	// 				UnsupportedProviderCount: to.Ptr[int32](0),
	// 			},
	// 			ProtectedItemCount: to.Ptr[int32](2),
	// 			RecoveryPlanCount: to.Ptr[int32](1),
	// 			RegisteredServersCount: to.Ptr[int32](2),
	// 	}},
	// }
}
Output:

type ReplicationUsagesClientListOptions

type ReplicationUsagesClientListOptions struct {
}

ReplicationUsagesClientListOptions contains the optional parameters for the ReplicationUsagesClient.NewListPager method.

type ReplicationUsagesClientListResponse

type ReplicationUsagesClientListResponse struct {
	// Replication usages for vault.
	ReplicationUsageList
}

ReplicationUsagesClientListResponse contains the response from method ReplicationUsagesClient.NewListPager.

type Resource

type Resource struct {
	// Optional ETag.
	Etag *string

	// READ-ONLY; Resource Id represents the complete path to the resource.
	ID *string

	// READ-ONLY; Resource name associated with the resource.
	Name *string

	// READ-ONLY; Resource type represents the complete path of the form Namespace/ResourceType/ResourceType/…
	Type *string
}

Resource - ARM Resource.

func (Resource) MarshalJSON

func (r Resource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Resource.

func (*Resource) UnmarshalJSON

func (r *Resource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Resource.

type ResourceCapabilities

type ResourceCapabilities struct {
	// REQUIRED; Describes the Resource type: Microsoft.RecoveryServices/Vaults
	Type *string

	// Capabilities information
	Properties *CapabilitiesProperties
}

ResourceCapabilities - Input to get capabilities information for Microsoft.RecoveryServices

func (ResourceCapabilities) MarshalJSON

func (r ResourceCapabilities) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ResourceCapabilities.

func (*ResourceCapabilities) UnmarshalJSON

func (r *ResourceCapabilities) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ResourceCapabilities.

type ResourceCapabilitiesBase

type ResourceCapabilitiesBase struct {
	// REQUIRED; Describes the Resource type: Microsoft.RecoveryServices/Vaults
	Type *string
}

ResourceCapabilitiesBase - Base class for request and response capabilities information for Microsoft.RecoveryServices

func (ResourceCapabilitiesBase) MarshalJSON

func (r ResourceCapabilitiesBase) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ResourceCapabilitiesBase.

func (*ResourceCapabilitiesBase) UnmarshalJSON

func (r *ResourceCapabilitiesBase) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ResourceCapabilitiesBase.

type ResourceCertificateAndAADDetails

type ResourceCertificateAndAADDetails struct {
	// REQUIRED; AAD tenant authority.
	AADAuthority *string

	// REQUIRED; AAD tenant Id.
	AADTenantID *string

	// REQUIRED; This property will be used as the discriminator for deciding the specific types in the polymorphic chain of types.
	AuthType *string

	// REQUIRED; Azure Management Endpoint Audience.
	AzureManagementEndpointAudience *string

	// REQUIRED; AAD service principal clientId.
	ServicePrincipalClientID *string

	// REQUIRED; AAD service principal ObjectId.
	ServicePrincipalObjectID *string

	// AAD audience for the resource
	AADAudience *string

	// The base64 encoded certificate raw data string.
	Certificate []byte

	// Certificate friendly name.
	FriendlyName *string

	// Certificate issuer.
	Issuer *string

	// Resource ID of the vault.
	ResourceID *int64

	// Service Resource Id.
	ServiceResourceID *string

	// Certificate Subject Name.
	Subject *string

	// Certificate thumbprint.
	Thumbprint *string

	// Certificate Validity start Date time.
	ValidFrom *time.Time

	// Certificate Validity End Date time.
	ValidTo *time.Time
}

ResourceCertificateAndAADDetails - Certificate details representing the Vault credentials for AAD.

func (*ResourceCertificateAndAADDetails) GetResourceCertificateDetails

func (r *ResourceCertificateAndAADDetails) GetResourceCertificateDetails() *ResourceCertificateDetails

GetResourceCertificateDetails implements the ResourceCertificateDetailsClassification interface for type ResourceCertificateAndAADDetails.

func (ResourceCertificateAndAADDetails) MarshalJSON

func (r ResourceCertificateAndAADDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ResourceCertificateAndAADDetails.

func (*ResourceCertificateAndAADDetails) UnmarshalJSON

func (r *ResourceCertificateAndAADDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ResourceCertificateAndAADDetails.

type ResourceCertificateAndAcsDetails

type ResourceCertificateAndAcsDetails struct {
	// REQUIRED; This property will be used as the discriminator for deciding the specific types in the polymorphic chain of types.
	AuthType *string

	// REQUIRED; Acs mgmt host name to connect to.
	GlobalAcsHostName *string

	// REQUIRED; ACS namespace name - tenant for our service.
	GlobalAcsNamespace *string

	// REQUIRED; Global ACS namespace RP realm.
	GlobalAcsRPRealm *string

	// The base64 encoded certificate raw data string.
	Certificate []byte

	// Certificate friendly name.
	FriendlyName *string

	// Certificate issuer.
	Issuer *string

	// Resource ID of the vault.
	ResourceID *int64

	// Certificate Subject Name.
	Subject *string

	// Certificate thumbprint.
	Thumbprint *string

	// Certificate Validity start Date time.
	ValidFrom *time.Time

	// Certificate Validity End Date time.
	ValidTo *time.Time
}

ResourceCertificateAndAcsDetails - Certificate details representing the Vault credentials for ACS.

func (*ResourceCertificateAndAcsDetails) GetResourceCertificateDetails

func (r *ResourceCertificateAndAcsDetails) GetResourceCertificateDetails() *ResourceCertificateDetails

GetResourceCertificateDetails implements the ResourceCertificateDetailsClassification interface for type ResourceCertificateAndAcsDetails.

func (ResourceCertificateAndAcsDetails) MarshalJSON

func (r ResourceCertificateAndAcsDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ResourceCertificateAndAcsDetails.

func (*ResourceCertificateAndAcsDetails) UnmarshalJSON

func (r *ResourceCertificateAndAcsDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ResourceCertificateAndAcsDetails.

type ResourceCertificateDetails

type ResourceCertificateDetails struct {
	// REQUIRED; This property will be used as the discriminator for deciding the specific types in the polymorphic chain of types.
	AuthType *string

	// The base64 encoded certificate raw data string.
	Certificate []byte

	// Certificate friendly name.
	FriendlyName *string

	// Certificate issuer.
	Issuer *string

	// Resource ID of the vault.
	ResourceID *int64

	// Certificate Subject Name.
	Subject *string

	// Certificate thumbprint.
	Thumbprint *string

	// Certificate Validity start Date time.
	ValidFrom *time.Time

	// Certificate Validity End Date time.
	ValidTo *time.Time
}

ResourceCertificateDetails - Certificate details representing the Vault credentials.

func (*ResourceCertificateDetails) GetResourceCertificateDetails

func (r *ResourceCertificateDetails) GetResourceCertificateDetails() *ResourceCertificateDetails

GetResourceCertificateDetails implements the ResourceCertificateDetailsClassification interface for type ResourceCertificateDetails.

func (ResourceCertificateDetails) MarshalJSON

func (r ResourceCertificateDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ResourceCertificateDetails.

func (*ResourceCertificateDetails) UnmarshalJSON

func (r *ResourceCertificateDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ResourceCertificateDetails.

type ResourceCertificateDetailsClassification

type ResourceCertificateDetailsClassification interface {
	// GetResourceCertificateDetails returns the ResourceCertificateDetails content of the underlying type.
	GetResourceCertificateDetails() *ResourceCertificateDetails
}

ResourceCertificateDetailsClassification provides polymorphic access to related types. Call the interface's GetResourceCertificateDetails() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *ResourceCertificateAndAADDetails, *ResourceCertificateAndAcsDetails, *ResourceCertificateDetails

type ResourceIdentityType

type ResourceIdentityType string

ResourceIdentityType - The type of managed identity used. The type 'SystemAssigned, UserAssigned' includes both an implicitly created identity and a set of user-assigned identities. The type 'None' will remove any identities.

const (
	ResourceIdentityTypeNone                       ResourceIdentityType = "None"
	ResourceIdentityTypeSystemAssigned             ResourceIdentityType = "SystemAssigned"
	ResourceIdentityTypeSystemAssignedUserAssigned ResourceIdentityType = "SystemAssigned, UserAssigned"
	ResourceIdentityTypeUserAssigned               ResourceIdentityType = "UserAssigned"
)

func PossibleResourceIdentityTypeValues

func PossibleResourceIdentityTypeValues() []ResourceIdentityType

PossibleResourceIdentityTypeValues returns the possible values for the ResourceIdentityType const type.

type ResourceMoveState

type ResourceMoveState string

ResourceMoveState - The State of the Resource after the move operation

const (
	ResourceMoveStateCommitFailed    ResourceMoveState = "CommitFailed"
	ResourceMoveStateCommitTimedout  ResourceMoveState = "CommitTimedout"
	ResourceMoveStateCriticalFailure ResourceMoveState = "CriticalFailure"
	ResourceMoveStateFailure         ResourceMoveState = "Failure"
	ResourceMoveStateInProgress      ResourceMoveState = "InProgress"
	ResourceMoveStateMoveSucceeded   ResourceMoveState = "MoveSucceeded"
	ResourceMoveStatePartialSuccess  ResourceMoveState = "PartialSuccess"
	ResourceMoveStatePrepareFailed   ResourceMoveState = "PrepareFailed"
	ResourceMoveStatePrepareTimedout ResourceMoveState = "PrepareTimedout"
	ResourceMoveStateUnknown         ResourceMoveState = "Unknown"
)

func PossibleResourceMoveStateValues

func PossibleResourceMoveStateValues() []ResourceMoveState

PossibleResourceMoveStateValues returns the possible values for the ResourceMoveState const type.

type RestoreSettings

type RestoreSettings struct {
	// Settings for CrossSubscriptionRestore
	CrossSubscriptionRestoreSettings *CrossSubscriptionRestoreSettings
}

RestoreSettings - Restore Settings of the vault

func (RestoreSettings) MarshalJSON

func (r RestoreSettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RestoreSettings.

func (*RestoreSettings) UnmarshalJSON

func (r *RestoreSettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RestoreSettings.

type SKU

type SKU struct {
	// REQUIRED; Name of SKU is RS0 (Recovery Services 0th version) and the tier is standard tier. They do not have affect on
	// backend storage redundancy or any other vault settings. To manage storage redundancy, use
	// the backupstorageconfig
	Name *SKUName

	// The sku capacity
	Capacity *string

	// The sku family
	Family *string

	// The sku size
	Size *string

	// The Sku tier.
	Tier *string
}

SKU - Identifies the unique system identifier for each Azure resource.

func (SKU) MarshalJSON

func (s SKU) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SKU.

func (*SKU) UnmarshalJSON

func (s *SKU) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SKU.

type SKUName

type SKUName string

SKUName - Name of SKU is RS0 (Recovery Services 0th version) and the tier is standard tier. They do not have affect on backend storage redundancy or any other vault settings. To manage storage redundancy, use the backupstorageconfig

const (
	SKUNameRS0      SKUName = "RS0"
	SKUNameStandard SKUName = "Standard"
)

func PossibleSKUNameValues

func PossibleSKUNameValues() []SKUName

PossibleSKUNameValues returns the possible values for the SKUName const type.

type SecureScoreLevel

type SecureScoreLevel string

SecureScoreLevel - Secure Score of Recovery Services Vault

const (
	SecureScoreLevelAdequate SecureScoreLevel = "Adequate"
	SecureScoreLevelMaximum  SecureScoreLevel = "Maximum"
	SecureScoreLevelMinimum  SecureScoreLevel = "Minimum"
	SecureScoreLevelNone     SecureScoreLevel = "None"
)

func PossibleSecureScoreLevelValues

func PossibleSecureScoreLevelValues() []SecureScoreLevel

PossibleSecureScoreLevelValues returns the possible values for the SecureScoreLevel const type.

type SecuritySettings

type SecuritySettings struct {
	// Immutability Settings of a vault
	ImmutabilitySettings *ImmutabilitySettings

	// Soft delete Settings of a vault
	SoftDeleteSettings *SoftDeleteSettings

	// READ-ONLY; MUA Settings of a vault
	MultiUserAuthorization *MultiUserAuthorization
}

SecuritySettings - Security Settings of the vault

func (SecuritySettings) MarshalJSON

func (s SecuritySettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SecuritySettings.

func (*SecuritySettings) UnmarshalJSON

func (s *SecuritySettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SecuritySettings.

type SoftDeleteSettings

type SoftDeleteSettings struct {
	EnhancedSecurityState *EnhancedSecurityState

	// Soft delete retention period in days
	SoftDeleteRetentionPeriodInDays *int32
	SoftDeleteState                 *SoftDeleteState
}

SoftDeleteSettings - Soft delete Settings of vault

func (SoftDeleteSettings) MarshalJSON

func (s SoftDeleteSettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SoftDeleteSettings.

func (*SoftDeleteSettings) UnmarshalJSON

func (s *SoftDeleteSettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SoftDeleteSettings.

type SoftDeleteState

type SoftDeleteState string
const (
	SoftDeleteStateAlwaysON SoftDeleteState = "AlwaysON"
	SoftDeleteStateDisabled SoftDeleteState = "Disabled"
	SoftDeleteStateEnabled  SoftDeleteState = "Enabled"
	SoftDeleteStateInvalid  SoftDeleteState = "Invalid"
)

func PossibleSoftDeleteStateValues

func PossibleSoftDeleteStateValues() []SoftDeleteState

PossibleSoftDeleteStateValues returns the possible values for the SoftDeleteState const type.

type StandardTierStorageRedundancy

type StandardTierStorageRedundancy string

StandardTierStorageRedundancy - The storage redundancy setting of a vault

const (
	StandardTierStorageRedundancyGeoRedundant     StandardTierStorageRedundancy = "GeoRedundant"
	StandardTierStorageRedundancyInvalid          StandardTierStorageRedundancy = "Invalid"
	StandardTierStorageRedundancyLocallyRedundant StandardTierStorageRedundancy = "LocallyRedundant"
	StandardTierStorageRedundancyZoneRedundant    StandardTierStorageRedundancy = "ZoneRedundant"
)

func PossibleStandardTierStorageRedundancyValues

func PossibleStandardTierStorageRedundancyValues() []StandardTierStorageRedundancy

PossibleStandardTierStorageRedundancyValues returns the possible values for the StandardTierStorageRedundancy const type.

type SystemData

type SystemData struct {
	// The timestamp of resource creation (UTC).
	CreatedAt *time.Time

	// The identity that created the resource.
	CreatedBy *string

	// The type of identity that created the resource.
	CreatedByType *CreatedByType

	// The type of identity that last modified the resource.
	LastModifiedAt *time.Time

	// The identity that last modified the resource.
	LastModifiedBy *string

	// The type of identity that last modified the resource.
	LastModifiedByType *CreatedByType
}

SystemData - Metadata pertaining to creation and last modification of the resource.

func (SystemData) MarshalJSON

func (s SystemData) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SystemData.

func (*SystemData) UnmarshalJSON

func (s *SystemData) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SystemData.

type TrackedResource

type TrackedResource struct {
	// REQUIRED; Resource location.
	Location *string

	// Optional ETag.
	Etag *string

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Resource Id represents the complete path to the resource.
	ID *string

	// READ-ONLY; Resource name associated with the resource.
	Name *string

	// READ-ONLY; Resource type represents the complete path of the form Namespace/ResourceType/ResourceType/…
	Type *string
}

TrackedResource - Tracked resource with location.

func (TrackedResource) MarshalJSON

func (t TrackedResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type TrackedResource.

func (*TrackedResource) UnmarshalJSON

func (t *TrackedResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type TrackedResource.

type TriggerType

type TriggerType string

TriggerType - The way the vault upgrade was triggered.

const (
	TriggerTypeForcedUpgrade TriggerType = "ForcedUpgrade"
	TriggerTypeUserTriggered TriggerType = "UserTriggered"
)

func PossibleTriggerTypeValues

func PossibleTriggerTypeValues() []TriggerType

PossibleTriggerTypeValues returns the possible values for the TriggerType const type.

type UpgradeDetails

type UpgradeDetails struct {
	// READ-ONLY; UTC time at which the upgrade operation has ended.
	EndTimeUTC *time.Time

	// READ-ONLY; UTC time at which the upgrade operation status was last updated.
	LastUpdatedTimeUTC *time.Time

	// READ-ONLY; Message to the user containing information about the upgrade operation.
	Message *string

	// READ-ONLY; ID of the vault upgrade operation.
	OperationID *string

	// READ-ONLY; Resource ID of the vault before the upgrade.
	PreviousResourceID *string

	// READ-ONLY; UTC time at which the upgrade operation has started.
	StartTimeUTC *time.Time

	// READ-ONLY; Status of the vault upgrade operation.
	Status *VaultUpgradeState

	// READ-ONLY; The way the vault upgrade was triggered.
	TriggerType *TriggerType

	// READ-ONLY; Resource ID of the upgraded vault.
	UpgradedResourceID *string
}

UpgradeDetails - Details for upgrading vault.

func (UpgradeDetails) MarshalJSON

func (u UpgradeDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UpgradeDetails.

func (*UpgradeDetails) UnmarshalJSON

func (u *UpgradeDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UpgradeDetails.

type UsagesClient

type UsagesClient struct {
	// contains filtered or unexported fields
}

UsagesClient contains the methods for the Usages group. Don't use this type directly, use NewUsagesClient() instead.

func NewUsagesClient

func NewUsagesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*UsagesClient, error)

NewUsagesClient creates a new instance of UsagesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*UsagesClient) NewListByVaultsPager

func (client *UsagesClient) NewListByVaultsPager(resourceGroupName string, vaultName string, options *UsagesClientListByVaultsOptions) *runtime.Pager[UsagesClientListByVaultsResponse]

NewListByVaultsPager - Fetches the usages of the vault.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - UsagesClientListByVaultsOptions contains the optional parameters for the UsagesClient.NewListByVaultsPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/ListUsages.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewUsagesClient().NewListByVaultsPager("Default-RecoveryServices-ResourceGroup", "swaggerExample", 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.VaultUsageList = armrecoveryservices.VaultUsageList{
	// 	Value: []*armrecoveryservices.VaultUsage{
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Backup management servers"),
	// 				Value: to.Ptr("MABContainersCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](6),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Backup items/Azure virtual machine backup"),
	// 				Value: to.Ptr("ProtectedItemCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](3),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Critical"),
	// 				Value: to.Ptr("ProtectedItemCriticalCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Warning"),
	// 				Value: to.Ptr("ProtectedItemWarningCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Azure Virtual Machines"),
	// 				Value: to.Ptr("IaaSVMProtectedItemCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Critical"),
	// 				Value: to.Ptr("IaaSVMProtectedItemCriticalCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Warning"),
	// 				Value: to.Ptr("IaaSVMProtectedItemWarningCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("File-Folders"),
	// 				Value: to.Ptr("MABProtectedItemCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("DPM Protected Items Count"),
	// 				Value: to.Ptr("DPMProtectedItemCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](1),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Azure Backup Server Protected Items Count"),
	// 				Value: to.Ptr("AzureBackupServerProtectedItemCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](2),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("In progress"),
	// 				Value: to.Ptr("InProgressJobsCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			QuotaPeriod: to.Ptr("P1D"),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Failed"),
	// 				Value: to.Ptr("FailedJobsCount"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			QuotaPeriod: to.Ptr("P1D"),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Cloud - GRS"),
	// 				Value: to.Ptr("GRSStorageUsage"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](117007930),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitBytes),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Cloud - LRS"),
	// 				Value: to.Ptr("LRSStorageUsage"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitBytes),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Protected Instances"),
	// 				Value: to.Ptr("ManagedInstances"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](5),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitCount),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Dedup - GRS"),
	// 				Value: to.Ptr("GRSDedupStorageUsage"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitBytes),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Dedup - LRS"),
	// 				Value: to.Ptr("LRSDedupStorageUsage"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](0),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitBytes),
	// 		},
	// 		{
	// 			Name: &armrecoveryservices.NameInfo{
	// 				LocalizedValue: to.Ptr("Backup Engines' Disk Used"),
	// 				Value: to.Ptr("UsedDiskSize"),
	// 			},
	// 			CurrentValue: to.Ptr[int64](117851553792),
	// 			Limit: to.Ptr[int64](-1),
	// 			Unit: to.Ptr(armrecoveryservices.UsagesUnitBytes),
	// 	}},
	// }
}
Output:

type UsagesClientListByVaultsOptions

type UsagesClientListByVaultsOptions struct {
}

UsagesClientListByVaultsOptions contains the optional parameters for the UsagesClient.NewListByVaultsPager method.

type UsagesClientListByVaultsResponse

type UsagesClientListByVaultsResponse struct {
	// Usage for vault.
	VaultUsageList
}

UsagesClientListByVaultsResponse contains the response from method UsagesClient.NewListByVaultsPager.

type UsagesUnit

type UsagesUnit string

UsagesUnit - Unit of the usage.

const (
	UsagesUnitBytes          UsagesUnit = "Bytes"
	UsagesUnitBytesPerSecond UsagesUnit = "BytesPerSecond"
	UsagesUnitCount          UsagesUnit = "Count"
	UsagesUnitCountPerSecond UsagesUnit = "CountPerSecond"
	UsagesUnitPercent        UsagesUnit = "Percent"
	UsagesUnitSeconds        UsagesUnit = "Seconds"
)

func PossibleUsagesUnitValues

func PossibleUsagesUnitValues() []UsagesUnit

PossibleUsagesUnitValues returns the possible values for the UsagesUnit const type.

type UserIdentity

type UserIdentity struct {
	// READ-ONLY; The client ID of the user-assigned identity.
	ClientID *string

	// READ-ONLY; The principal ID of the user-assigned identity.
	PrincipalID *string
}

UserIdentity - A resource identity that is managed by the user of the service.

func (UserIdentity) MarshalJSON

func (u UserIdentity) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UserIdentity.

func (*UserIdentity) UnmarshalJSON

func (u *UserIdentity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UserIdentity.

type Vault

type Vault struct {
	// REQUIRED; Resource location.
	Location *string

	// Optional ETag.
	Etag *string

	// Identity for the resource.
	Identity *IdentityData

	// Properties of the vault.
	Properties *VaultProperties

	// Identifies the unique system identifier for each Azure resource.
	SKU *SKU

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Resource Id represents the complete path to the resource.
	ID *string

	// READ-ONLY; Resource name associated with the resource.
	Name *string

	// READ-ONLY; Metadata pertaining to creation and last modification of the resource.
	SystemData *SystemData

	// READ-ONLY; Resource type represents the complete path of the form Namespace/ResourceType/ResourceType/…
	Type *string
}

Vault - Resource information, as returned by the resource provider.

func (Vault) MarshalJSON

func (v Vault) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Vault.

func (*Vault) UnmarshalJSON

func (v *Vault) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Vault.

type VaultCertificateResponse

type VaultCertificateResponse struct {
	// Certificate details representing the Vault credentials.
	Properties ResourceCertificateDetailsClassification

	// READ-ONLY; Resource Id represents the complete path to the resource.
	ID *string

	// READ-ONLY; Resource name associated with the resource.
	Name *string

	// READ-ONLY; Resource type represents the complete path of the form Namespace/ResourceType/ResourceType/…
	Type *string
}

VaultCertificateResponse - Certificate corresponding to a vault that can be used by clients to register themselves with the vault.

func (VaultCertificateResponse) MarshalJSON

func (v VaultCertificateResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultCertificateResponse.

func (*VaultCertificateResponse) UnmarshalJSON

func (v *VaultCertificateResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultCertificateResponse.

type VaultCertificatesClient

type VaultCertificatesClient struct {
	// contains filtered or unexported fields
}

VaultCertificatesClient contains the methods for the VaultCertificates group. Don't use this type directly, use NewVaultCertificatesClient() instead.

func NewVaultCertificatesClient

func NewVaultCertificatesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*VaultCertificatesClient, error)

NewVaultCertificatesClient creates a new instance of VaultCertificatesClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*VaultCertificatesClient) Create

func (client *VaultCertificatesClient) Create(ctx context.Context, resourceGroupName string, vaultName string, certificateName string, certificateRequest CertificateRequest, options *VaultCertificatesClientCreateOptions) (VaultCertificatesClientCreateResponse, error)

Create - Uploads a certificate for a resource. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • certificateName - Certificate friendly name.
  • certificateRequest - Input parameters for uploading the vault certificate.
  • options - VaultCertificatesClientCreateOptions contains the optional parameters for the VaultCertificatesClient.Create method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PUTVaultCred.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewVaultCertificatesClient().Create(ctx, "BCDRIbzRG", "BCDRIbzVault", "BCDRIbzVault77777777-d41f-4550-9f70-7708a3a2283b-12-18-2017-vaultcredentials", armrecoveryservices.CertificateRequest{
	Properties: &armrecoveryservices.RawCertificateData{
		AuthType:    to.Ptr(armrecoveryservices.AuthTypeAAD),
		Certificate: []byte("TUlJRE5EQ0NBaHlnQXdJQkFnSVFDYUxFKzVTSlNVeWdncDM0VS9HUm9qQU5CZ2txaGtpRzl3MEJBUXNGQURBWE1SVXdFd1lEVlFRREV3eGhiV05vWVc1a2JpNWpiMjB3SGhjTk1qSXhNREkwTVRJd05qRTRXaGNOTWpNeE1ESTBNVEl4TmpFNFdqQVhNUlV3RXdZRFZRUURFd3hoYldOb1lXNWtiaTVqYjIwd2dnRWlNQTBHQ1NxR1NJYjNEUUVCQVFVQUE0SUJEd0F3Z2dFS0FvSUJBUUN4cFpwS293a2p4VU9VWkpLT2JvdGdPWXkzaW9UVkxMMmZyaW9nZVN1Qm5IMWw3aVdQWW9kUHRoWS8yVmh6ZFVUckNXL25pNUh3b0JHYzZMMHF6UGlBWXpHek94RmpMQjZjdFNkbm9nL1A4eEV2OGE0cnJWZlBZdS9INStoTGx3N0RubXlTNWs4TU9sSVhUemVWNkxZV2I2RWlpTFppc0k1R3lLU1liemNaQmJKdnhLTVdGdHRCV08xZUwzUWNUejlpb1VGQzVnRlFKQzg3YXFkeDR1Wk9WYzRLM3Ixb09sTFBKdmRLN25YU3VWci9ZOC80ZHhCdDJZUTRia0hjM2EzcUNBbTZrV0QzamRiajhCZmhlWWNVNjFFZ3llVFV2MlI4dzRubWJqVXZxRW05cDZtTG4xMTdEWWpQTHNFODVTL0FpQmF0dkNhQ3hCZ0lxb1N1blBOUkFnTUJBQUdqZkRCNk1BNEdBMVVkRHdFQi93UUVBd0lGb0RBSkJnTlZIUk1FQWpBQU1CMEdBMVVkSlFRV01CUUdDQ3NHQVFVRkJ3TUJCZ2dyQmdFRkJRY0RBakFmQmdOVkhTTUVHREFXZ0JRR1NZcDJMUTJwOE5wMHUzRThJZDdRUjRTQXBqQWRCZ05WSFE0RUZnUVVCa21LZGkwTnFmRGFkTHR4UENIZTBFZUVnS1l3RFFZSktvWklodmNOQVFFTEJRQURnZ0VCQUp2ZG9yRmJ4cExZaUhYRHpnR001WmxMWTRDZE1LYW5BdzVDZDNFVnhDbkhtT05ISnpLRmpzdHZjdUN1TDZ2S1ptci9abm5ENXNLUnE0d0xnTXV6dlNXNGtQTXlWeENrYzdVYnNZSWJCSXNIUDl3cUNmcUY5aG5LSE9YZFJJV2tBVXhnbmYxSlpLZjR1NlpTSzZ3dExaME9VT0c5Mmd3SlB2eW5PVmJoeWpqczdQTVpONEw1djZyeHJkRWp0WG5sYzIvRDlnS0NOTFhFZHdRM0dzS05ZTGZvYy9DT3JmbEIrRHVPSThrVzM0WmxzYlFHelgyQ3ArWVVlSDNrQlBjY3RpUWNURHFQcW5YS0NNMTJ6MGZDTjVpNXRkRlUrM0VzemZBQkpiOEZpU2ZCWFF1UUZRRDNDTDkraVdjZXhrMmxQako2akZIbHZtak9XbTdjQllHZlc4ST0="),
	},
}, 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.VaultCertificateResponse = armrecoveryservices.VaultCertificateResponse{
// 	Name: to.Ptr("BCDRIbzVault77777777-d41f-4550-9f70-7708a3a2283b-12-18-2017-vaultcredentials"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults/certificates"),
// 	ID: to.Ptr("/Subscriptions/77777777-d41f-4550-9f70-7708a3a2283b/resourceGroups/BCDRIbzRG/providers/Microsoft.RecoveryServices/vaults/BCDRIbzVault/certificates/BCDRIbzVault77777777-d41f-4550-9f70-7708a3a2283b-12-18-2017-vaultcredentials"),
// 	Properties: &armrecoveryservices.ResourceCertificateAndAADDetails{
// 		AuthType: to.Ptr("AzureActiveDirectory"),
// 		Certificate: []byte("TUlJRE5EQ0NBaHlnQXdJQkFnSVFDYUxFKzVTSlNVeWdncDM0VS9HUm9qQU5CZ2txaGtpRzl3MEJBUXNGQURBWE1SVXdFd1lEVlFRREV3eGhiV05vWVc1a2JpNWpiMjB3SGhjTk1qSXhNREkwTVRJd05qRTRXaGNOTWpNeE1ESTBNVEl4TmpFNFdqQVhNUlV3RXdZRFZRUURFd3hoYldOb1lXNWtiaTVqYjIwd2dnRWlNQTBHQ1NxR1NJYjNEUUVCQVFVQUE0SUJEd0F3Z2dFS0FvSUJBUUN4cFpwS293a2p4VU9VWkpLT2JvdGdPWXkzaW9UVkxMMmZyaW9nZVN1Qm5IMWw3aVdQWW9kUHRoWS8yVmh6ZFVUckNXL25pNUh3b0JHYzZMMHF6UGlBWXpHek94RmpMQjZjdFNkbm9nL1A4eEV2OGE0cnJWZlBZdS9INStoTGx3N0RubXlTNWs4TU9sSVhUemVWNkxZV2I2RWlpTFppc0k1R3lLU1liemNaQmJKdnhLTVdGdHRCV08xZUwzUWNUejlpb1VGQzVnRlFKQzg3YXFkeDR1Wk9WYzRLM3Ixb09sTFBKdmRLN25YU3VWci9ZOC80ZHhCdDJZUTRia0hjM2EzcUNBbTZrV0QzamRiajhCZmhlWWNVNjFFZ3llVFV2MlI4dzRubWJqVXZxRW05cDZtTG4xMTdEWWpQTHNFODVTL0FpQmF0dkNhQ3hCZ0lxb1N1blBOUkFnTUJBQUdqZkRCNk1BNEdBMVVkRHdFQi93UUVBd0lGb0RBSkJnTlZIUk1FQWpBQU1CMEdBMVVkSlFRV01CUUdDQ3NHQVFVRkJ3TUJCZ2dyQmdFRkJRY0RBakFmQmdOVkhTTUVHREFXZ0JRR1NZcDJMUTJwOE5wMHUzRThJZDdRUjRTQXBqQWRCZ05WSFE0RUZnUVVCa21LZGkwTnFmRGFkTHR4UENIZTBFZUVnS1l3RFFZSktvWklodmNOQVFFTEJRQURnZ0VCQUp2ZG9yRmJ4cExZaUhYRHpnR001WmxMWTRDZE1LYW5BdzVDZDNFVnhDbkhtT05ISnpLRmpzdHZjdUN1TDZ2S1ptci9abm5ENXNLUnE0d0xnTXV6dlNXNGtQTXlWeENrYzdVYnNZSWJCSXNIUDl3cUNmcUY5aG5LSE9YZFJJV2tBVXhnbmYxSlpLZjR1NlpTSzZ3dExaME9VT0c5Mmd3SlB2eW5PVmJoeWpqczdQTVpONEw1djZyeHJkRWp0WG5sYzIvRDlnS0NOTFhFZHdRM0dzS05ZTGZvYy9DT3JmbEIrRHVPSThrVzM0WmxzYlFHelgyQ3ArWVVlSDNrQlBjY3RpUWNURHFQcW5YS0NNMTJ6MGZDTjVpNXRkRlUrM0VzemZBQkpiOEZpU2ZCWFF1UUZRRDNDTDkraVdjZXhrMmxQako2akZIbHZtak9XbTdjQllHZlc4ST0="),
// 		FriendlyName: to.Ptr(""),
// 		Issuer: to.Ptr("CN=Windows Azure Tools"),
// 		ResourceID: to.Ptr[int64](8726350008099341000),
// 		Subject: to.Ptr("CN=Windows Azure Tools"),
// 		Thumbprint: to.Ptr("019FE9BAD18A5A09A5CA53B593AF66331F3054AF"),
// 		ValidFrom: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-12-18T09:17:53.000Z"); return t}()),
// 		ValidTo: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-12-23T09:27:53.000Z"); return t}()),
// 		AADAudience: to.Ptr("api://9b0c2069-2eba-489f-95f4-eca15cb602ab/RecoveryServiceVault/US/AADReregisterTest/8726350008099341699"),
// 		AADAuthority: to.Ptr("https://login.windows.net"),
// 		AADTenantID: to.Ptr("9b0c2069-2eba-489f-95f4-eca15cb602ab"),
// 		AzureManagementEndpointAudience: to.Ptr("https://ppe1-id1.wus.wabppe.obs-test.com/restapi/"),
// 		ServicePrincipalClientID: to.Ptr("4932d0bd-b5f9-4659-94a0-7ab02d918933"),
// 		ServicePrincipalObjectID: to.Ptr("2d60221e-cef5-4e13-ba66-b33701a533bb"),
// 	},
// }
Output:

type VaultCertificatesClientCreateOptions

type VaultCertificatesClientCreateOptions struct {
}

VaultCertificatesClientCreateOptions contains the optional parameters for the VaultCertificatesClient.Create method.

type VaultCertificatesClientCreateResponse

type VaultCertificatesClientCreateResponse struct {
	// Certificate corresponding to a vault that can be used by clients to register themselves with the vault.
	VaultCertificateResponse
}

VaultCertificatesClientCreateResponse contains the response from method VaultCertificatesClient.Create.

type VaultExtendedInfo

type VaultExtendedInfo struct {
	// Algorithm for Vault ExtendedInfo
	Algorithm *string

	// Encryption key.
	EncryptionKey *string

	// Encryption key thumbprint.
	EncryptionKeyThumbprint *string

	// Integrity key.
	IntegrityKey *string
}

VaultExtendedInfo - Vault extended information.

func (VaultExtendedInfo) MarshalJSON

func (v VaultExtendedInfo) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultExtendedInfo.

func (*VaultExtendedInfo) UnmarshalJSON

func (v *VaultExtendedInfo) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultExtendedInfo.

type VaultExtendedInfoClient

type VaultExtendedInfoClient struct {
	// contains filtered or unexported fields
}

VaultExtendedInfoClient contains the methods for the VaultExtendedInfo group. Don't use this type directly, use NewVaultExtendedInfoClient() instead.

func NewVaultExtendedInfoClient

func NewVaultExtendedInfoClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*VaultExtendedInfoClient, error)

NewVaultExtendedInfoClient creates a new instance of VaultExtendedInfoClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*VaultExtendedInfoClient) CreateOrUpdate

func (client *VaultExtendedInfoClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, vaultName string, resourceExtendedInfoDetails VaultExtendedInfoResource, options *VaultExtendedInfoClientCreateOrUpdateOptions) (VaultExtendedInfoClientCreateOrUpdateResponse, error)

CreateOrUpdate - Create vault extended info. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • resourceExtendedInfoDetails - Details of ResourceExtendedInfo
  • options - VaultExtendedInfoClientCreateOrUpdateOptions contains the optional parameters for the VaultExtendedInfoClient.CreateOrUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/UpdateVaultExtendedInfo.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewVaultExtendedInfoClient().CreateOrUpdate(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", armrecoveryservices.VaultExtendedInfoResource{}, 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.VaultExtendedInfoResource = armrecoveryservices.VaultExtendedInfoResource{
// 	Name: to.Ptr("vaultExtendedInfo"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults/extendedInformation"),
// 	Etag: to.Ptr("f0d0260b-b92d-4458-ba0a-32c6cdabacb7"),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample/extendedInformation/vaultExtendedInfo"),
// 	Properties: &armrecoveryservices.VaultExtendedInfo{
// 		Algorithm: to.Ptr("None"),
// 		IntegrityKey: to.Ptr("J99wzS27fmJ+Wjot7xO5wA=="),
// 	},
// }
Output:

func (*VaultExtendedInfoClient) Get

Get - Get the vault extended info. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - VaultExtendedInfoClientGetOptions contains the optional parameters for the VaultExtendedInfoClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/GETVaultExtendedInfo.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewVaultExtendedInfoClient().Get(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", 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.VaultExtendedInfoResource = armrecoveryservices.VaultExtendedInfoResource{
// 	Name: to.Ptr("vaultExtendedInfo"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults/extendedInformation"),
// 	Etag: to.Ptr("f0d0260b-b92d-4458-ba0a-32c6cdabacb7"),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample/extendedInformation/vaultExtendedInfo"),
// 	Properties: &armrecoveryservices.VaultExtendedInfo{
// 		Algorithm: to.Ptr("None"),
// 		IntegrityKey: to.Ptr("J09wzS27fnJ+Wjot7xO5wA=="),
// 	},
// }
Output:

func (*VaultExtendedInfoClient) Update

func (client *VaultExtendedInfoClient) Update(ctx context.Context, resourceGroupName string, vaultName string, resourceExtendedInfoDetails VaultExtendedInfoResource, options *VaultExtendedInfoClientUpdateOptions) (VaultExtendedInfoClientUpdateResponse, error)

Update - Update vault extended info. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • resourceExtendedInfoDetails - Details of ResourceExtendedInfo
  • options - VaultExtendedInfoClientUpdateOptions contains the optional parameters for the VaultExtendedInfoClient.Update method.

type VaultExtendedInfoClientCreateOrUpdateOptions

type VaultExtendedInfoClientCreateOrUpdateOptions struct {
}

VaultExtendedInfoClientCreateOrUpdateOptions contains the optional parameters for the VaultExtendedInfoClient.CreateOrUpdate method.

type VaultExtendedInfoClientCreateOrUpdateResponse

type VaultExtendedInfoClientCreateOrUpdateResponse struct {
	// Vault extended information.
	VaultExtendedInfoResource
}

VaultExtendedInfoClientCreateOrUpdateResponse contains the response from method VaultExtendedInfoClient.CreateOrUpdate.

type VaultExtendedInfoClientGetOptions

type VaultExtendedInfoClientGetOptions struct {
}

VaultExtendedInfoClientGetOptions contains the optional parameters for the VaultExtendedInfoClient.Get method.

type VaultExtendedInfoClientGetResponse

type VaultExtendedInfoClientGetResponse struct {
	// Vault extended information.
	VaultExtendedInfoResource
}

VaultExtendedInfoClientGetResponse contains the response from method VaultExtendedInfoClient.Get.

type VaultExtendedInfoClientUpdateOptions

type VaultExtendedInfoClientUpdateOptions struct {
}

VaultExtendedInfoClientUpdateOptions contains the optional parameters for the VaultExtendedInfoClient.Update method.

type VaultExtendedInfoClientUpdateResponse

type VaultExtendedInfoClientUpdateResponse struct {
	// Vault extended information.
	VaultExtendedInfoResource
}

VaultExtendedInfoClientUpdateResponse contains the response from method VaultExtendedInfoClient.Update.

type VaultExtendedInfoResource

type VaultExtendedInfoResource struct {
	// Optional ETag.
	Etag *string

	// Vault extended information.
	Properties *VaultExtendedInfo

	// READ-ONLY; Resource Id represents the complete path to the resource.
	ID *string

	// READ-ONLY; Resource name associated with the resource.
	Name *string

	// READ-ONLY; Resource type represents the complete path of the form Namespace/ResourceType/ResourceType/…
	Type *string
}

VaultExtendedInfoResource - Vault extended information.

func (VaultExtendedInfoResource) MarshalJSON

func (v VaultExtendedInfoResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultExtendedInfoResource.

func (*VaultExtendedInfoResource) UnmarshalJSON

func (v *VaultExtendedInfoResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultExtendedInfoResource.

type VaultList

type VaultList struct {
	Value []*Vault

	// READ-ONLY
	NextLink *string
}

VaultList - The response model for a list of Vaults.

func (VaultList) MarshalJSON

func (v VaultList) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultList.

func (*VaultList) UnmarshalJSON

func (v *VaultList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultList.

type VaultPrivateEndpointState

type VaultPrivateEndpointState string

VaultPrivateEndpointState - Private endpoint state for backup.

const (
	VaultPrivateEndpointStateEnabled VaultPrivateEndpointState = "Enabled"
	VaultPrivateEndpointStateNone    VaultPrivateEndpointState = "None"
)

func PossibleVaultPrivateEndpointStateValues

func PossibleVaultPrivateEndpointStateValues() []VaultPrivateEndpointState

PossibleVaultPrivateEndpointStateValues returns the possible values for the VaultPrivateEndpointState const type.

type VaultProperties

type VaultProperties struct {
	// Customer Managed Key details of the resource.
	Encryption *VaultPropertiesEncryption

	// Monitoring Settings of the vault
	MonitoringSettings *MonitoringSettings

	// The details of the latest move operation performed on the Azure Resource
	MoveDetails *VaultPropertiesMoveDetails

	// property to enable or disable resource provider inbound network traffic from public clients
	PublicNetworkAccess *PublicNetworkAccess

	// The redundancy Settings of a Vault
	RedundancySettings *VaultPropertiesRedundancySettings

	// ResourceGuardOperationRequests on which LAC check will be performed
	ResourceGuardOperationRequests []*string

	// Restore Settings of the vault
	RestoreSettings *RestoreSettings

	// Security Settings of the vault
	SecuritySettings *SecuritySettings

	// Details for upgrading vault.
	UpgradeDetails *UpgradeDetails

	// READ-ONLY; Backup storage version
	BackupStorageVersion *BackupStorageVersion

	// READ-ONLY; Security levels of Recovery Services Vault for business continuity and disaster recovery
	BcdrSecurityLevel *BCDRSecurityLevel

	// READ-ONLY; The State of the Resource after the move operation
	MoveState *ResourceMoveState

	// READ-ONLY; List of private endpoint connection.
	PrivateEndpointConnections []*PrivateEndpointConnectionVaultProperties

	// READ-ONLY; Private endpoint state for backup.
	PrivateEndpointStateForBackup *VaultPrivateEndpointState

	// READ-ONLY; Private endpoint state for site recovery.
	PrivateEndpointStateForSiteRecovery *VaultPrivateEndpointState

	// READ-ONLY; Provisioning State.
	ProvisioningState *string

	// READ-ONLY; Secure Score of Recovery Services Vault
	SecureScore *SecureScoreLevel
}

VaultProperties - Properties of the vault.

func (VaultProperties) MarshalJSON

func (v VaultProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultProperties.

func (*VaultProperties) UnmarshalJSON

func (v *VaultProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultProperties.

type VaultPropertiesEncryption

type VaultPropertiesEncryption struct {
	// Enabling/Disabling the Double Encryption state
	InfrastructureEncryption *InfrastructureEncryptionState

	// The details of the identity used for CMK
	KekIdentity *CmkKekIdentity

	// The properties of the Key Vault which hosts CMK
	KeyVaultProperties *CmkKeyVaultProperties
}

VaultPropertiesEncryption - Customer Managed Key details of the resource.

func (VaultPropertiesEncryption) MarshalJSON

func (v VaultPropertiesEncryption) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultPropertiesEncryption.

func (*VaultPropertiesEncryption) UnmarshalJSON

func (v *VaultPropertiesEncryption) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultPropertiesEncryption.

type VaultPropertiesMoveDetails

type VaultPropertiesMoveDetails struct {
	// READ-ONLY; End Time of the Resource Move Operation
	CompletionTimeUTC *time.Time

	// READ-ONLY; OperationId of the Resource Move Operation
	OperationID *string

	// READ-ONLY; Source Resource of the Resource Move Operation
	SourceResourceID *string

	// READ-ONLY; Start Time of the Resource Move Operation
	StartTimeUTC *time.Time

	// READ-ONLY; Target Resource of the Resource Move Operation
	TargetResourceID *string
}

VaultPropertiesMoveDetails - The details of the latest move operation performed on the Azure Resource

func (VaultPropertiesMoveDetails) MarshalJSON

func (v VaultPropertiesMoveDetails) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultPropertiesMoveDetails.

func (*VaultPropertiesMoveDetails) UnmarshalJSON

func (v *VaultPropertiesMoveDetails) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultPropertiesMoveDetails.

type VaultPropertiesRedundancySettings

type VaultPropertiesRedundancySettings struct {
	// Flag to show if Cross Region Restore is enabled on the Vault or not
	CrossRegionRestore *CrossRegionRestore

	// The storage redundancy setting of a vault
	StandardTierStorageRedundancy *StandardTierStorageRedundancy
}

VaultPropertiesRedundancySettings - The redundancy Settings of a Vault

func (VaultPropertiesRedundancySettings) MarshalJSON

func (v VaultPropertiesRedundancySettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultPropertiesRedundancySettings.

func (*VaultPropertiesRedundancySettings) UnmarshalJSON

func (v *VaultPropertiesRedundancySettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultPropertiesRedundancySettings.

type VaultSubResourceType

type VaultSubResourceType string

VaultSubResourceType - Subresource type for vault AzureBackup, AzureBackup_secondary or AzureSiteRecovery

const (
	VaultSubResourceTypeAzureBackup          VaultSubResourceType = "AzureBackup"
	VaultSubResourceTypeAzureBackupSecondary VaultSubResourceType = "AzureBackup_secondary"
	VaultSubResourceTypeAzureSiteRecovery    VaultSubResourceType = "AzureSiteRecovery"
)

func PossibleVaultSubResourceTypeValues

func PossibleVaultSubResourceTypeValues() []VaultSubResourceType

PossibleVaultSubResourceTypeValues returns the possible values for the VaultSubResourceType const type.

type VaultUpgradeState

type VaultUpgradeState string

VaultUpgradeState - Status of the vault upgrade operation.

const (
	VaultUpgradeStateFailed     VaultUpgradeState = "Failed"
	VaultUpgradeStateInProgress VaultUpgradeState = "InProgress"
	VaultUpgradeStateUnknown    VaultUpgradeState = "Unknown"
	VaultUpgradeStateUpgraded   VaultUpgradeState = "Upgraded"
)

func PossibleVaultUpgradeStateValues

func PossibleVaultUpgradeStateValues() []VaultUpgradeState

PossibleVaultUpgradeStateValues returns the possible values for the VaultUpgradeState const type.

type VaultUsage

type VaultUsage struct {
	// Current value of usage.
	CurrentValue *int64

	// Limit of usage.
	Limit *int64

	// Name of usage.
	Name *NameInfo

	// Next reset time of usage.
	NextResetTime *time.Time

	// Quota period of usage.
	QuotaPeriod *string

	// Unit of the usage.
	Unit *UsagesUnit
}

VaultUsage - Usages of a vault.

func (VaultUsage) MarshalJSON

func (v VaultUsage) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultUsage.

func (*VaultUsage) UnmarshalJSON

func (v *VaultUsage) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultUsage.

type VaultUsageList

type VaultUsageList struct {
	// The list of usages for the given vault.
	Value []*VaultUsage
}

VaultUsageList - Usage for vault.

func (VaultUsageList) MarshalJSON

func (v VaultUsageList) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VaultUsageList.

func (*VaultUsageList) UnmarshalJSON

func (v *VaultUsageList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VaultUsageList.

type VaultsClient

type VaultsClient struct {
	// contains filtered or unexported fields
}

VaultsClient contains the methods for the Vaults group. Don't use this type directly, use NewVaultsClient() instead.

func NewVaultsClient

func NewVaultsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*VaultsClient, error)

NewVaultsClient creates a new instance of VaultsClient with the specified values.

  • subscriptionID - The ID of the target subscription.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*VaultsClient) BeginCreateOrUpdate

func (client *VaultsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, vaultName string, vault Vault, options *VaultsClientBeginCreateOrUpdateOptions) (*runtime.Poller[VaultsClientCreateOrUpdateResponse], error)

BeginCreateOrUpdate - Creates or updates a Recovery Services vault. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • vault - Recovery Services Vault to be created.
  • options - VaultsClientBeginCreateOrUpdateOptions contains the optional parameters for the VaultsClient.BeginCreateOrUpdate method.
Example (CreateOrUpdateRecoveryServicesVault)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PUTVault.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginCreateOrUpdate(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", armrecoveryservices.Vault{
	Location: to.Ptr("West US"),
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeSystemAssigned),
	},
	Properties: &armrecoveryservices.VaultProperties{
		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
	},
	SKU: &armrecoveryservices.SKU{
		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	},
}, &armrecoveryservices.VaultsClientBeginCreateOrUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeSystemAssigned),
// 		PrincipalID: to.Ptr("3137d6c7-5d6c-411c-b934-7a2a729ee247"),
// 		TenantID: to.Ptr("d676e86e-2206-4a7c-999c-ece52c144b5b"),
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameRS0),
// 		Tier: to.Ptr("Standard"),
// 	},
// }
Output:

Example (CreateOrUpdateVaultPerformingCriticalOperationWithMua)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PUTVault_ResourceGuardEnabled.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginCreateOrUpdate(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", armrecoveryservices.Vault{
	Location: to.Ptr("West US"),
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": {},
		},
	},
	Properties: &armrecoveryservices.VaultProperties{
		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
			InfrastructureEncryption: to.Ptr(armrecoveryservices.InfrastructureEncryptionStateEnabled),
			KekIdentity: &armrecoveryservices.CmkKekIdentity{
				UserAssignedIdentity: to.Ptr("/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi"),
			},
			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
			},
		},
		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
		ResourceGuardOperationRequests: []*string{
			to.Ptr("/subscriptions/38304e13-357e-405e-9e9a-220351dcce8c/resourcegroups/ankurResourceGuard1/providers/Microsoft.DataProtection/resourceGuards/ResourceGuard38-1/modifyEncryptionSettings/default")},
	},
	SKU: &armrecoveryservices.SKU{
		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	},
}, &armrecoveryservices.VaultsClientBeginCreateOrUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
// 		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
// 			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": &armrecoveryservices.UserIdentity{
// 				ClientID: to.Ptr("fbe75b66-01c5-4f87-a220-233af3270436"),
// 				PrincipalID: to.Ptr("075a0ca6-43f6-4434-9abf-c9b1b79f9219"),
// 			},
// 		},
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
// 			InfrastructureEncryption: to.Ptr(armrecoveryservices.InfrastructureEncryptionStateEnabled),
// 			KekIdentity: &armrecoveryservices.CmkKekIdentity{
// 				UseSystemAssignedIdentity: to.Ptr(false),
// 				UserAssignedIdentity: to.Ptr("/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi"),
// 			},
// 			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
// 				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
// 			},
// 		},
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

Example (CreateOrUpdateVaultWithCustomerManagedKeys)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PUTVault_WithCMK.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginCreateOrUpdate(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", armrecoveryservices.Vault{
	Location: to.Ptr("West US"),
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": {},
		},
	},
	Properties: &armrecoveryservices.VaultProperties{
		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
			InfrastructureEncryption: to.Ptr(armrecoveryservices.InfrastructureEncryptionStateEnabled),
			KekIdentity: &armrecoveryservices.CmkKekIdentity{
				UserAssignedIdentity: to.Ptr("/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi"),
			},
			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
			},
		},
		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
	},
	SKU: &armrecoveryservices.SKU{
		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	},
}, &armrecoveryservices.VaultsClientBeginCreateOrUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
// 		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
// 			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": &armrecoveryservices.UserIdentity{
// 				ClientID: to.Ptr("fbe75b66-01c5-4f87-a220-233af3270436"),
// 				PrincipalID: to.Ptr("075a0ca6-43f6-4434-9abf-c9b1b79f9219"),
// 			},
// 		},
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
// 			InfrastructureEncryption: to.Ptr(armrecoveryservices.InfrastructureEncryptionStateEnabled),
// 			KekIdentity: &armrecoveryservices.CmkKekIdentity{
// 				UseSystemAssignedIdentity: to.Ptr(false),
// 				UserAssignedIdentity: to.Ptr("/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi"),
// 			},
// 			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
// 				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
// 			},
// 		},
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

Example (CreateOrUpdateVaultWithMonitoringSetting)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PUTVault_WithMonitoringSettings.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginCreateOrUpdate(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", armrecoveryservices.Vault{
	Location: to.Ptr("West US"),
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeSystemAssigned),
	},
	Properties: &armrecoveryservices.VaultProperties{
		MonitoringSettings: &armrecoveryservices.MonitoringSettings{
			AzureMonitorAlertSettings: &armrecoveryservices.AzureMonitorAlertSettings{
				AlertsForAllFailoverIssues:    to.Ptr(armrecoveryservices.AlertsStateDisabled),
				AlertsForAllJobFailures:       to.Ptr(armrecoveryservices.AlertsStateEnabled),
				AlertsForAllReplicationIssues: to.Ptr(armrecoveryservices.AlertsStateEnabled),
			},
			ClassicAlertSettings: &armrecoveryservices.ClassicAlertSettings{
				AlertsForCriticalOperations:       to.Ptr(armrecoveryservices.AlertsStateDisabled),
				EmailNotificationsForSiteRecovery: to.Ptr(armrecoveryservices.AlertsStateEnabled),
			},
		},
		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
	},
	SKU: &armrecoveryservices.SKU{
		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	},
}, &armrecoveryservices.VaultsClientBeginCreateOrUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeSystemAssigned),
// 		PrincipalID: to.Ptr("3137d6c7-5d6c-411c-b934-7a2a729ee247"),
// 		TenantID: to.Ptr("d676e86e-2206-4a7c-999c-ece52c144b5b"),
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		MonitoringSettings: &armrecoveryservices.MonitoringSettings{
// 			AzureMonitorAlertSettings: &armrecoveryservices.AzureMonitorAlertSettings{
// 				AlertsForAllFailoverIssues: to.Ptr(armrecoveryservices.AlertsStateDisabled),
// 				AlertsForAllJobFailures: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 				AlertsForAllReplicationIssues: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 			},
// 			ClassicAlertSettings: &armrecoveryservices.ClassicAlertSettings{
// 				AlertsForCriticalOperations: to.Ptr(armrecoveryservices.AlertsStateDisabled),
// 				EmailNotificationsForSiteRecovery: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 			},
// 		},
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameRS0),
// 		Tier: to.Ptr("Standard"),
// 	},
// }
Output:

Example (CreateOrUpdateVaultWithRedundancySetting)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PUTVault_WithRedundancySettings.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginCreateOrUpdate(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", armrecoveryservices.Vault{
	Location: to.Ptr("West US"),
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeSystemAssigned),
	},
	Properties: &armrecoveryservices.VaultProperties{
		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
		RedundancySettings: &armrecoveryservices.VaultPropertiesRedundancySettings{
			CrossRegionRestore:            to.Ptr(armrecoveryservices.CrossRegionRestoreEnabled),
			StandardTierStorageRedundancy: to.Ptr(armrecoveryservices.StandardTierStorageRedundancyGeoRedundant),
		},
	},
	SKU: &armrecoveryservices.SKU{
		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	},
}, &armrecoveryservices.VaultsClientBeginCreateOrUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeSystemAssigned),
// 		PrincipalID: to.Ptr("3137d6c7-5d6c-411c-b934-7a2a729ee247"),
// 		TenantID: to.Ptr("d676e86e-2206-4a7c-999c-ece52c144b5b"),
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 		RedundancySettings: &armrecoveryservices.VaultPropertiesRedundancySettings{
// 			CrossRegionRestore: to.Ptr(armrecoveryservices.CrossRegionRestoreEnabled),
// 			StandardTierStorageRedundancy: to.Ptr(armrecoveryservices.StandardTierStorageRedundancyGeoRedundant),
// 		},
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameRS0),
// 		Tier: to.Ptr("Standard"),
// 	},
// }
Output:

Example (CreateOrUpdateVaultWithUserAssignedIdentity)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PUTVault_WithUserAssignedIdentity.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginCreateOrUpdate(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", armrecoveryservices.Vault{
	Location: to.Ptr("West US"),
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": {},
		},
	},
	Properties: &armrecoveryservices.VaultProperties{
		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
	},
	SKU: &armrecoveryservices.SKU{
		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	},
}, &armrecoveryservices.VaultsClientBeginCreateOrUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
// 		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
// 			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": &armrecoveryservices.UserIdentity{
// 				ClientID: to.Ptr("fbe75b66-01c5-4f87-a220-233af3270436"),
// 				PrincipalID: to.Ptr("075a0ca6-43f6-4434-9abf-c9b1b79f9219"),
// 			},
// 		},
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

func (*VaultsClient) BeginDelete

func (client *VaultsClient) BeginDelete(ctx context.Context, resourceGroupName string, vaultName string, options *VaultsClientBeginDeleteOptions) (*runtime.Poller[VaultsClientDeleteResponse], error)

BeginDelete - Deletes a vault. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - VaultsClientBeginDeleteOptions contains the optional parameters for the VaultsClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/DeleteVault.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginDelete(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", 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)
}
Output:

func (*VaultsClient) BeginUpdate

func (client *VaultsClient) BeginUpdate(ctx context.Context, resourceGroupName string, vaultName string, vault PatchVault, options *VaultsClientBeginUpdateOptions) (*runtime.Poller[VaultsClientUpdateResponse], error)

BeginUpdate - Updates the vault. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • vault - Recovery Services Vault to be created.
  • options - VaultsClientBeginUpdateOptions contains the optional parameters for the VaultsClient.BeginUpdate method.
Example (UpdateResource)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PATCHVault.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginUpdate(ctx, "HelloWorld", "swaggerExample", armrecoveryservices.PatchVault{
	Tags: map[string]*string{
		"PatchKey": to.Ptr("PatchKeyUpdated"),
	},
}, &armrecoveryservices.VaultsClientBeginUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"PatchKey": to.Ptr("PatchKeyUpdated"),
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

Example (UpdateResourceWithCustomerManagedKeys)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PATCHVault_WithCMK.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginUpdate(ctx, "HelloWorld", "swaggerExample", armrecoveryservices.PatchVault{
	Tags: map[string]*string{
		"PatchKey": to.Ptr("PatchKeyUpdated"),
	},
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": {},
		},
	},
	Properties: &armrecoveryservices.VaultProperties{
		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
			InfrastructureEncryption: to.Ptr(armrecoveryservices.InfrastructureEncryptionStateEnabled),
			KekIdentity: &armrecoveryservices.CmkKekIdentity{
				UserAssignedIdentity: to.Ptr("/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi"),
			},
			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
			},
		},
	},
}, &armrecoveryservices.VaultsClientBeginUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"PatchKey": to.Ptr("PatchKeyUpdated"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
// 		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
// 			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": &armrecoveryservices.UserIdentity{
// 				ClientID: to.Ptr("fbe75b66-01c5-4f87-a220-233af3270436"),
// 				PrincipalID: to.Ptr("075a0ca6-43f6-4434-9abf-c9b1b79f9219"),
// 			},
// 		},
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
// 			InfrastructureEncryption: to.Ptr(armrecoveryservices.InfrastructureEncryptionStateEnabled),
// 			KekIdentity: &armrecoveryservices.CmkKekIdentity{
// 				UseSystemAssignedIdentity: to.Ptr(false),
// 				UserAssignedIdentity: to.Ptr("/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi"),
// 			},
// 			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
// 				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
// 			},
// 		},
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

Example (UpdateResourceWithCustomerManagedKeys2)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PatchVault_WithCMK2.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginUpdate(ctx, "HelloWorld", "swaggerExample", armrecoveryservices.PatchVault{
	Tags: map[string]*string{
		"PatchKey": to.Ptr("PatchKeyUpdated"),
	},
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeSystemAssigned),
	},
	Properties: &armrecoveryservices.VaultProperties{
		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
			KekIdentity: &armrecoveryservices.CmkKekIdentity{
				UseSystemAssignedIdentity: to.Ptr(true),
			},
		},
	},
}, &armrecoveryservices.VaultsClientBeginUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"PatchKey": to.Ptr("PatchKeyUpdated"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
// 		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
// 			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": &armrecoveryservices.UserIdentity{
// 				ClientID: to.Ptr("fbe75b66-01c5-4f87-a220-233af3270436"),
// 				PrincipalID: to.Ptr("075a0ca6-43f6-4434-9abf-c9b1b79f9219"),
// 			},
// 		},
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
// 			InfrastructureEncryption: to.Ptr(armrecoveryservices.InfrastructureEncryptionStateEnabled),
// 			KekIdentity: &armrecoveryservices.CmkKekIdentity{
// 				UseSystemAssignedIdentity: to.Ptr(true),
// 			},
// 			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
// 				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
// 			},
// 		},
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

Example (UpdateResourceWithCustomerManagedKeys3)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PATCHVault_WithCMK3.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginUpdate(ctx, "HelloWorld", "swaggerExample", armrecoveryservices.PatchVault{
	Tags: map[string]*string{
		"PatchKey": to.Ptr("PatchKeyUpdated"),
	},
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": {},
		},
	},
	Properties: &armrecoveryservices.VaultProperties{
		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
			},
		},
	},
}, &armrecoveryservices.VaultsClientBeginUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"PatchKey": to.Ptr("PatchKeyUpdated"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
// 		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
// 			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": &armrecoveryservices.UserIdentity{
// 				ClientID: to.Ptr("fbe75b66-01c5-4f87-a220-233af3270436"),
// 				PrincipalID: to.Ptr("075a0ca6-43f6-4434-9abf-c9b1b79f9219"),
// 			},
// 		},
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		Encryption: &armrecoveryservices.VaultPropertiesEncryption{
// 			InfrastructureEncryption: to.Ptr(armrecoveryservices.InfrastructureEncryptionStateEnabled),
// 			KekIdentity: &armrecoveryservices.CmkKekIdentity{
// 				UseSystemAssignedIdentity: to.Ptr(false),
// 				UserAssignedIdentity: to.Ptr("/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi"),
// 			},
// 			KeyVaultProperties: &armrecoveryservices.CmkKeyVaultProperties{
// 				KeyURI: to.Ptr("https://cmk2xkv.vault.azure.net/keys/Key1/0767b348bb1a4c07baa6c4ec0055d2b3"),
// 			},
// 		},
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

Example (UpdateResourceWithUserAssignedIdentity)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PATCHVault_WithUserAssignedIdentity.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginUpdate(ctx, "HelloWorld", "swaggerExample", armrecoveryservices.PatchVault{
	Tags: map[string]*string{
		"PatchKey": to.Ptr("PatchKeyUpdated"),
	},
	Identity: &armrecoveryservices.IdentityData{
		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": {},
		},
	},
}, &armrecoveryservices.VaultsClientBeginUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"PatchKey": to.Ptr("PatchKeyUpdated"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeUserAssigned),
// 		UserAssignedIdentities: map[string]*armrecoveryservices.UserIdentity{
// 			"/subscriptions/85bf5e8c-3084-4f42-add2-746ebb7e97b2/resourcegroups/defaultrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/examplemsi": &armrecoveryservices.UserIdentity{
// 				ClientID: to.Ptr("fbe75b66-01c5-4f87-a220-233af3270436"),
// 				PrincipalID: to.Ptr("075a0ca6-43f6-4434-9abf-c9b1b79f9219"),
// 			},
// 		},
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

Example (UpdateVaultWithMonitoringSetting)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PATCHVault_WithMonitoringSettings.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginUpdate(ctx, "HelloWorld", "swaggerExample", armrecoveryservices.PatchVault{
	Tags: map[string]*string{
		"PatchKey": to.Ptr("PatchKeyUpdated"),
	},
	Properties: &armrecoveryservices.VaultProperties{
		MonitoringSettings: &armrecoveryservices.MonitoringSettings{
			AzureMonitorAlertSettings: &armrecoveryservices.AzureMonitorAlertSettings{
				AlertsForAllFailoverIssues:    to.Ptr(armrecoveryservices.AlertsStateDisabled),
				AlertsForAllJobFailures:       to.Ptr(armrecoveryservices.AlertsStateEnabled),
				AlertsForAllReplicationIssues: to.Ptr(armrecoveryservices.AlertsStateEnabled),
			},
			ClassicAlertSettings: &armrecoveryservices.ClassicAlertSettings{
				AlertsForCriticalOperations:       to.Ptr(armrecoveryservices.AlertsStateDisabled),
				EmailNotificationsForSiteRecovery: to.Ptr(armrecoveryservices.AlertsStateEnabled),
			},
		},
	},
}, &armrecoveryservices.VaultsClientBeginUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"PatchKey": to.Ptr("PatchKeyUpdated"),
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		MonitoringSettings: &armrecoveryservices.MonitoringSettings{
// 			AzureMonitorAlertSettings: &armrecoveryservices.AzureMonitorAlertSettings{
// 				AlertsForAllFailoverIssues: to.Ptr(armrecoveryservices.AlertsStateDisabled),
// 				AlertsForAllJobFailures: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 				AlertsForAllReplicationIssues: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 			},
// 			ClassicAlertSettings: &armrecoveryservices.ClassicAlertSettings{
// 				AlertsForCriticalOperations: to.Ptr(armrecoveryservices.AlertsStateDisabled),
// 				EmailNotificationsForSiteRecovery: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 			},
// 		},
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

Example (UpdateVaultWithRedundancySetting)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/PATCHVault_WithRedundancySettings.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewVaultsClient().BeginUpdate(ctx, "HelloWorld", "swaggerExample", armrecoveryservices.PatchVault{
	Properties: &armrecoveryservices.VaultProperties{
		RedundancySettings: &armrecoveryservices.VaultPropertiesRedundancySettings{
			CrossRegionRestore:            to.Ptr(armrecoveryservices.CrossRegionRestoreEnabled),
			StandardTierStorageRedundancy: to.Ptr(armrecoveryservices.StandardTierStorageRedundancyGeoRedundant),
		},
	},
}, &armrecoveryservices.VaultsClientBeginUpdateOptions{XMSAuthorizationAuxiliary: nil})
if err != nil {
	log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
	log.Fatalf("failed to pull the result: %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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"PatchKey": to.Ptr("PatchKeyUpdated"),
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		ProvisioningState: to.Ptr("Succeeded"),
// 		PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 		RedundancySettings: &armrecoveryservices.VaultPropertiesRedundancySettings{
// 			CrossRegionRestore: to.Ptr(armrecoveryservices.CrossRegionRestoreEnabled),
// 			StandardTierStorageRedundancy: to.Ptr(armrecoveryservices.StandardTierStorageRedundancyGeoRedundant),
// 		},
// 	},
// 	SKU: &armrecoveryservices.SKU{
// 		Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 	},
// }
Output:

func (*VaultsClient) Get

func (client *VaultsClient) Get(ctx context.Context, resourceGroupName string, vaultName string, options *VaultsClientGetOptions) (VaultsClientGetResponse, error)

Get - Get the Vault details. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • vaultName - The name of the recovery services vault.
  • options - VaultsClientGetOptions contains the optional parameters for the VaultsClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/GETVault.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewVaultsClient().Get(ctx, "Default-RecoveryServices-ResourceGroup", "swaggerExample", 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.Vault = armrecoveryservices.Vault{
// 	Name: to.Ptr("swaggerExample"),
// 	Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
// 	Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
// 	ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
// 	Location: to.Ptr("westus"),
// 	Tags: map[string]*string{
// 		"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
// 	},
// 	Identity: &armrecoveryservices.IdentityData{
// 		Type: to.Ptr(armrecoveryservices.ResourceIdentityTypeSystemAssigned),
// 		PrincipalID: to.Ptr("3137d6c7-5d6c-411c-b934-7a2a729ee247"),
// 		TenantID: to.Ptr("d676e86e-2206-4a7c-999c-ece52c144b5b"),
// 	},
// 	Properties: &armrecoveryservices.VaultProperties{
// 		BcdrSecurityLevel: to.Ptr(armrecoveryservices.BCDRSecurityLevelPoor),
// 		MonitoringSettings: &armrecoveryservices.MonitoringSettings{
// 			AzureMonitorAlertSettings: &armrecoveryservices.AzureMonitorAlertSettings{
// 				AlertsForAllFailoverIssues: to.Ptr(armrecoveryservices.AlertsStateDisabled),
// 				AlertsForAllJobFailures: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 				AlertsForAllReplicationIssues: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 			},
// 			ClassicAlertSettings: &armrecoveryservices.ClassicAlertSettings{
// 				AlertsForCriticalOperations: to.Ptr(armrecoveryservices.AlertsStateDisabled),
// 				EmailNotificationsForSiteRecovery: to.Ptr(armrecoveryservices.AlertsStateEnabled),
// 			},
// 		},
// 		PrivateEndpointConnections: []*armrecoveryservices.PrivateEndpointConnectionVaultProperties{
// 			{
// 				ID: to.Ptr("/subscriptions/6c48fa17-39c7-45f1-90ac-47a587128ace/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/Vaults/pemsi-ecy-rsv2/privateEndpointConnections/pe114-pemsi-ecy-rsv.5944358949303501042.backup.75061caa-cba4-4849-8e09-608da4914aad"),
// 				Properties: &armrecoveryservices.PrivateEndpointConnection{
// 					GroupIDs: []*armrecoveryservices.VaultSubResourceType{
// 						to.Ptr(armrecoveryservices.VaultSubResourceTypeAzureBackup)},
// 						PrivateEndpoint: &armrecoveryservices.PrivateEndpoint{
// 							ID: to.Ptr("/subscriptions/6c48fa17-39c7-45f1-90ac-47a587128ace/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.Network/privateEndpoints/pe114-pemsi-ecy-rsv"),
// 						},
// 						PrivateLinkServiceConnectionState: &armrecoveryservices.PrivateLinkServiceConnectionState{
// 							Description: to.Ptr("None"),
// 							ActionsRequired: to.Ptr("None"),
// 							Status: to.Ptr(armrecoveryservices.PrivateEndpointConnectionStatusApproved),
// 						},
// 						ProvisioningState: to.Ptr(armrecoveryservices.ProvisioningStateSucceeded),
// 					},
// 			}},
// 			PrivateEndpointStateForBackup: to.Ptr(armrecoveryservices.VaultPrivateEndpointStateEnabled),
// 			PrivateEndpointStateForSiteRecovery: to.Ptr(armrecoveryservices.VaultPrivateEndpointStateNone),
// 			ProvisioningState: to.Ptr("Succeeded"),
// 			PublicNetworkAccess: to.Ptr(armrecoveryservices.PublicNetworkAccessEnabled),
// 			RedundancySettings: &armrecoveryservices.VaultPropertiesRedundancySettings{
// 				CrossRegionRestore: to.Ptr(armrecoveryservices.CrossRegionRestoreEnabled),
// 				StandardTierStorageRedundancy: to.Ptr(armrecoveryservices.StandardTierStorageRedundancyGeoRedundant),
// 			},
// 			SecureScore: to.Ptr(armrecoveryservices.SecureScoreLevelNone),
// 			SecuritySettings: &armrecoveryservices.SecuritySettings{
// 				ImmutabilitySettings: &armrecoveryservices.ImmutabilitySettings{
// 					State: to.Ptr(armrecoveryservices.ImmutabilityStateDisabled),
// 				},
// 				MultiUserAuthorization: to.Ptr(armrecoveryservices.MultiUserAuthorizationDisabled),
// 				SoftDeleteSettings: &armrecoveryservices.SoftDeleteSettings{
// 					EnhancedSecurityState: to.Ptr(armrecoveryservices.EnhancedSecurityStateEnabled),
// 					SoftDeleteRetentionPeriodInDays: to.Ptr[int32](14),
// 					SoftDeleteState: to.Ptr(armrecoveryservices.SoftDeleteStateEnabled),
// 				},
// 			},
// 		},
// 		SKU: &armrecoveryservices.SKU{
// 			Name: to.Ptr(armrecoveryservices.SKUNameStandard),
// 		},
// 	}
Output:

func (*VaultsClient) NewListByResourceGroupPager

func (client *VaultsClient) NewListByResourceGroupPager(resourceGroupName string, options *VaultsClientListByResourceGroupOptions) *runtime.Pager[VaultsClientListByResourceGroupResponse]

NewListByResourceGroupPager - Retrieve a list of Vaults.

Generated from API version 2024-04-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • options - VaultsClientListByResourceGroupOptions contains the optional parameters for the VaultsClient.NewListByResourceGroupPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/ListResources.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewVaultsClient().NewListByResourceGroupPager("Default-RecoveryServices-ResourceGroup", 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.VaultList = armrecoveryservices.VaultList{
	// 	Value: []*armrecoveryservices.Vault{
	// 		{
	// 			Name: to.Ptr("patchtest"),
	// 			Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
	// 			Etag: to.Ptr("W/\"datetime'2017-11-22T11%3A05%3A19.907Z'\""),
	// 			ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/patchtest"),
	// 			Location: to.Ptr("westus"),
	// 			Tags: map[string]*string{
	// 				"Love": to.Ptr("India"),
	// 			},
	// 			Properties: &armrecoveryservices.VaultProperties{
	// 				ProvisioningState: to.Ptr("Succeeded"),
	// 			},
	// 			SKU: &armrecoveryservices.SKU{
	// 				Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	// 			},
	// 		},
	// 		{
	// 			Name: to.Ptr("swaggerExample"),
	// 			Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
	// 			Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
	// 			ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
	// 			Location: to.Ptr("westus"),
	// 			Tags: map[string]*string{
	// 				"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
	// 			},
	// 			Properties: &armrecoveryservices.VaultProperties{
	// 				ProvisioningState: to.Ptr("Succeeded"),
	// 			},
	// 			SKU: &armrecoveryservices.SKU{
	// 				Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	// 			},
	// 		},
	// 		{
	// 			Name: to.Ptr("today1"),
	// 			Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
	// 			Etag: to.Ptr("W/\"datetime'2017-11-21T10%3A52%3A19.633Z'\""),
	// 			ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/today1"),
	// 			Location: to.Ptr("westus"),
	// 			Tags: map[string]*string{
	// 				"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
	// 			},
	// 			Properties: &armrecoveryservices.VaultProperties{
	// 				ProvisioningState: to.Ptr("Succeeded"),
	// 			},
	// 			SKU: &armrecoveryservices.SKU{
	// 				Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	// 			},
	// 	}},
	// }
}
Output:

func (*VaultsClient) NewListBySubscriptionIDPager

NewListBySubscriptionIDPager - Fetches all the resources of the specified type in the subscription.

Generated from API version 2024-04-01

  • options - VaultsClientListBySubscriptionIDOptions contains the optional parameters for the VaultsClient.NewListBySubscriptionIDPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/33c4457b1d13f83965f4fe3367dca4a6df898100/specification/recoveryservices/resource-manager/Microsoft.RecoveryServices/stable/2024-04-01/examples/ListBySubscriptionIds.json

cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
	log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armrecoveryservices.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
	log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewVaultsClient().NewListBySubscriptionIDPager(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.VaultList = armrecoveryservices.VaultList{
	// 	Value: []*armrecoveryservices.Vault{
	// 		{
	// 			Name: to.Ptr("patchtest"),
	// 			Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
	// 			Etag: to.Ptr("W/\"datetime'2017-11-22T11%3A05%3A19.907Z'\""),
	// 			ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/Default-RecoveryServices-ResourceGroup/providers/Microsoft.RecoveryServices/vaults/patchtest"),
	// 			Location: to.Ptr("westus"),
	// 			Tags: map[string]*string{
	// 				"Love": to.Ptr("India"),
	// 			},
	// 			Properties: &armrecoveryservices.VaultProperties{
	// 				ProvisioningState: to.Ptr("Succeeded"),
	// 			},
	// 			SKU: &armrecoveryservices.SKU{
	// 				Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	// 			},
	// 		},
	// 		{
	// 			Name: to.Ptr("swaggerExample"),
	// 			Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
	// 			Etag: to.Ptr("W/\"datetime'2017-12-15T12%3A36%3A51.68Z'\""),
	// 			ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/swaggerExample"),
	// 			Location: to.Ptr("westus"),
	// 			Tags: map[string]*string{
	// 				"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
	// 			},
	// 			Properties: &armrecoveryservices.VaultProperties{
	// 				ProvisioningState: to.Ptr("Succeeded"),
	// 			},
	// 			SKU: &armrecoveryservices.SKU{
	// 				Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	// 			},
	// 		},
	// 		{
	// 			Name: to.Ptr("today1"),
	// 			Type: to.Ptr("Microsoft.RecoveryServices/vaults"),
	// 			Etag: to.Ptr("W/\"datetime'2017-11-21T10%3A52%3A19.633Z'\""),
	// 			ID: to.Ptr("/subscriptions/77777777-b0c6-47a2-b37c-d8e65a629c18/resourceGroups/HelloWorld/providers/Microsoft.RecoveryServices/vaults/today1"),
	// 			Location: to.Ptr("westus"),
	// 			Tags: map[string]*string{
	// 				"TestUpdatedKey": to.Ptr("TestUpdatedValue"),
	// 			},
	// 			Properties: &armrecoveryservices.VaultProperties{
	// 				ProvisioningState: to.Ptr("Succeeded"),
	// 			},
	// 			SKU: &armrecoveryservices.SKU{
	// 				Name: to.Ptr(armrecoveryservices.SKUNameStandard),
	// 			},
	// 	}},
	// }
}
Output:

type VaultsClientBeginCreateOrUpdateOptions

type VaultsClientBeginCreateOrUpdateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken               string
	XMSAuthorizationAuxiliary *string
}

VaultsClientBeginCreateOrUpdateOptions contains the optional parameters for the VaultsClient.BeginCreateOrUpdate method.

type VaultsClientBeginDeleteOptions

type VaultsClientBeginDeleteOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

VaultsClientBeginDeleteOptions contains the optional parameters for the VaultsClient.BeginDelete method.

type VaultsClientBeginUpdateOptions

type VaultsClientBeginUpdateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken               string
	XMSAuthorizationAuxiliary *string
}

VaultsClientBeginUpdateOptions contains the optional parameters for the VaultsClient.BeginUpdate method.

type VaultsClientCreateOrUpdateResponse

type VaultsClientCreateOrUpdateResponse struct {
	// Resource information, as returned by the resource provider.
	Vault
}

VaultsClientCreateOrUpdateResponse contains the response from method VaultsClient.BeginCreateOrUpdate.

type VaultsClientDeleteResponse

type VaultsClientDeleteResponse struct {
}

VaultsClientDeleteResponse contains the response from method VaultsClient.BeginDelete.

type VaultsClientGetOptions

type VaultsClientGetOptions struct {
}

VaultsClientGetOptions contains the optional parameters for the VaultsClient.Get method.

type VaultsClientGetResponse

type VaultsClientGetResponse struct {
	// Resource information, as returned by the resource provider.
	Vault
}

VaultsClientGetResponse contains the response from method VaultsClient.Get.

type VaultsClientListByResourceGroupOptions

type VaultsClientListByResourceGroupOptions struct {
}

VaultsClientListByResourceGroupOptions contains the optional parameters for the VaultsClient.NewListByResourceGroupPager method.

type VaultsClientListByResourceGroupResponse

type VaultsClientListByResourceGroupResponse struct {
	// The response model for a list of Vaults.
	VaultList
}

VaultsClientListByResourceGroupResponse contains the response from method VaultsClient.NewListByResourceGroupPager.

type VaultsClientListBySubscriptionIDOptions

type VaultsClientListBySubscriptionIDOptions struct {
}

VaultsClientListBySubscriptionIDOptions contains the optional parameters for the VaultsClient.NewListBySubscriptionIDPager method.

type VaultsClientListBySubscriptionIDResponse

type VaultsClientListBySubscriptionIDResponse struct {
	// The response model for a list of Vaults.
	VaultList
}

VaultsClientListBySubscriptionIDResponse contains the response from method VaultsClient.NewListBySubscriptionIDPager.

type VaultsClientUpdateResponse

type VaultsClientUpdateResponse struct {
	// Resource information, as returned by the resource provider.
	Vault
}

VaultsClientUpdateResponse contains the response from method VaultsClient.BeginUpdate.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL