armmanagedapplications

package module
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2023 License: MIT Imports: 14 Imported by: 1

README

Azure Managed Application Module for Go

PkgGoDev

The armmanagedapplications module provides operations for working with Azure Managed Application.

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 Managed Application module:

go get github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications

Authorization

When creating a client, you will need to provide a credential for authenticating with Azure Managed Application. 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 Managed Application 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 := armmanagedapplications.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 := armmanagedapplications.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.NewApplicationsClient()

Provide Feedback

If you encounter bugs or have suggestions, please open an issue and assign the Managed Application 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 ActionType

type ActionType string

ActionType - Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs.

const (
	ActionTypeInternal ActionType = "Internal"
)

func PossibleActionTypeValues

func PossibleActionTypeValues() []ActionType

PossibleActionTypeValues returns the possible values for the ActionType const type.

type Application

type Application struct {
	// REQUIRED; The kind of the managed application. Allowed values are MarketPlace and ServiceCatalog.
	Kind *string

	// REQUIRED; The managed application properties.
	Properties *ApplicationProperties

	// The identity of the resource.
	Identity *Identity

	// Resource location
	Location *string

	// ID of the resource that manages this resource.
	ManagedBy *string

	// The plan information.
	Plan *Plan

	// The SKU of the resource.
	SKU *SKU

	// Resource tags
	Tags map[string]*string

	// READ-ONLY; Resource ID
	ID *string

	// READ-ONLY; Resource name
	Name *string

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

	// READ-ONLY; Resource type
	Type *string
}

Application - Information about managed application.

func (Application) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type Application.

func (*Application) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type Application.

type ApplicationArtifact

type ApplicationArtifact struct {
	// REQUIRED; The managed application artifact name.
	Name *ApplicationArtifactName

	// REQUIRED; The managed application artifact type.
	Type *ApplicationArtifactType

	// REQUIRED; The managed application artifact blob uri.
	URI *string
}

ApplicationArtifact - Managed application artifact.

func (ApplicationArtifact) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationArtifact.

func (*ApplicationArtifact) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationArtifact.

type ApplicationArtifactName

type ApplicationArtifactName string

ApplicationArtifactName - The managed application artifact name.

const (
	ApplicationArtifactNameAuthorizations       ApplicationArtifactName = "Authorizations"
	ApplicationArtifactNameCustomRoleDefinition ApplicationArtifactName = "CustomRoleDefinition"
	ApplicationArtifactNameNotSpecified         ApplicationArtifactName = "NotSpecified"
	ApplicationArtifactNameViewDefinition       ApplicationArtifactName = "ViewDefinition"
)

func PossibleApplicationArtifactNameValues

func PossibleApplicationArtifactNameValues() []ApplicationArtifactName

PossibleApplicationArtifactNameValues returns the possible values for the ApplicationArtifactName const type.

type ApplicationArtifactType

type ApplicationArtifactType string

ApplicationArtifactType - The managed application artifact type.

const (
	ApplicationArtifactTypeNotSpecified ApplicationArtifactType = "NotSpecified"
	ApplicationArtifactTypeTemplate     ApplicationArtifactType = "Template"
	ApplicationArtifactTypeCustom       ApplicationArtifactType = "Custom"
)

func PossibleApplicationArtifactTypeValues

func PossibleApplicationArtifactTypeValues() []ApplicationArtifactType

PossibleApplicationArtifactTypeValues returns the possible values for the ApplicationArtifactType const type.

type ApplicationAuthorization

type ApplicationAuthorization struct {
	// REQUIRED; The provider's principal identifier. This is the identity that the provider will use to call ARM to manage the
	// managed application resources.
	PrincipalID *string

	// REQUIRED; The provider's role definition identifier. This role will define all the permissions that the provider must have
	// on the managed application's container resource group. This role definition cannot have
	// permission to delete the resource group.
	RoleDefinitionID *string
}

ApplicationAuthorization - The managed application provider authorization.

func (ApplicationAuthorization) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationAuthorization.

func (*ApplicationAuthorization) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationAuthorization.

type ApplicationBillingDetailsDefinition

type ApplicationBillingDetailsDefinition struct {
	// The managed application resource usage Id.
	ResourceUsageID *string
}

ApplicationBillingDetailsDefinition - Managed application billing details definition.

func (ApplicationBillingDetailsDefinition) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationBillingDetailsDefinition.

func (*ApplicationBillingDetailsDefinition) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationBillingDetailsDefinition.

type ApplicationClient

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

ApplicationClient contains the methods for the ApplicationClient group. Don't use this type directly, use NewApplicationClient() instead.

func NewApplicationClient

func NewApplicationClient(credential azcore.TokenCredential, options *arm.ClientOptions) (*ApplicationClient, error)

NewApplicationClient creates a new instance of ApplicationClient with the specified values.

  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ApplicationClient) NewListOperationsPager added in v0.4.0

NewListOperationsPager - Lists all of the available Microsoft.Solutions REST API operations.

Generated from API version 2021-07-01

  • options - ApplicationClientListOperationsOptions contains the optional parameters for the ApplicationClient.NewListOperationsPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/listSolutionsOperations.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewApplicationClient().NewListOperationsPager(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.OperationListResult = armmanagedapplications.OperationListResult{
		// 	Value: []*armmanagedapplications.Operation{
		// 		{
		// 			Name: to.Ptr("SolutionsOperation1"),
		// 			Display: &armmanagedapplications.OperationDisplay{
		// 				Description: to.Ptr("Description of the operation"),
		// 				Operation: to.Ptr("Read"),
		// 				Provider: to.Ptr("Microsoft.ResourceProvider"),
		// 				Resource: to.Ptr("Resource1"),
		// 			},
		// 			IsDataAction: to.Ptr(false),
		// 		},
		// 		{
		// 			Name: to.Ptr("SolutionssOperation2"),
		// 			Display: &armmanagedapplications.OperationDisplay{
		// 				Description: to.Ptr("Description of the operation"),
		// 				Operation: to.Ptr("Write"),
		// 				Provider: to.Ptr("Microsoft.ResourceProvider"),
		// 				Resource: to.Ptr("Resource2"),
		// 			},
		// 			IsDataAction: to.Ptr(false),
		// 	}},
		// }
	}
}
Output:

type ApplicationClientDetails

type ApplicationClientDetails struct {
	// The client application Id.
	ApplicationID *string

	// The client Oid.
	Oid *string

	// The client Puid
	Puid *string
}

ApplicationClientDetails - The application client details to track the entity creating/updating the managed app resource.

func (ApplicationClientDetails) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationClientDetails.

func (*ApplicationClientDetails) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationClientDetails.

type ApplicationClientListOperationsOptions

type ApplicationClientListOperationsOptions struct {
}

ApplicationClientListOperationsOptions contains the optional parameters for the ApplicationClient.NewListOperationsPager method.

type ApplicationClientListOperationsResponse

type ApplicationClientListOperationsResponse struct {
	OperationListResult
}

ApplicationClientListOperationsResponse contains the response from method ApplicationClient.NewListOperationsPager.

type ApplicationDefinition

type ApplicationDefinition struct {
	// REQUIRED; The managed application definition properties.
	Properties *ApplicationDefinitionProperties

	// Resource location
	Location *string

	// ID of the resource that manages this resource.
	ManagedBy *string

	// The SKU of the resource.
	SKU *SKU

	// Resource tags
	Tags map[string]*string

	// READ-ONLY; Resource ID
	ID *string

	// READ-ONLY; Resource name
	Name *string

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

	// READ-ONLY; Resource type
	Type *string
}

ApplicationDefinition - Information about managed application definition.

func (ApplicationDefinition) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationDefinition.

func (*ApplicationDefinition) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationDefinition.

type ApplicationDefinitionArtifact

type ApplicationDefinitionArtifact struct {
	// REQUIRED; The managed application definition artifact name.
	Name *ApplicationDefinitionArtifactName

	// REQUIRED; The managed application definition artifact type.
	Type *ApplicationArtifactType

	// REQUIRED; The managed application definition artifact blob uri.
	URI *string
}

ApplicationDefinitionArtifact - Application definition artifact.

func (ApplicationDefinitionArtifact) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationDefinitionArtifact.

func (*ApplicationDefinitionArtifact) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationDefinitionArtifact.

type ApplicationDefinitionArtifactName

type ApplicationDefinitionArtifactName string

ApplicationDefinitionArtifactName - The managed application artifact name.

const (
	ApplicationDefinitionArtifactNameApplicationResourceTemplate ApplicationDefinitionArtifactName = "ApplicationResourceTemplate"
	ApplicationDefinitionArtifactNameCreateUIDefinition          ApplicationDefinitionArtifactName = "CreateUiDefinition"
	ApplicationDefinitionArtifactNameMainTemplateParameters      ApplicationDefinitionArtifactName = "MainTemplateParameters"
	ApplicationDefinitionArtifactNameNotSpecified                ApplicationDefinitionArtifactName = "NotSpecified"
)

func PossibleApplicationDefinitionArtifactNameValues

func PossibleApplicationDefinitionArtifactNameValues() []ApplicationDefinitionArtifactName

PossibleApplicationDefinitionArtifactNameValues returns the possible values for the ApplicationDefinitionArtifactName const type.

type ApplicationDefinitionListResult

type ApplicationDefinitionListResult struct {
	// The URL to use for getting the next set of results.
	NextLink *string

	// The array of managed application definitions.
	Value []*ApplicationDefinition
}

ApplicationDefinitionListResult - List of managed application definitions.

func (ApplicationDefinitionListResult) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationDefinitionListResult.

func (*ApplicationDefinitionListResult) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationDefinitionListResult.

type ApplicationDefinitionPatchable

type ApplicationDefinitionPatchable struct {
	// Application definition tags
	Tags map[string]*string
}

ApplicationDefinitionPatchable - Information about an application definition request.

func (ApplicationDefinitionPatchable) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationDefinitionPatchable.

func (*ApplicationDefinitionPatchable) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationDefinitionPatchable.

type ApplicationDefinitionProperties

type ApplicationDefinitionProperties struct {
	// REQUIRED; The managed application lock level.
	LockLevel *ApplicationLockLevel

	// The collection of managed application artifacts. The portal will use the files specified as artifacts to construct the
	// user experience of creating a managed application from a managed application
	// definition.
	Artifacts []*ApplicationDefinitionArtifact

	// The managed application provider authorizations.
	Authorizations []*ApplicationAuthorization

	// The createUiDefinition json for the backing template with Microsoft.Solutions/applications resource. It can be a JObject
	// or well-formed JSON string.
	CreateUIDefinition any

	// The managed application deployment policy.
	DeploymentPolicy *ApplicationDeploymentPolicy

	// The managed application definition description.
	Description *string

	// The managed application definition display name.
	DisplayName *string

	// A value indicating whether the package is enabled or not.
	IsEnabled *bool

	// The managed application locking policy.
	LockingPolicy *ApplicationPackageLockingPolicyDefinition

	// The inline main template json which has resources to be provisioned. It can be a JObject or well-formed JSON string.
	MainTemplate any

	// The managed application management policy that determines publisher's access to the managed resource group.
	ManagementPolicy *ApplicationManagementPolicy

	// The managed application notification policy.
	NotificationPolicy *ApplicationNotificationPolicy

	// The managed application definition package file Uri. Use this element
	PackageFileURI *string

	// The managed application provider policies.
	Policies []*ApplicationPolicy

	// The storage account id for bring your own storage scenario.
	StorageAccountID *string

	// READ-ONLY; Provisioning state.
	ProvisioningState *ProvisioningState
}

ApplicationDefinitionProperties - The managed application definition properties.

func (ApplicationDefinitionProperties) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationDefinitionProperties.

func (*ApplicationDefinitionProperties) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationDefinitionProperties.

type ApplicationDefinitionsClient

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

ApplicationDefinitionsClient contains the methods for the ApplicationDefinitions group. Don't use this type directly, use NewApplicationDefinitionsClient() instead.

func NewApplicationDefinitionsClient

func NewApplicationDefinitionsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ApplicationDefinitionsClient, error)

NewApplicationDefinitionsClient creates a new instance of ApplicationDefinitionsClient 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 (*ApplicationDefinitionsClient) BeginCreateOrUpdate

BeginCreateOrUpdate - Creates a new managed application definition. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationDefinitionName - The name of the managed application definition.
  • parameters - Parameters supplied to the create or update an managed application definition.
  • options - ApplicationDefinitionsClientBeginCreateOrUpdateOptions contains the optional parameters for the ApplicationDefinitionsClient.BeginCreateOrUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/createOrUpdateApplicationDefinition.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewApplicationDefinitionsClient().BeginCreateOrUpdate(ctx, "rg", "myManagedApplicationDef", armmanagedapplications.ApplicationDefinition{
		Properties: &armmanagedapplications.ApplicationDefinitionProperties{
			Description: to.Ptr("myManagedApplicationDef description"),
			Authorizations: []*armmanagedapplications.ApplicationAuthorization{
				{
					PrincipalID:      to.Ptr("validprincipalguid"),
					RoleDefinitionID: to.Ptr("validroleguid"),
				}},
			DisplayName:    to.Ptr("myManagedApplicationDef"),
			LockLevel:      to.Ptr(armmanagedapplications.ApplicationLockLevelNone),
			PackageFileURI: to.Ptr("https://path/to/packagezipfile"),
		},
	}, 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.ApplicationDefinition = armmanagedapplications.ApplicationDefinition{
	// 	Name: to.Ptr("myManagedApplicationDef"),
	// 	Type: to.Ptr("Microsoft.Solutions/applicationDefinitions"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myManagedApplicationDef"),
	// 	Properties: &armmanagedapplications.ApplicationDefinitionProperties{
	// 		Description: to.Ptr("myManagedApplicationDef description"),
	// 		Artifacts: []*armmanagedapplications.ApplicationDefinitionArtifact{
	// 			{
	// 				Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameCreateUIDefinition),
	// 				Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeCustom),
	// 				URI: to.Ptr("https://path/to/managedApplicationCreateUiDefinition.json"),
	// 			},
	// 			{
	// 				Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameApplicationResourceTemplate),
	// 				Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeTemplate),
	// 				URI: to.Ptr("https://path/to/mainTemplate.json"),
	// 		}},
	// 		Authorizations: []*armmanagedapplications.ApplicationAuthorization{
	// 			{
	// 				PrincipalID: to.Ptr("validprincipalguid"),
	// 				RoleDefinitionID: to.Ptr("validroleguid"),
	// 		}},
	// 		DisplayName: to.Ptr("myManagedApplicationDef"),
	// 		LockLevel: to.Ptr(armmanagedapplications.ApplicationLockLevelNone),
	// 		PackageFileURI: to.Ptr("https://path/to/packagezipfile"),
	// 	},
	// }
}
Output:

func (*ApplicationDefinitionsClient) BeginDelete

BeginDelete - Deletes the managed application definition. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationDefinitionName - The name of the managed application definition.
  • options - ApplicationDefinitionsClientBeginDeleteOptions contains the optional parameters for the ApplicationDefinitionsClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/deleteApplicationDefinition.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewApplicationDefinitionsClient().BeginDelete(ctx, "rg", "myManagedApplicationDef", 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 (*ApplicationDefinitionsClient) Get

func (client *ApplicationDefinitionsClient) Get(ctx context.Context, resourceGroupName string, applicationDefinitionName string, options *ApplicationDefinitionsClientGetOptions) (ApplicationDefinitionsClientGetResponse, error)

Get - Gets the managed application definition. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationDefinitionName - The name of the managed application definition.
  • options - ApplicationDefinitionsClientGetOptions contains the optional parameters for the ApplicationDefinitionsClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/getApplicationDefinition.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewApplicationDefinitionsClient().Get(ctx, "rg", "myManagedApplicationDef", 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.ApplicationDefinition = armmanagedapplications.ApplicationDefinition{
	// 	Name: to.Ptr("myManagedApplicationDef"),
	// 	Type: to.Ptr("Microsoft.Solutions/applicationDefinitions"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myManagedApplicationDef"),
	// 	Properties: &armmanagedapplications.ApplicationDefinitionProperties{
	// 		Description: to.Ptr("myManagedApplicationDef description"),
	// 		Artifacts: []*armmanagedapplications.ApplicationDefinitionArtifact{
	// 			{
	// 				Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameCreateUIDefinition),
	// 				Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeCustom),
	// 				URI: to.Ptr("https://path/to/managedApplicationCreateUiDefinition.json"),
	// 			},
	// 			{
	// 				Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameApplicationResourceTemplate),
	// 				Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeTemplate),
	// 				URI: to.Ptr("https://path/to/mainTemplate.json"),
	// 		}},
	// 		Authorizations: []*armmanagedapplications.ApplicationAuthorization{
	// 			{
	// 				PrincipalID: to.Ptr("validprincipalguid"),
	// 				RoleDefinitionID: to.Ptr("validroleguid"),
	// 		}},
	// 		DisplayName: to.Ptr("myManagedApplicationDef"),
	// 		LockLevel: to.Ptr(armmanagedapplications.ApplicationLockLevelNone),
	// 		PackageFileURI: to.Ptr("https://path/to/packagezipfile"),
	// 		Policies: []*armmanagedapplications.ApplicationPolicy{
	// 		},
	// 	},
	// }
}
Output:

func (*ApplicationDefinitionsClient) NewListByResourceGroupPager added in v0.4.0

NewListByResourceGroupPager - Lists the managed application definitions in a resource group.

Generated from API version 2021-07-01

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

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/listApplicationDefinitionsByResourceGroup.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewApplicationDefinitionsClient().NewListByResourceGroupPager("rg", 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.ApplicationDefinitionListResult = armmanagedapplications.ApplicationDefinitionListResult{
		// 	Value: []*armmanagedapplications.ApplicationDefinition{
		// 		{
		// 			Name: to.Ptr("myManagedApplicationDef"),
		// 			Type: to.Ptr("Microsoft.Solutions/applicationDefinitions"),
		// 			ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myManagedApplicationDef"),
		// 			Properties: &armmanagedapplications.ApplicationDefinitionProperties{
		// 				Description: to.Ptr("myManagedApplicationDef description"),
		// 				Artifacts: []*armmanagedapplications.ApplicationDefinitionArtifact{
		// 					{
		// 						Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameCreateUIDefinition),
		// 						Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeCustom),
		// 						URI: to.Ptr("https://path/to/managedApplicationCreateUiDefinition.json"),
		// 					},
		// 					{
		// 						Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameApplicationResourceTemplate),
		// 						Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeTemplate),
		// 						URI: to.Ptr("https://path/to/mainTemplate.json"),
		// 				}},
		// 				Authorizations: []*armmanagedapplications.ApplicationAuthorization{
		// 					{
		// 						PrincipalID: to.Ptr("validprincipalguid"),
		// 						RoleDefinitionID: to.Ptr("validroleguid"),
		// 				}},
		// 				DisplayName: to.Ptr("myManagedApplicationDef"),
		// 				LockLevel: to.Ptr(armmanagedapplications.ApplicationLockLevelNone),
		// 				PackageFileURI: to.Ptr("https://path/to/packagezipfile"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("myManagedApplicationDef2"),
		// 			Type: to.Ptr("Microsoft.Solutions/applicationDefinitions"),
		// 			ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myManagedApplicationDef2"),
		// 			Properties: &armmanagedapplications.ApplicationDefinitionProperties{
		// 				Description: to.Ptr("myManagedApplicationDef2 description"),
		// 				Artifacts: []*armmanagedapplications.ApplicationDefinitionArtifact{
		// 					{
		// 						Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameCreateUIDefinition),
		// 						Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeCustom),
		// 						URI: to.Ptr("https://path/to/managedApplicationCreateUiDefinition.json"),
		// 					},
		// 					{
		// 						Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameApplicationResourceTemplate),
		// 						Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeTemplate),
		// 						URI: to.Ptr("https://path/to/mainTemplate.json"),
		// 				}},
		// 				Authorizations: []*armmanagedapplications.ApplicationAuthorization{
		// 					{
		// 						PrincipalID: to.Ptr("validprincipalguid"),
		// 						RoleDefinitionID: to.Ptr("validroleguid"),
		// 				}},
		// 				DisplayName: to.Ptr("myManagedApplicationDef2"),
		// 				LockLevel: to.Ptr(armmanagedapplications.ApplicationLockLevelNone),
		// 				PackageFileURI: to.Ptr("https://path/to/packagezipfile"),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*ApplicationDefinitionsClient) NewListBySubscriptionPager added in v0.4.0

NewListBySubscriptionPager - Gets all the application definitions within a subscription.

Generated from API version 2021-07-01

  • options - ApplicationDefinitionsClientListBySubscriptionOptions contains the optional parameters for the ApplicationDefinitionsClient.NewListBySubscriptionPager method.

func (*ApplicationDefinitionsClient) Update

Update - Updates the managed application definition. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationDefinitionName - The name of the managed application definition.
  • parameters - Parameters supplied to the update a managed application definition.
  • options - ApplicationDefinitionsClientUpdateOptions contains the optional parameters for the ApplicationDefinitionsClient.Update method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/updateApplicationDefinition.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewApplicationDefinitionsClient().Update(ctx, "rg", "myManagedApplicationDef", armmanagedapplications.ApplicationDefinitionPatchable{
		Tags: map[string]*string{
			"department": to.Ptr("Finance"),
		},
	}, 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.ApplicationDefinition = armmanagedapplications.ApplicationDefinition{
	// 	Name: to.Ptr("myManagedApplicationDef"),
	// 	Type: to.Ptr("Microsoft.Solutions/applicationDefinitions"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myManagedApplicationDef"),
	// 	Properties: &armmanagedapplications.ApplicationDefinitionProperties{
	// 		Description: to.Ptr("myManagedApplicationDef description"),
	// 		Artifacts: []*armmanagedapplications.ApplicationDefinitionArtifact{
	// 			{
	// 				Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameCreateUIDefinition),
	// 				Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeCustom),
	// 				URI: to.Ptr("https://path/to/managedApplicationCreateUiDefinition.json"),
	// 			},
	// 			{
	// 				Name: to.Ptr(armmanagedapplications.ApplicationDefinitionArtifactNameApplicationResourceTemplate),
	// 				Type: to.Ptr(armmanagedapplications.ApplicationArtifactTypeTemplate),
	// 				URI: to.Ptr("https://path/to/mainTemplate.json"),
	// 		}},
	// 		Authorizations: []*armmanagedapplications.ApplicationAuthorization{
	// 			{
	// 				PrincipalID: to.Ptr("validprincipalguid"),
	// 				RoleDefinitionID: to.Ptr("validroleguid"),
	// 		}},
	// 		DisplayName: to.Ptr("myManagedApplicationDef"),
	// 		LockLevel: to.Ptr(armmanagedapplications.ApplicationLockLevelNone),
	// 		PackageFileURI: to.Ptr("https://path/to/packagezipfile"),
	// 	},
	// }
}
Output:

type ApplicationDefinitionsClientBeginCreateOrUpdateOptions added in v0.2.0

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

ApplicationDefinitionsClientBeginCreateOrUpdateOptions contains the optional parameters for the ApplicationDefinitionsClient.BeginCreateOrUpdate method.

type ApplicationDefinitionsClientBeginDeleteOptions added in v0.2.0

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

ApplicationDefinitionsClientBeginDeleteOptions contains the optional parameters for the ApplicationDefinitionsClient.BeginDelete method.

type ApplicationDefinitionsClientCreateOrUpdateResponse added in v0.2.0

type ApplicationDefinitionsClientCreateOrUpdateResponse struct {
	ApplicationDefinition
}

ApplicationDefinitionsClientCreateOrUpdateResponse contains the response from method ApplicationDefinitionsClient.BeginCreateOrUpdate.

type ApplicationDefinitionsClientDeleteResponse added in v0.2.0

type ApplicationDefinitionsClientDeleteResponse struct {
}

ApplicationDefinitionsClientDeleteResponse contains the response from method ApplicationDefinitionsClient.BeginDelete.

type ApplicationDefinitionsClientGetOptions added in v0.2.0

type ApplicationDefinitionsClientGetOptions struct {
}

ApplicationDefinitionsClientGetOptions contains the optional parameters for the ApplicationDefinitionsClient.Get method.

type ApplicationDefinitionsClientGetResponse added in v0.2.0

type ApplicationDefinitionsClientGetResponse struct {
	ApplicationDefinition
}

ApplicationDefinitionsClientGetResponse contains the response from method ApplicationDefinitionsClient.Get.

type ApplicationDefinitionsClientListByResourceGroupOptions added in v0.2.0

type ApplicationDefinitionsClientListByResourceGroupOptions struct {
}

ApplicationDefinitionsClientListByResourceGroupOptions contains the optional parameters for the ApplicationDefinitionsClient.NewListByResourceGroupPager method.

type ApplicationDefinitionsClientListByResourceGroupResponse added in v0.2.0

type ApplicationDefinitionsClientListByResourceGroupResponse struct {
	ApplicationDefinitionListResult
}

ApplicationDefinitionsClientListByResourceGroupResponse contains the response from method ApplicationDefinitionsClient.NewListByResourceGroupPager.

type ApplicationDefinitionsClientListBySubscriptionOptions added in v0.2.0

type ApplicationDefinitionsClientListBySubscriptionOptions struct {
}

ApplicationDefinitionsClientListBySubscriptionOptions contains the optional parameters for the ApplicationDefinitionsClient.NewListBySubscriptionPager method.

type ApplicationDefinitionsClientListBySubscriptionResponse added in v0.2.0

type ApplicationDefinitionsClientListBySubscriptionResponse struct {
	ApplicationDefinitionListResult
}

ApplicationDefinitionsClientListBySubscriptionResponse contains the response from method ApplicationDefinitionsClient.NewListBySubscriptionPager.

type ApplicationDefinitionsClientUpdateOptions added in v0.2.0

type ApplicationDefinitionsClientUpdateOptions struct {
}

ApplicationDefinitionsClientUpdateOptions contains the optional parameters for the ApplicationDefinitionsClient.Update method.

type ApplicationDefinitionsClientUpdateResponse added in v0.2.0

type ApplicationDefinitionsClientUpdateResponse struct {
	ApplicationDefinition
}

ApplicationDefinitionsClientUpdateResponse contains the response from method ApplicationDefinitionsClient.Update.

type ApplicationDeploymentPolicy

type ApplicationDeploymentPolicy struct {
	// REQUIRED; The managed application deployment mode.
	DeploymentMode *DeploymentMode
}

ApplicationDeploymentPolicy - Managed application deployment policy.

func (ApplicationDeploymentPolicy) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationDeploymentPolicy.

func (*ApplicationDeploymentPolicy) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationDeploymentPolicy.

type ApplicationJitAccessPolicy

type ApplicationJitAccessPolicy struct {
	// REQUIRED; Whether the JIT access is enabled.
	JitAccessEnabled *bool

	// JIT approval mode.
	JitApprovalMode *JitApprovalMode

	// The JIT approvers
	JitApprovers []*JitApproverDefinition

	// The maximum duration JIT access is granted. This is an ISO8601 time period value.
	MaximumJitAccessDuration *string
}

ApplicationJitAccessPolicy - Managed application Jit access policy.

func (ApplicationJitAccessPolicy) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationJitAccessPolicy.

func (*ApplicationJitAccessPolicy) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationJitAccessPolicy.

type ApplicationListResult

type ApplicationListResult struct {
	// The URL to use for getting the next set of results.
	NextLink *string

	// The array of managed applications.
	Value []*Application
}

ApplicationListResult - List of managed applications.

func (ApplicationListResult) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationListResult.

func (*ApplicationListResult) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationListResult.

type ApplicationLockLevel

type ApplicationLockLevel string

ApplicationLockLevel - The managed application lock level.

const (
	ApplicationLockLevelCanNotDelete ApplicationLockLevel = "CanNotDelete"
	ApplicationLockLevelReadOnly     ApplicationLockLevel = "ReadOnly"
	ApplicationLockLevelNone         ApplicationLockLevel = "None"
)

func PossibleApplicationLockLevelValues

func PossibleApplicationLockLevelValues() []ApplicationLockLevel

PossibleApplicationLockLevelValues returns the possible values for the ApplicationLockLevel const type.

type ApplicationManagementMode

type ApplicationManagementMode string

ApplicationManagementMode - The management mode.

const (
	ApplicationManagementModeManaged      ApplicationManagementMode = "Managed"
	ApplicationManagementModeNotSpecified ApplicationManagementMode = "NotSpecified"
	ApplicationManagementModeUnmanaged    ApplicationManagementMode = "Unmanaged"
)

func PossibleApplicationManagementModeValues

func PossibleApplicationManagementModeValues() []ApplicationManagementMode

PossibleApplicationManagementModeValues returns the possible values for the ApplicationManagementMode const type.

type ApplicationManagementPolicy

type ApplicationManagementPolicy struct {
	// The managed application management mode.
	Mode *ApplicationManagementMode
}

ApplicationManagementPolicy - Managed application management policy.

func (ApplicationManagementPolicy) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationManagementPolicy.

func (*ApplicationManagementPolicy) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationManagementPolicy.

type ApplicationNotificationEndpoint

type ApplicationNotificationEndpoint struct {
	// REQUIRED; The managed application notification endpoint uri.
	URI *string
}

ApplicationNotificationEndpoint - Managed application notification endpoint.

func (ApplicationNotificationEndpoint) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationNotificationEndpoint.

func (*ApplicationNotificationEndpoint) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationNotificationEndpoint.

type ApplicationNotificationPolicy

type ApplicationNotificationPolicy struct {
	// REQUIRED; The managed application notification endpoint.
	NotificationEndpoints []*ApplicationNotificationEndpoint
}

ApplicationNotificationPolicy - Managed application notification policy.

func (ApplicationNotificationPolicy) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationNotificationPolicy.

func (*ApplicationNotificationPolicy) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationNotificationPolicy.

type ApplicationPackageContact

type ApplicationPackageContact struct {
	// REQUIRED; The contact email.
	Email *string

	// REQUIRED; The contact phone number.
	Phone *string

	// The contact name.
	ContactName *string
}

ApplicationPackageContact - The application package contact information.

func (ApplicationPackageContact) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationPackageContact.

func (*ApplicationPackageContact) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationPackageContact.

type ApplicationPackageLockingPolicyDefinition

type ApplicationPackageLockingPolicyDefinition struct {
	// The deny assignment excluded actions.
	AllowedActions []*string

	// The deny assignment excluded data actions.
	AllowedDataActions []*string
}

ApplicationPackageLockingPolicyDefinition - Managed application locking policy.

func (ApplicationPackageLockingPolicyDefinition) MarshalJSON

MarshalJSON implements the json.Marshaller interface for type ApplicationPackageLockingPolicyDefinition.

func (*ApplicationPackageLockingPolicyDefinition) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationPackageLockingPolicyDefinition.

type ApplicationPackageSupportUrls

type ApplicationPackageSupportUrls struct {
	// The government cloud support URL.
	GovernmentCloud *string

	// The public azure support URL.
	PublicAzure *string
}

ApplicationPackageSupportUrls - The appliance package support URLs.

func (ApplicationPackageSupportUrls) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationPackageSupportUrls.

func (*ApplicationPackageSupportUrls) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationPackageSupportUrls.

type ApplicationPatchable

type ApplicationPatchable struct {
	// The identity of the resource.
	Identity *Identity

	// The kind of the managed application. Allowed values are MarketPlace and ServiceCatalog.
	Kind *string

	// Resource location
	Location *string

	// ID of the resource that manages this resource.
	ManagedBy *string

	// The plan information.
	Plan *PlanPatchable

	// The managed application properties.
	Properties *ApplicationProperties

	// The SKU of the resource.
	SKU *SKU

	// Resource tags
	Tags map[string]*string

	// READ-ONLY; Resource ID
	ID *string

	// READ-ONLY; Resource name
	Name *string

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

	// READ-ONLY; Resource type
	Type *string
}

ApplicationPatchable - Information about managed application.

func (ApplicationPatchable) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationPatchable.

func (*ApplicationPatchable) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationPatchable.

type ApplicationPolicy

type ApplicationPolicy struct {
	// The policy name
	Name *string

	// The policy parameters.
	Parameters *string

	// The policy definition Id.
	PolicyDefinitionID *string
}

ApplicationPolicy - Managed application policy.

func (ApplicationPolicy) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationPolicy.

func (*ApplicationPolicy) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationPolicy.

type ApplicationProperties

type ApplicationProperties struct {
	// The fully qualified path of managed application definition Id.
	ApplicationDefinitionID *string

	// The managed application Jit access policy.
	JitAccessPolicy *ApplicationJitAccessPolicy

	// The managed resource group Id.
	ManagedResourceGroupID *string

	// Name and value pairs that define the managed application parameters. It can be a JObject or a well formed JSON string.
	Parameters any

	// READ-ONLY; The collection of managed application artifacts.
	Artifacts []*ApplicationArtifact

	// READ-ONLY; The read-only authorizations property that is retrieved from the application package.
	Authorizations []*ApplicationAuthorization

	// READ-ONLY; The managed application billing details.
	BillingDetails *ApplicationBillingDetailsDefinition

	// READ-ONLY; The client entity that created the JIT request.
	CreatedBy *ApplicationClientDetails

	// READ-ONLY; The read-only customer support property that is retrieved from the application package.
	CustomerSupport *ApplicationPackageContact

	// READ-ONLY; The managed application management mode.
	ManagementMode *ApplicationManagementMode

	// READ-ONLY; Name and value pairs that define the managed application outputs.
	Outputs any

	// READ-ONLY; The managed application provisioning state.
	ProvisioningState *ProvisioningState

	// READ-ONLY; The publisher tenant Id.
	PublisherTenantID *string

	// READ-ONLY; The read-only support URLs property that is retrieved from the application package.
	SupportUrls *ApplicationPackageSupportUrls

	// READ-ONLY; The client entity that last updated the JIT request.
	UpdatedBy *ApplicationClientDetails
}

ApplicationProperties - The managed application properties.

func (ApplicationProperties) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ApplicationProperties.

func (*ApplicationProperties) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationProperties.

type ApplicationPropertiesPatchable

type ApplicationPropertiesPatchable struct {
	// The fully qualified path of managed application definition Id.
	ApplicationDefinitionID *string

	// The managed resource group Id.
	ManagedResourceGroupID *string

	// Name and value pairs that define the managed application parameters. It can be a JObject or a well formed JSON string.
	Parameters any

	// READ-ONLY; Name and value pairs that define the managed application outputs.
	Outputs any

	// READ-ONLY; The managed application provisioning state.
	ProvisioningState *ProvisioningState
}

ApplicationPropertiesPatchable - The managed application properties.

func (ApplicationPropertiesPatchable) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ApplicationPropertiesPatchable.

func (*ApplicationPropertiesPatchable) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ApplicationPropertiesPatchable.

type ApplicationsClient

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

ApplicationsClient contains the methods for the Applications group. Don't use this type directly, use NewApplicationsClient() instead.

func NewApplicationsClient

func NewApplicationsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ApplicationsClient, error)

NewApplicationsClient creates a new instance of ApplicationsClient 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 (*ApplicationsClient) BeginCreateOrUpdate

func (client *ApplicationsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, applicationName string, parameters Application, options *ApplicationsClientBeginCreateOrUpdateOptions) (*runtime.Poller[ApplicationsClientCreateOrUpdateResponse], error)

BeginCreateOrUpdate - Creates a new managed application. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationName - The name of the managed application.
  • parameters - Parameters supplied to the create or update a managed application.
  • options - ApplicationsClientBeginCreateOrUpdateOptions contains the optional parameters for the ApplicationsClient.BeginCreateOrUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/createOrUpdateApplication.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewApplicationsClient().BeginCreateOrUpdate(ctx, "rg", "myManagedApplication", armmanagedapplications.Application{
		Kind: to.Ptr("ServiceCatalog"),
		Properties: &armmanagedapplications.ApplicationProperties{
			ApplicationDefinitionID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myAppDef"),
			ManagedResourceGroupID:  to.Ptr("/subscriptions/subid/resourceGroups/myManagedRG"),
		},
	}, 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.Application = armmanagedapplications.Application{
	// 	Name: to.Ptr("myManagedApplication"),
	// 	Type: to.Ptr("Microsoft.Solutions/applications"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applications/myManagedApplication"),
	// 	Kind: to.Ptr("ServiceCatalog"),
	// 	Properties: &armmanagedapplications.ApplicationProperties{
	// 		ApplicationDefinitionID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myAppDef"),
	// 		ManagedResourceGroupID: to.Ptr("/subscriptions/subid/resourceGroups/myManagedRG"),
	// 		ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

func (*ApplicationsClient) BeginDelete

func (client *ApplicationsClient) BeginDelete(ctx context.Context, resourceGroupName string, applicationName string, options *ApplicationsClientBeginDeleteOptions) (*runtime.Poller[ApplicationsClientDeleteResponse], error)

BeginDelete - Deletes the managed application. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationName - The name of the managed application.
  • options - ApplicationsClientBeginDeleteOptions contains the optional parameters for the ApplicationsClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/deleteApplication.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewApplicationsClient().BeginDelete(ctx, "rg", "myManagedApplication", 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 (*ApplicationsClient) BeginRefreshPermissions

func (client *ApplicationsClient) BeginRefreshPermissions(ctx context.Context, resourceGroupName string, applicationName string, options *ApplicationsClientBeginRefreshPermissionsOptions) (*runtime.Poller[ApplicationsClientRefreshPermissionsResponse], error)

BeginRefreshPermissions - Refresh Permissions for application. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationName - The name of the managed application.
  • options - ApplicationsClientBeginRefreshPermissionsOptions contains the optional parameters for the ApplicationsClient.BeginRefreshPermissions method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/refreshApplicationPermissions.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewApplicationsClient().BeginRefreshPermissions(ctx, "rg", "myManagedApplication", 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 (*ApplicationsClient) Get

func (client *ApplicationsClient) Get(ctx context.Context, resourceGroupName string, applicationName string, options *ApplicationsClientGetOptions) (ApplicationsClientGetResponse, error)

Get - Gets the managed application. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationName - The name of the managed application.
  • options - ApplicationsClientGetOptions contains the optional parameters for the ApplicationsClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/getApplication.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewApplicationsClient().Get(ctx, "rg", "myManagedApplication", 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.Application = armmanagedapplications.Application{
	// 	Name: to.Ptr("myManagedApplication"),
	// 	Type: to.Ptr("Microsoft.Solutions/applications"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applications/myManagedApplication"),
	// 	Kind: to.Ptr("ServiceCatalog"),
	// 	Properties: &armmanagedapplications.ApplicationProperties{
	// 		ApplicationDefinitionID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/managedApplicationDefinitions/myAppDef"),
	// 		Artifacts: []*armmanagedapplications.ApplicationArtifact{
	// 		},
	// 		Authorizations: []*armmanagedapplications.ApplicationAuthorization{
	// 			{
	// 				PrincipalID: to.Ptr("validprincipalguid"),
	// 				RoleDefinitionID: to.Ptr("validroleguid"),
	// 		}},
	// 		CreatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 			ApplicationID: to.Ptr("ClientApplicationId"),
	// 			Oid: to.Ptr("ClientOid"),
	// 			Puid: to.Ptr("ClientPuid"),
	// 		},
	// 		ManagedResourceGroupID: to.Ptr("/subscriptions/subid/resourceGroups/myManagedRG"),
	// 		ManagementMode: to.Ptr(armmanagedapplications.ApplicationManagementModeManaged),
	// 		ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
	// 		UpdatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 			ApplicationID: to.Ptr("ClientApplicationId"),
	// 			Oid: to.Ptr("ClientOid"),
	// 			Puid: to.Ptr("ClientPuid"),
	// 		},
	// 	},
	// }
}
Output:

func (*ApplicationsClient) ListAllowedUpgradePlans

func (client *ApplicationsClient) ListAllowedUpgradePlans(ctx context.Context, resourceGroupName string, applicationName string, options *ApplicationsClientListAllowedUpgradePlansOptions) (ApplicationsClientListAllowedUpgradePlansResponse, error)

ListAllowedUpgradePlans - List allowed upgrade plans for application. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationName - The name of the managed application.
  • options - ApplicationsClientListAllowedUpgradePlansOptions contains the optional parameters for the ApplicationsClient.ListAllowedUpgradePlans method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/listAllowedUpgradePlans.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewApplicationsClient().ListAllowedUpgradePlans(ctx, "rg", "myManagedApplication", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ApplicationsClient) NewListByResourceGroupPager added in v0.4.0

NewListByResourceGroupPager - Gets all the applications within a resource group.

Generated from API version 2021-07-01

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

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/listApplicationsByResourceGroup.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewApplicationsClient().NewListByResourceGroupPager("rg", 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.ApplicationListResult = armmanagedapplications.ApplicationListResult{
		// 	Value: []*armmanagedapplications.Application{
		// 		{
		// 			Name: to.Ptr("myManagedApplication"),
		// 			Type: to.Ptr("Microsoft.Solutions/applications"),
		// 			ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applications/myManagedApplication"),
		// 			Kind: to.Ptr("ServiceCatalog"),
		// 			Properties: &armmanagedapplications.ApplicationProperties{
		// 				ApplicationDefinitionID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/managedApplicationDefinitions/myAppDef"),
		// 				ManagedResourceGroupID: to.Ptr("/subscriptions/subid/resourceGroups/myManagedRG"),
		// 				ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("myManagedApplication2"),
		// 			Type: to.Ptr("Microsoft.Solutions/applications"),
		// 			ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applications/myManagedApplication2"),
		// 			Kind: to.Ptr("ServiceCatalog"),
		// 			Properties: &armmanagedapplications.ApplicationProperties{
		// 				ApplicationDefinitionID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/managedApplicationDefinitions/myAppDef2"),
		// 				ManagedResourceGroupID: to.Ptr("/subscriptions/subid/resourceGroups/myManagedRG"),
		// 				ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*ApplicationsClient) NewListBySubscriptionPager added in v0.4.0

NewListBySubscriptionPager - Gets all the applications within a subscription.

Generated from API version 2021-07-01

  • options - ApplicationsClientListBySubscriptionOptions contains the optional parameters for the ApplicationsClient.NewListBySubscriptionPager method.

func (*ApplicationsClient) Update

func (client *ApplicationsClient) Update(ctx context.Context, resourceGroupName string, applicationName string, options *ApplicationsClientUpdateOptions) (ApplicationsClientUpdateResponse, error)

Update - Updates an existing managed application. The only value that can be updated via PATCH currently is the tags. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • applicationName - The name of the managed application.
  • options - ApplicationsClientUpdateOptions contains the optional parameters for the ApplicationsClient.Update method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/updateApplication.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewApplicationsClient().Update(ctx, "rg", "myManagedApplication", &armmanagedapplications.ApplicationsClientUpdateOptions{Parameters: &armmanagedapplications.ApplicationPatchable{
		Kind: to.Ptr("ServiceCatalog"),
		Properties: &armmanagedapplications.ApplicationProperties{
			ApplicationDefinitionID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myAppDef"),
			ManagedResourceGroupID:  to.Ptr("/subscriptions/subid/resourceGroups/myManagedRG"),
		},
	},
	})
	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.Application = armmanagedapplications.Application{
	// 	Name: to.Ptr("myManagedApplication"),
	// 	Type: to.Ptr("Microsoft.Solutions/applications"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applications/myManagedApplication"),
	// 	Kind: to.Ptr("ServiceCatalog"),
	// 	Properties: &armmanagedapplications.ApplicationProperties{
	// 		ApplicationDefinitionID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/applicationDefinitions/myAppDef"),
	// 		ManagedResourceGroupID: to.Ptr("/subscriptions/subid/resourceGroups/myManagedRG"),
	// 		ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
	// 	},
	// }
}
Output:

type ApplicationsClientBeginCreateOrUpdateOptions added in v0.2.0

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

ApplicationsClientBeginCreateOrUpdateOptions contains the optional parameters for the ApplicationsClient.BeginCreateOrUpdate method.

type ApplicationsClientBeginDeleteOptions added in v0.2.0

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

ApplicationsClientBeginDeleteOptions contains the optional parameters for the ApplicationsClient.BeginDelete method.

type ApplicationsClientBeginRefreshPermissionsOptions added in v0.2.0

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

ApplicationsClientBeginRefreshPermissionsOptions contains the optional parameters for the ApplicationsClient.BeginRefreshPermissions method.

type ApplicationsClientCreateOrUpdateResponse added in v0.2.0

type ApplicationsClientCreateOrUpdateResponse struct {
	Application
}

ApplicationsClientCreateOrUpdateResponse contains the response from method ApplicationsClient.BeginCreateOrUpdate.

type ApplicationsClientDeleteResponse added in v0.2.0

type ApplicationsClientDeleteResponse struct {
}

ApplicationsClientDeleteResponse contains the response from method ApplicationsClient.BeginDelete.

type ApplicationsClientGetOptions added in v0.2.0

type ApplicationsClientGetOptions struct {
}

ApplicationsClientGetOptions contains the optional parameters for the ApplicationsClient.Get method.

type ApplicationsClientGetResponse added in v0.2.0

type ApplicationsClientGetResponse struct {
	Application
}

ApplicationsClientGetResponse contains the response from method ApplicationsClient.Get.

type ApplicationsClientListAllowedUpgradePlansOptions added in v0.2.0

type ApplicationsClientListAllowedUpgradePlansOptions struct {
}

ApplicationsClientListAllowedUpgradePlansOptions contains the optional parameters for the ApplicationsClient.ListAllowedUpgradePlans method.

type ApplicationsClientListAllowedUpgradePlansResponse added in v0.2.0

type ApplicationsClientListAllowedUpgradePlansResponse struct {
}

ApplicationsClientListAllowedUpgradePlansResponse contains the response from method ApplicationsClient.ListAllowedUpgradePlans.

type ApplicationsClientListByResourceGroupOptions added in v0.2.0

type ApplicationsClientListByResourceGroupOptions struct {
}

ApplicationsClientListByResourceGroupOptions contains the optional parameters for the ApplicationsClient.NewListByResourceGroupPager method.

type ApplicationsClientListByResourceGroupResponse added in v0.2.0

type ApplicationsClientListByResourceGroupResponse struct {
	ApplicationListResult
}

ApplicationsClientListByResourceGroupResponse contains the response from method ApplicationsClient.NewListByResourceGroupPager.

type ApplicationsClientListBySubscriptionOptions added in v0.2.0

type ApplicationsClientListBySubscriptionOptions struct {
}

ApplicationsClientListBySubscriptionOptions contains the optional parameters for the ApplicationsClient.NewListBySubscriptionPager method.

type ApplicationsClientListBySubscriptionResponse added in v0.2.0

type ApplicationsClientListBySubscriptionResponse struct {
	ApplicationListResult
}

ApplicationsClientListBySubscriptionResponse contains the response from method ApplicationsClient.NewListBySubscriptionPager.

type ApplicationsClientRefreshPermissionsResponse added in v0.2.0

type ApplicationsClientRefreshPermissionsResponse struct {
}

ApplicationsClientRefreshPermissionsResponse contains the response from method ApplicationsClient.BeginRefreshPermissions.

type ApplicationsClientUpdateOptions added in v0.2.0

type ApplicationsClientUpdateOptions struct {
	// Parameters supplied to update an existing managed application.
	Parameters *ApplicationPatchable
}

ApplicationsClientUpdateOptions contains the optional parameters for the ApplicationsClient.Update method.

type ApplicationsClientUpdateResponse added in v0.2.0

type ApplicationsClientUpdateResponse struct {
	Application
}

ApplicationsClientUpdateResponse contains the response from method ApplicationsClient.Update.

type ClientFactory added in v1.1.0

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 added in v1.1.0

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) NewApplicationClient added in v1.1.0

func (c *ClientFactory) NewApplicationClient() *ApplicationClient

func (*ClientFactory) NewApplicationDefinitionsClient added in v1.1.0

func (c *ClientFactory) NewApplicationDefinitionsClient() *ApplicationDefinitionsClient

func (*ClientFactory) NewApplicationsClient added in v1.1.0

func (c *ClientFactory) NewApplicationsClient() *ApplicationsClient

func (*ClientFactory) NewJitRequestsClient added in v1.1.0

func (c *ClientFactory) NewJitRequestsClient() *JitRequestsClient

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 DeploymentMode

type DeploymentMode string

DeploymentMode - The deployment mode.

const (
	DeploymentModeComplete     DeploymentMode = "Complete"
	DeploymentModeIncremental  DeploymentMode = "Incremental"
	DeploymentModeNotSpecified DeploymentMode = "NotSpecified"
)

func PossibleDeploymentModeValues

func PossibleDeploymentModeValues() []DeploymentMode

PossibleDeploymentModeValues returns the possible values for the DeploymentMode const type.

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 added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ErrorAdditionalInfo.

func (*ErrorAdditionalInfo) UnmarshalJSON added in v1.1.0

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 added in v1.1.0

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 added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ErrorResponse.

func (*ErrorResponse) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ErrorResponse.

type GenericResource

type GenericResource struct {
	// Resource location
	Location *string

	// ID of the resource that manages this resource.
	ManagedBy *string

	// The SKU of the resource.
	SKU *SKU

	// Resource tags
	Tags map[string]*string

	// READ-ONLY; Resource ID
	ID *string

	// READ-ONLY; Resource name
	Name *string

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

	// READ-ONLY; Resource type
	Type *string
}

GenericResource - Resource information.

func (GenericResource) MarshalJSON

func (g GenericResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type GenericResource.

func (*GenericResource) UnmarshalJSON added in v1.1.0

func (g *GenericResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type GenericResource.

type Identity added in v0.2.0

type Identity struct {
	// The identity type.
	Type *ResourceIdentityType

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

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

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

Identity for the resource.

func (Identity) MarshalJSON added in v0.2.0

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

MarshalJSON implements the json.Marshaller interface for type Identity.

func (*Identity) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type Identity.

type JitApprovalMode

type JitApprovalMode string

JitApprovalMode - The Jit approval mode.

const (
	JitApprovalModeAutoApprove   JitApprovalMode = "AutoApprove"
	JitApprovalModeManualApprove JitApprovalMode = "ManualApprove"
	JitApprovalModeNotSpecified  JitApprovalMode = "NotSpecified"
)

func PossibleJitApprovalModeValues

func PossibleJitApprovalModeValues() []JitApprovalMode

PossibleJitApprovalModeValues returns the possible values for the JitApprovalMode const type.

type JitApproverDefinition

type JitApproverDefinition struct {
	// REQUIRED; The approver service principal Id.
	ID *string

	// The approver display name.
	DisplayName *string

	// The approver type.
	Type *JitApproverType
}

JitApproverDefinition - JIT approver definition.

func (JitApproverDefinition) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type JitApproverDefinition.

func (*JitApproverDefinition) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type JitApproverDefinition.

type JitApproverType

type JitApproverType string

JitApproverType - The approver type.

const (
	JitApproverTypeGroup JitApproverType = "group"
	JitApproverTypeUser  JitApproverType = "user"
)

func PossibleJitApproverTypeValues

func PossibleJitApproverTypeValues() []JitApproverType

PossibleJitApproverTypeValues returns the possible values for the JitApproverType const type.

type JitAuthorizationPolicies

type JitAuthorizationPolicies struct {
	// REQUIRED; The the principal id that will be granted JIT access.
	PrincipalID *string

	// REQUIRED; The role definition id that will be granted to the Principal.
	RoleDefinitionID *string
}

JitAuthorizationPolicies - The JIT authorization policies.

func (JitAuthorizationPolicies) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type JitAuthorizationPolicies.

func (*JitAuthorizationPolicies) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type JitAuthorizationPolicies.

type JitRequestDefinition

type JitRequestDefinition struct {
	// Resource location
	Location *string

	// The JIT request properties.
	Properties *JitRequestProperties

	// Resource tags
	Tags map[string]*string

	// READ-ONLY; Resource ID
	ID *string

	// READ-ONLY; Resource name
	Name *string

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

	// READ-ONLY; Resource type
	Type *string
}

JitRequestDefinition - Information about JIT request definition.

func (JitRequestDefinition) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type JitRequestDefinition.

func (*JitRequestDefinition) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type JitRequestDefinition.

type JitRequestDefinitionListResult

type JitRequestDefinitionListResult struct {
	// The URL to use for getting the next set of results.
	NextLink *string

	// The array of Jit request definition.
	Value []*JitRequestDefinition
}

JitRequestDefinitionListResult - List of JIT requests.

func (JitRequestDefinitionListResult) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type JitRequestDefinitionListResult.

func (*JitRequestDefinitionListResult) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type JitRequestDefinitionListResult.

type JitRequestPatchable

type JitRequestPatchable struct {
	// Jit request tags
	Tags map[string]*string
}

JitRequestPatchable - Information about JIT request.

func (JitRequestPatchable) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type JitRequestPatchable.

func (*JitRequestPatchable) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type JitRequestPatchable.

type JitRequestProperties

type JitRequestProperties struct {
	// REQUIRED; The parent application id.
	ApplicationResourceID *string

	// REQUIRED; The JIT authorization policies.
	JitAuthorizationPolicies []*JitAuthorizationPolicies

	// REQUIRED; The JIT request properties.
	JitSchedulingPolicy *JitSchedulingPolicy

	// READ-ONLY; The client entity that created the JIT request.
	CreatedBy *ApplicationClientDetails

	// READ-ONLY; The JIT request state.
	JitRequestState *JitRequestState

	// READ-ONLY; The JIT request provisioning state.
	ProvisioningState *ProvisioningState

	// READ-ONLY; The publisher tenant id.
	PublisherTenantID *string

	// READ-ONLY; The client entity that last updated the JIT request.
	UpdatedBy *ApplicationClientDetails
}

JitRequestProperties - Information about JIT request properties

func (JitRequestProperties) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type JitRequestProperties.

func (*JitRequestProperties) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type JitRequestProperties.

type JitRequestState

type JitRequestState string

JitRequestState - The JIT request state.

const (
	JitRequestStateApproved     JitRequestState = "Approved"
	JitRequestStateCanceled     JitRequestState = "Canceled"
	JitRequestStateDenied       JitRequestState = "Denied"
	JitRequestStateExpired      JitRequestState = "Expired"
	JitRequestStateFailed       JitRequestState = "Failed"
	JitRequestStateNotSpecified JitRequestState = "NotSpecified"
	JitRequestStatePending      JitRequestState = "Pending"
	JitRequestStateTimeout      JitRequestState = "Timeout"
)

func PossibleJitRequestStateValues

func PossibleJitRequestStateValues() []JitRequestState

PossibleJitRequestStateValues returns the possible values for the JitRequestState const type.

type JitRequestsClient

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

JitRequestsClient contains the methods for the JitRequests group. Don't use this type directly, use NewJitRequestsClient() instead.

func NewJitRequestsClient

func NewJitRequestsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*JitRequestsClient, error)

NewJitRequestsClient creates a new instance of JitRequestsClient 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 (*JitRequestsClient) BeginCreateOrUpdate

func (client *JitRequestsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, jitRequestName string, parameters JitRequestDefinition, options *JitRequestsClientBeginCreateOrUpdateOptions) (*runtime.Poller[JitRequestsClientCreateOrUpdateResponse], error)

BeginCreateOrUpdate - Creates or updates the JIT request. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • jitRequestName - The name of the JIT request.
  • parameters - Parameters supplied to the update JIT request.
  • options - JitRequestsClientBeginCreateOrUpdateOptions contains the optional parameters for the JitRequestsClient.BeginCreateOrUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/createOrUpdateJitRequest.json

package main

import (
	"context"
	"log"

	"time"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewJitRequestsClient().BeginCreateOrUpdate(ctx, "rg", "myJitRequest", armmanagedapplications.JitRequestDefinition{
		Properties: &armmanagedapplications.JitRequestProperties{
			ApplicationResourceID: to.Ptr("/subscriptions/00c76877-e316-48a7-af60-4a09fec9d43f/resourceGroups/52F30DB2/providers/Microsoft.Solutions/applications/7E193158"),
			JitAuthorizationPolicies: []*armmanagedapplications.JitAuthorizationPolicies{
				{
					PrincipalID:      to.Ptr("1db8e132e2934dbcb8e1178a61319491"),
					RoleDefinitionID: to.Ptr("ecd05a23-931a-4c38-a52b-ac7c4c583334"),
				}},
			JitSchedulingPolicy: &armmanagedapplications.JitSchedulingPolicy{
				Type:      to.Ptr(armmanagedapplications.JitSchedulingTypeOnce),
				Duration:  to.Ptr("PT8H"),
				StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-04-22T05:48:30.6661804Z"); return t }()),
			},
		},
	}, 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.JitRequestDefinition = armmanagedapplications.JitRequestDefinition{
	// 	Name: to.Ptr("myJitRequest"),
	// 	Type: to.Ptr("Microsoft.Solutions/jitRequests"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/jitRequests/myJitRequest"),
	// 	Properties: &armmanagedapplications.JitRequestProperties{
	// 		ApplicationResourceID: to.Ptr("/subscriptions/00c76877-e316-48a7-af60-4a09fec9d43f/resourceGroups/52F30DB2/providers/Microsoft.Solutions/applications/7E193158"),
	// 		CreatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 			ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 			Oid: to.Ptr(""),
	// 		},
	// 		JitAuthorizationPolicies: []*armmanagedapplications.JitAuthorizationPolicies{
	// 			{
	// 				PrincipalID: to.Ptr("1db8e132e2934dbcb8e1178a61319491"),
	// 				RoleDefinitionID: to.Ptr("ecd05a23-931a-4c38-a52b-ac7c4c583334"),
	// 		}},
	// 		JitRequestState: to.Ptr(armmanagedapplications.JitRequestStatePending),
	// 		JitSchedulingPolicy: &armmanagedapplications.JitSchedulingPolicy{
	// 			Type: to.Ptr(armmanagedapplications.JitSchedulingTypeOnce),
	// 			Duration: to.Ptr("PT8H"),
	// 			StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-04-22T05:48:30.6661804Z"); return t}()),
	// 		},
	// 		ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
	// 		UpdatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 			ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 			Oid: to.Ptr(""),
	// 		},
	// 	},
	// }
}
Output:

func (*JitRequestsClient) Delete

func (client *JitRequestsClient) Delete(ctx context.Context, resourceGroupName string, jitRequestName string, options *JitRequestsClientDeleteOptions) (JitRequestsClientDeleteResponse, error)

Delete - Deletes the JIT request. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • jitRequestName - The name of the JIT request.
  • options - JitRequestsClientDeleteOptions contains the optional parameters for the JitRequestsClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/deleteJitRequest.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewJitRequestsClient().Delete(ctx, "rg", "myJitRequest", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*JitRequestsClient) Get

func (client *JitRequestsClient) Get(ctx context.Context, resourceGroupName string, jitRequestName string, options *JitRequestsClientGetOptions) (JitRequestsClientGetResponse, error)

Get - Gets the JIT request. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • jitRequestName - The name of the JIT request.
  • options - JitRequestsClientGetOptions contains the optional parameters for the JitRequestsClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/getJitRequest.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewJitRequestsClient().Get(ctx, "rg", "myJitRequest", 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.JitRequestDefinition = armmanagedapplications.JitRequestDefinition{
	// 	Name: to.Ptr("myJitRequest"),
	// 	Type: to.Ptr("Microsoft.Solutions/jitRequests"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/jitRequests/myJitRequest"),
	// 	Properties: &armmanagedapplications.JitRequestProperties{
	// 		ApplicationResourceID: to.Ptr("/subscriptions/00c76877-e316-48a7-af60-4a09fec9d43f/resourceGroups/52F30DB2/providers/Microsoft.Solutions/applications/7E193158"),
	// 		CreatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 			ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 			Oid: to.Ptr(""),
	// 		},
	// 		JitAuthorizationPolicies: []*armmanagedapplications.JitAuthorizationPolicies{
	// 			{
	// 				PrincipalID: to.Ptr("1db8e132e2934dbcb8e1178a61319491"),
	// 				RoleDefinitionID: to.Ptr("ecd05a23-931a-4c38-a52b-ac7c4c583334"),
	// 		}},
	// 		JitRequestState: to.Ptr(armmanagedapplications.JitRequestStatePending),
	// 		JitSchedulingPolicy: &armmanagedapplications.JitSchedulingPolicy{
	// 			Type: to.Ptr(armmanagedapplications.JitSchedulingTypeOnce),
	// 			Duration: to.Ptr("PT8H"),
	// 			StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-04-22T05:48:30.6661804Z"); return t}()),
	// 		},
	// 		ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
	// 		UpdatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 			ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 			Oid: to.Ptr(""),
	// 		},
	// 	},
	// }
}
Output:

func (*JitRequestsClient) ListByResourceGroup

ListByResourceGroup - Retrieves all JIT requests within the resource group. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • options - JitRequestsClientListByResourceGroupOptions contains the optional parameters for the JitRequestsClient.ListByResourceGroup method.

func (*JitRequestsClient) ListBySubscription

ListBySubscription - Retrieves all JIT requests within the subscription. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • options - JitRequestsClientListBySubscriptionOptions contains the optional parameters for the JitRequestsClient.ListBySubscription method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/listJitRequestsByResourceGroup.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewJitRequestsClient().ListBySubscription(ctx, 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.JitRequestDefinitionListResult = armmanagedapplications.JitRequestDefinitionListResult{
	// 	Value: []*armmanagedapplications.JitRequestDefinition{
	// 		{
	// 			Name: to.Ptr("myJitRequest"),
	// 			Type: to.Ptr("Microsoft.Solutions/jitRequests"),
	// 			ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/jitRequests/myJitRequest"),
	// 			Properties: &armmanagedapplications.JitRequestProperties{
	// 				ApplicationResourceID: to.Ptr("/subscriptions/00c76877-e316-48a7-af60-4a09fec9d43f/resourceGroups/52F30DB2/providers/Microsoft.Solutions/applications/7E193158"),
	// 				CreatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 					ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 					Oid: to.Ptr(""),
	// 				},
	// 				JitAuthorizationPolicies: []*armmanagedapplications.JitAuthorizationPolicies{
	// 					{
	// 						PrincipalID: to.Ptr("1db8e132e2934dbcb8e1178a61319491"),
	// 						RoleDefinitionID: to.Ptr("ecd05a23-931a-4c38-a52b-ac7c4c583334"),
	// 				}},
	// 				JitRequestState: to.Ptr(armmanagedapplications.JitRequestStatePending),
	// 				JitSchedulingPolicy: &armmanagedapplications.JitSchedulingPolicy{
	// 					Type: to.Ptr(armmanagedapplications.JitSchedulingTypeOnce),
	// 					Duration: to.Ptr("PT8H"),
	// 					StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-04-22T05:48:30.6661804Z"); return t}()),
	// 				},
	// 				ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
	// 				UpdatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 					ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 					Oid: to.Ptr(""),
	// 				},
	// 			},
	// 		},
	// 		{
	// 			Name: to.Ptr("myJitRequest2"),
	// 			Type: to.Ptr("Microsoft.Solutions/jitRequests"),
	// 			ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/jitRequests/myJitRequest2"),
	// 			Properties: &armmanagedapplications.JitRequestProperties{
	// 				ApplicationResourceID: to.Ptr("/subscriptions/00c76877-e316-48a7-af60-4a09fec9d43f/resourceGroups/52F30DB2/providers/Microsoft.Solutions/applications/7E193158"),
	// 				CreatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 					ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 					Oid: to.Ptr(""),
	// 				},
	// 				JitAuthorizationPolicies: []*armmanagedapplications.JitAuthorizationPolicies{
	// 					{
	// 						PrincipalID: to.Ptr("1db8e132e2934dbcb8e1178a61319491"),
	// 						RoleDefinitionID: to.Ptr("ecd05a23-931a-4c38-a52b-ac7c4c583334"),
	// 				}},
	// 				JitRequestState: to.Ptr(armmanagedapplications.JitRequestStatePending),
	// 				JitSchedulingPolicy: &armmanagedapplications.JitSchedulingPolicy{
	// 					Type: to.Ptr(armmanagedapplications.JitSchedulingTypeOnce),
	// 					Duration: to.Ptr("PT8H"),
	// 					StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-04-22T05:48:30.6661804Z"); return t}()),
	// 				},
	// 				ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
	// 				UpdatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 					ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 					Oid: to.Ptr(""),
	// 				},
	// 			},
	// 	}},
	// }
}
Output:

func (*JitRequestsClient) Update

func (client *JitRequestsClient) Update(ctx context.Context, resourceGroupName string, jitRequestName string, parameters JitRequestPatchable, options *JitRequestsClientUpdateOptions) (JitRequestsClientUpdateResponse, error)

Update - Updates the JIT request. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-07-01

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • jitRequestName - The name of the JIT request.
  • parameters - Parameters supplied to the update JIT request.
  • options - JitRequestsClientUpdateOptions contains the optional parameters for the JitRequestsClient.Update method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/solutions/resource-manager/Microsoft.Solutions/stable/2021-07-01/examples/updateJitRequest.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/solutions/armmanagedapplications"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armmanagedapplications.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewJitRequestsClient().Update(ctx, "rg", "myJitRequest", armmanagedapplications.JitRequestPatchable{
		Tags: map[string]*string{
			"department": to.Ptr("Finance"),
		},
	}, 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.JitRequestDefinition = armmanagedapplications.JitRequestDefinition{
	// 	Name: to.Ptr("myJitRequest"),
	// 	Type: to.Ptr("Microsoft.Solutions/jitRequests"),
	// 	ID: to.Ptr("/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Solutions/jitRequests/myJitRequest"),
	// 	Properties: &armmanagedapplications.JitRequestProperties{
	// 		ApplicationResourceID: to.Ptr("/subscriptions/00c76877-e316-48a7-af60-4a09fec9d43f/resourceGroups/52F30DB2/providers/Microsoft.Solutions/applications/7E193158"),
	// 		CreatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 			ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 			Oid: to.Ptr(""),
	// 		},
	// 		JitAuthorizationPolicies: []*armmanagedapplications.JitAuthorizationPolicies{
	// 			{
	// 				PrincipalID: to.Ptr("1db8e132e2934dbcb8e1178a61319491"),
	// 				RoleDefinitionID: to.Ptr("ecd05a23-931a-4c38-a52b-ac7c4c583334"),
	// 		}},
	// 		JitRequestState: to.Ptr(armmanagedapplications.JitRequestStatePending),
	// 		JitSchedulingPolicy: &armmanagedapplications.JitSchedulingPolicy{
	// 			Type: to.Ptr(armmanagedapplications.JitSchedulingTypeOnce),
	// 			Duration: to.Ptr("PT8H"),
	// 			StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-04-22T05:48:30.6661804Z"); return t}()),
	// 		},
	// 		ProvisioningState: to.Ptr(armmanagedapplications.ProvisioningStateSucceeded),
	// 		UpdatedBy: &armmanagedapplications.ApplicationClientDetails{
	// 			ApplicationID: to.Ptr("33a83f1f-c363-4ae7-9e0a-a0c08466354d"),
	// 			Oid: to.Ptr(""),
	// 		},
	// 	},
	// }
}
Output:

type JitRequestsClientBeginCreateOrUpdateOptions added in v0.2.0

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

JitRequestsClientBeginCreateOrUpdateOptions contains the optional parameters for the JitRequestsClient.BeginCreateOrUpdate method.

type JitRequestsClientCreateOrUpdateResponse added in v0.2.0

type JitRequestsClientCreateOrUpdateResponse struct {
	JitRequestDefinition
}

JitRequestsClientCreateOrUpdateResponse contains the response from method JitRequestsClient.BeginCreateOrUpdate.

type JitRequestsClientDeleteOptions added in v0.2.0

type JitRequestsClientDeleteOptions struct {
}

JitRequestsClientDeleteOptions contains the optional parameters for the JitRequestsClient.Delete method.

type JitRequestsClientDeleteResponse added in v0.2.0

type JitRequestsClientDeleteResponse struct {
}

JitRequestsClientDeleteResponse contains the response from method JitRequestsClient.Delete.

type JitRequestsClientGetOptions added in v0.2.0

type JitRequestsClientGetOptions struct {
}

JitRequestsClientGetOptions contains the optional parameters for the JitRequestsClient.Get method.

type JitRequestsClientGetResponse added in v0.2.0

type JitRequestsClientGetResponse struct {
	JitRequestDefinition
}

JitRequestsClientGetResponse contains the response from method JitRequestsClient.Get.

type JitRequestsClientListByResourceGroupOptions added in v0.2.0

type JitRequestsClientListByResourceGroupOptions struct {
}

JitRequestsClientListByResourceGroupOptions contains the optional parameters for the JitRequestsClient.ListByResourceGroup method.

type JitRequestsClientListByResourceGroupResponse added in v0.2.0

type JitRequestsClientListByResourceGroupResponse struct {
	JitRequestDefinitionListResult
}

JitRequestsClientListByResourceGroupResponse contains the response from method JitRequestsClient.ListByResourceGroup.

type JitRequestsClientListBySubscriptionOptions added in v0.2.0

type JitRequestsClientListBySubscriptionOptions struct {
}

JitRequestsClientListBySubscriptionOptions contains the optional parameters for the JitRequestsClient.ListBySubscription method.

type JitRequestsClientListBySubscriptionResponse added in v0.2.0

type JitRequestsClientListBySubscriptionResponse struct {
	JitRequestDefinitionListResult
}

JitRequestsClientListBySubscriptionResponse contains the response from method JitRequestsClient.ListBySubscription.

type JitRequestsClientUpdateOptions added in v0.2.0

type JitRequestsClientUpdateOptions struct {
}

JitRequestsClientUpdateOptions contains the optional parameters for the JitRequestsClient.Update method.

type JitRequestsClientUpdateResponse added in v0.2.0

type JitRequestsClientUpdateResponse struct {
	JitRequestDefinition
}

JitRequestsClientUpdateResponse contains the response from method JitRequestsClient.Update.

type JitSchedulingPolicy

type JitSchedulingPolicy struct {
	// REQUIRED; The required duration of the JIT request.
	Duration *string

	// REQUIRED; The start time of the request.
	StartTime *time.Time

	// REQUIRED; The type of JIT schedule.
	Type *JitSchedulingType
}

JitSchedulingPolicy - The JIT scheduling policies.

func (JitSchedulingPolicy) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type JitSchedulingPolicy.

func (*JitSchedulingPolicy) UnmarshalJSON

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

UnmarshalJSON implements the json.Unmarshaller interface for type JitSchedulingPolicy.

type JitSchedulingType

type JitSchedulingType string

JitSchedulingType - The JIT request scheduling type.

const (
	JitSchedulingTypeNotSpecified JitSchedulingType = "NotSpecified"
	JitSchedulingTypeOnce         JitSchedulingType = "Once"
	JitSchedulingTypeRecurring    JitSchedulingType = "Recurring"
)

func PossibleJitSchedulingTypeValues

func PossibleJitSchedulingTypeValues() []JitSchedulingType

PossibleJitSchedulingTypeValues returns the possible values for the JitSchedulingType const type.

type Operation

type Operation struct {
	// Localized display information for this particular operation.
	Display *OperationDisplay

	// READ-ONLY; Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs.
	ActionType *ActionType

	// READ-ONLY; Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for ARM/control-plane
	// operations.
	IsDataAction *bool

	// READ-ONLY; The name of the operation, as per Resource-Based Access Control (RBAC). Examples: "Microsoft.Compute/virtualMachines/write",
	// "Microsoft.Compute/virtualMachines/capture/action"
	Name *string

	// READ-ONLY; The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default
	// value is "user,system"
	Origin *Origin
}

Operation - Details of a REST API operation, returned from the Resource Provider Operations API

func (Operation) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type Operation.

func (*Operation) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type Operation.

type OperationDisplay

type OperationDisplay struct {
	// READ-ONLY; The short, localized friendly description of the operation; suitable for tool tips and detailed views.
	Description *string

	// READ-ONLY; The concise, localized friendly name for the operation; suitable for dropdowns. E.g. "Create or Update Virtual
	// Machine", "Restart Virtual Machine".
	Operation *string

	// READ-ONLY; The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft
	// Compute".
	Provider *string

	// READ-ONLY; The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job
	// Schedule Collections".
	Resource *string
}

OperationDisplay - Localized display information for this particular operation.

func (OperationDisplay) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type OperationDisplay.

func (*OperationDisplay) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type OperationDisplay.

type OperationListResult

type OperationListResult struct {
	// READ-ONLY; URL to get the next set of operation list results (if there are any).
	NextLink *string

	// READ-ONLY; List of operations supported by the resource provider
	Value []*Operation
}

OperationListResult - A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results.

func (OperationListResult) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type OperationListResult.

func (*OperationListResult) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type OperationListResult.

type Origin

type Origin string

Origin - The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default value is "user,system"

const (
	OriginSystem     Origin = "system"
	OriginUser       Origin = "user"
	OriginUserSystem Origin = "user,system"
)

func PossibleOriginValues

func PossibleOriginValues() []Origin

PossibleOriginValues returns the possible values for the Origin const type.

type Plan

type Plan struct {
	// REQUIRED; The plan name.
	Name *string

	// REQUIRED; The product code.
	Product *string

	// REQUIRED; The publisher ID.
	Publisher *string

	// REQUIRED; The plan's version.
	Version *string

	// The promotion code.
	PromotionCode *string
}

Plan for the managed application.

func (Plan) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type Plan.

func (*Plan) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type Plan.

type PlanPatchable

type PlanPatchable struct {
	// The plan name.
	Name *string

	// The product code.
	Product *string

	// The promotion code.
	PromotionCode *string

	// The publisher ID.
	Publisher *string

	// The plan's version.
	Version *string
}

PlanPatchable - Plan for the managed application.

func (PlanPatchable) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type PlanPatchable.

func (*PlanPatchable) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type PlanPatchable.

type ProvisioningState

type ProvisioningState string

ProvisioningState - Provisioning status of the managed application.

const (
	ProvisioningStateAccepted     ProvisioningState = "Accepted"
	ProvisioningStateCanceled     ProvisioningState = "Canceled"
	ProvisioningStateDeleted      ProvisioningState = "Deleted"
	ProvisioningStateDeleting     ProvisioningState = "Deleting"
	ProvisioningStateFailed       ProvisioningState = "Failed"
	ProvisioningStateNotSpecified ProvisioningState = "NotSpecified"
	ProvisioningStateRunning      ProvisioningState = "Running"
	ProvisioningStateSucceeded    ProvisioningState = "Succeeded"
	ProvisioningStateUpdating     ProvisioningState = "Updating"
)

func PossibleProvisioningStateValues

func PossibleProvisioningStateValues() []ProvisioningState

PossibleProvisioningStateValues returns the possible values for the ProvisioningState const type.

type Resource

type Resource struct {
	// Resource location
	Location *string

	// Resource tags
	Tags map[string]*string

	// READ-ONLY; Resource ID
	ID *string

	// READ-ONLY; Resource name
	Name *string

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

	// READ-ONLY; Resource type
	Type *string
}

Resource information.

func (Resource) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type Resource.

func (*Resource) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type Resource.

type ResourceIdentityType added in v0.2.0

type ResourceIdentityType string

ResourceIdentityType - The identity type.

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

func PossibleResourceIdentityTypeValues added in v0.2.0

func PossibleResourceIdentityTypeValues() []ResourceIdentityType

PossibleResourceIdentityTypeValues returns the possible values for the ResourceIdentityType const type.

type SKU

type SKU struct {
	// REQUIRED; The SKU name.
	Name *string

	// The SKU capacity.
	Capacity *int32

	// The SKU family.
	Family *string

	// The SKU model.
	Model *string

	// The SKU size.
	Size *string

	// The SKU tier.
	Tier *string
}

SKU for the resource.

func (SKU) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type SKU.

func (*SKU) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type SKU.

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 timestamp of resource last modification (UTC)
	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 UserAssignedResourceIdentity added in v0.2.0

type UserAssignedResourceIdentity struct {
	// READ-ONLY; The principal id of user assigned identity.
	PrincipalID *string

	// READ-ONLY; The tenant id of user assigned identity.
	TenantID *string
}

UserAssignedResourceIdentity - Represents the user assigned identity that is contained within the UserAssignedIdentities dictionary on ResourceIdentity

func (UserAssignedResourceIdentity) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type UserAssignedResourceIdentity.

func (*UserAssignedResourceIdentity) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type UserAssignedResourceIdentity.

Jump to

Keyboard shortcuts

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