armdelegatednetwork

package module
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2023 License: MIT Imports: 13 Imported by: 1

README

Azure Delegated Network Module for Go

PkgGoDev

The armdelegatednetwork module provides operations for working with Azure Delegated Network.

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 Delegated Network module:

go get github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork

Authorization

When creating a client, you will need to provide a credential for authenticating with Azure Delegated Network. 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 Delegated Network 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 := armdelegatednetwork.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 := armdelegatednetwork.NewClientFactory(<subscription ID>, cred, &options)

Clients

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

client := clientFactory.NewClient()

Fakes

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

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

Provide Feedback

If you encounter bugs or have suggestions, please open an issue and assign the Delegated Network 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 Client

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

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

func NewClient

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

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

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

func (*Client) NewListByResourceGroupPager

func (client *Client) NewListByResourceGroupPager(resourceGroupName string, options *ClientListByResourceGroupOptions) *runtime.Pager[ClientListByResourceGroupResponse]

NewListByResourceGroupPager - Get all the delegatedController resources in a resource group.

Generated from API version 2021-03-15

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

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/controllerListByRG.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewClient().NewListByResourceGroupPager("testRG", 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.DelegatedControllers = armdelegatednetwork.DelegatedControllers{
		// 	Value: []*armdelegatednetwork.DelegatedController{
		// 		{
		// 			Name: to.Ptr("testcontroller"),
		// 			Type: to.Ptr("Microsoft.DelegatedNetwork/controller"),
		// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
		// 			Location: to.Ptr("West US"),
		// 			Properties: &armdelegatednetwork.DelegatedControllerProperties{
		// 				DncAppID: to.Ptr("ac1192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 				DncEndpoint: to.Ptr("https://orch.useast.dnc.azure.com"),
		// 				DncTenantID: to.Ptr("66192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 				ProvisioningState: to.Ptr(armdelegatednetwork.ControllerStateSucceeded),
		// 				ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*Client) NewListBySubscriptionPager

func (client *Client) NewListBySubscriptionPager(options *ClientListBySubscriptionOptions) *runtime.Pager[ClientListBySubscriptionResponse]

NewListBySubscriptionPager - Get all the delegatedController resources in a subscription.

Generated from API version 2021-03-15

  • options - ClientListBySubscriptionOptions contains the optional parameters for the Client.NewListBySubscriptionPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/controllerListBySub.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewClient().NewListBySubscriptionPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.DelegatedControllers = armdelegatednetwork.DelegatedControllers{
		// 	Value: []*armdelegatednetwork.DelegatedController{
		// 		{
		// 			Name: to.Ptr("testcontroller"),
		// 			Type: to.Ptr("Microsoft.DelegatedNetwork/controller"),
		// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
		// 			Location: to.Ptr("West US"),
		// 			Properties: &armdelegatednetwork.DelegatedControllerProperties{
		// 				DncAppID: to.Ptr("ac1192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 				DncEndpoint: to.Ptr("https://orch.useast.dnc.azure.com"),
		// 				DncTenantID: to.Ptr("66192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 				ProvisioningState: to.Ptr(armdelegatednetwork.ControllerStateSucceeded),
		// 				ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
		// 			},
		// 	}},
		// }
	}
}
Output:

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

func (c *ClientFactory) NewClient() *Client

NewClient creates a new instance of Client.

func (*ClientFactory) NewControllerClient added in v1.1.0

func (c *ClientFactory) NewControllerClient() *ControllerClient

NewControllerClient creates a new instance of ControllerClient.

func (*ClientFactory) NewDelegatedSubnetServiceClient added in v1.1.0

func (c *ClientFactory) NewDelegatedSubnetServiceClient() *DelegatedSubnetServiceClient

NewDelegatedSubnetServiceClient creates a new instance of DelegatedSubnetServiceClient.

func (*ClientFactory) NewOperationsClient added in v1.1.0

func (c *ClientFactory) NewOperationsClient() *OperationsClient

NewOperationsClient creates a new instance of OperationsClient.

func (*ClientFactory) NewOrchestratorInstanceServiceClient added in v1.1.0

func (c *ClientFactory) NewOrchestratorInstanceServiceClient() *OrchestratorInstanceServiceClient

NewOrchestratorInstanceServiceClient creates a new instance of OrchestratorInstanceServiceClient.

type ClientListByResourceGroupOptions

type ClientListByResourceGroupOptions struct {
}

ClientListByResourceGroupOptions contains the optional parameters for the Client.NewListByResourceGroupPager method.

type ClientListByResourceGroupResponse

type ClientListByResourceGroupResponse struct {
	// An array of Delegated controller resources.
	DelegatedControllers
}

ClientListByResourceGroupResponse contains the response from method Client.NewListByResourceGroupPager.

type ClientListBySubscriptionOptions

type ClientListBySubscriptionOptions struct {
}

ClientListBySubscriptionOptions contains the optional parameters for the Client.NewListBySubscriptionPager method.

type ClientListBySubscriptionResponse

type ClientListBySubscriptionResponse struct {
	// An array of Delegated controller resources.
	DelegatedControllers
}

ClientListBySubscriptionResponse contains the response from method Client.NewListBySubscriptionPager.

type ControllerClient

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

ControllerClient contains the methods for the Controller group. Don't use this type directly, use NewControllerClient() instead.

func NewControllerClient

func NewControllerClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ControllerClient, error)

NewControllerClient creates a new instance of ControllerClient 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 (*ControllerClient) BeginCreate

func (client *ControllerClient) BeginCreate(ctx context.Context, resourceGroupName string, resourceName string, parameters DelegatedController, options *ControllerClientBeginCreateOptions) (*runtime.Poller[ControllerClientCreateResponse], error)

BeginCreate - Create a dnc controller If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • parameters - controller type parameters
  • options - ControllerClientBeginCreateOptions contains the optional parameters for the ControllerClient.BeginCreate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/putController.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/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewControllerClient().BeginCreate(ctx, "TestRG", "testcontroller", armdelegatednetwork.DelegatedController{
		Location: to.Ptr("West US"),
	}, 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.DelegatedController = armdelegatednetwork.DelegatedController{
	// 	Name: to.Ptr("testcontroller"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/controller"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
	// 	Location: to.Ptr("West US"),
	// 	Properties: &armdelegatednetwork.DelegatedControllerProperties{
	// 		DncAppID: to.Ptr("ac1192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		DncEndpoint: to.Ptr("https://orch.useast.dnc.azure.com"),
	// 		DncTenantID: to.Ptr("66192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.ControllerStateSucceeded),
	// 		ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
	// 	},
	// }
}
Output:

func (*ControllerClient) BeginDelete

func (client *ControllerClient) BeginDelete(ctx context.Context, resourceGroupName string, resourceName string, options *ControllerClientBeginDeleteOptions) (*runtime.Poller[ControllerClientDeleteResponse], error)

BeginDelete - Deletes the DNC controller If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • options - ControllerClientBeginDeleteOptions contains the optional parameters for the ControllerClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/deleteController.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewControllerClient().BeginDelete(ctx, "TestRG", "testcontroller", 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 (*ControllerClient) GetDetails

func (client *ControllerClient) GetDetails(ctx context.Context, resourceGroupName string, resourceName string, options *ControllerClientGetDetailsOptions) (ControllerClientGetDetailsResponse, error)

GetDetails - Gets details about the specified dnc controller. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • options - ControllerClientGetDetailsOptions contains the optional parameters for the ControllerClient.GetDetails method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/getController.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewControllerClient().GetDetails(ctx, "TestRG", "testcontroller", 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.DelegatedController = armdelegatednetwork.DelegatedController{
	// 	Name: to.Ptr("testcontroller"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/controller"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
	// 	Location: to.Ptr("West US"),
	// 	Properties: &armdelegatednetwork.DelegatedControllerProperties{
	// 		DncAppID: to.Ptr("ac1192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		DncEndpoint: to.Ptr("https://orch.useast.dnc.azure.com"),
	// 		DncTenantID: to.Ptr("66192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.ControllerStateSucceeded),
	// 		ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
	// 	},
	// }
}
Output:

func (*ControllerClient) Patch

func (client *ControllerClient) Patch(ctx context.Context, resourceGroupName string, resourceName string, parameters ControllerResourceUpdateParameters, options *ControllerClientPatchOptions) (ControllerClientPatchResponse, error)

Patch - Update dnc controller If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • parameters - controller type parameters
  • options - ControllerClientPatchOptions contains the optional parameters for the ControllerClient.Patch method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/patchController.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/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewControllerClient().Patch(ctx, "TestRG", "testcontroller", armdelegatednetwork.ControllerResourceUpdateParameters{
		Tags: map[string]*string{
			"key": to.Ptr("value"),
		},
	}, 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.DelegatedController = armdelegatednetwork.DelegatedController{
	// 	Name: to.Ptr("testcontroller"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/controller"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
	// 	Location: to.Ptr("West US"),
	// 	Tags: map[string]*string{
	// 		"key": to.Ptr("value"),
	// 	},
	// 	Properties: &armdelegatednetwork.DelegatedControllerProperties{
	// 		DncAppID: to.Ptr("ac1192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		DncEndpoint: to.Ptr("https://orch.useast.dnc.azure.com"),
	// 		DncTenantID: to.Ptr("66192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.ControllerStateSucceeded),
	// 		ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
	// 	},
	// }
}
Output:

type ControllerClientBeginCreateOptions

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

ControllerClientBeginCreateOptions contains the optional parameters for the ControllerClient.BeginCreate method.

type ControllerClientBeginDeleteOptions

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

ControllerClientBeginDeleteOptions contains the optional parameters for the ControllerClient.BeginDelete method.

type ControllerClientCreateResponse

type ControllerClientCreateResponse struct {
	// Represents an instance of a DNC controller.
	DelegatedController
}

ControllerClientCreateResponse contains the response from method ControllerClient.BeginCreate.

type ControllerClientDeleteResponse

type ControllerClientDeleteResponse struct {
}

ControllerClientDeleteResponse contains the response from method ControllerClient.BeginDelete.

type ControllerClientGetDetailsOptions

type ControllerClientGetDetailsOptions struct {
}

ControllerClientGetDetailsOptions contains the optional parameters for the ControllerClient.GetDetails method.

type ControllerClientGetDetailsResponse

type ControllerClientGetDetailsResponse struct {
	// Represents an instance of a DNC controller.
	DelegatedController
}

ControllerClientGetDetailsResponse contains the response from method ControllerClient.GetDetails.

type ControllerClientPatchOptions

type ControllerClientPatchOptions struct {
}

ControllerClientPatchOptions contains the optional parameters for the ControllerClient.Patch method.

type ControllerClientPatchResponse

type ControllerClientPatchResponse struct {
	// Represents an instance of a DNC controller.
	DelegatedController
}

ControllerClientPatchResponse contains the response from method ControllerClient.Patch.

type ControllerDetails

type ControllerDetails struct {
	// controller arm resource id
	ID *string
}

ControllerDetails - controller details

func (ControllerDetails) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type ControllerDetails.

func (*ControllerDetails) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ControllerDetails.

type ControllerResource

type ControllerResource struct {
	// Location of the resource.
	Location *string

	// The resource tags.
	Tags map[string]*string

	// READ-ONLY; An identifier that represents the resource.
	ID *string

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

	// READ-ONLY; The type of resource.
	Type *string
}

ControllerResource - Represents an instance of a resource.

func (ControllerResource) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ControllerResource.

func (*ControllerResource) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ControllerResource.

type ControllerResourceUpdateParameters

type ControllerResourceUpdateParameters struct {
	// The resource tags.
	Tags map[string]*string
}

ControllerResourceUpdateParameters - Parameters for updating a resource.

func (ControllerResourceUpdateParameters) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ControllerResourceUpdateParameters.

func (*ControllerResourceUpdateParameters) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ControllerResourceUpdateParameters.

type ControllerState

type ControllerState string

ControllerState - The current state of dnc controller resource.

const (
	ControllerStateDeleting     ControllerState = "Deleting"
	ControllerStateFailed       ControllerState = "Failed"
	ControllerStateProvisioning ControllerState = "Provisioning"
	ControllerStateSucceeded    ControllerState = "Succeeded"
)

func PossibleControllerStateValues

func PossibleControllerStateValues() []ControllerState

PossibleControllerStateValues returns the possible values for the ControllerState const type.

type DelegatedController

type DelegatedController struct {
	// Location of the resource.
	Location *string

	// The resource tags.
	Tags map[string]*string

	// READ-ONLY; An identifier that represents the resource.
	ID *string

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

	// READ-ONLY; Properties of the provision operation request.
	Properties *DelegatedControllerProperties

	// READ-ONLY; The type of resource.
	Type *string
}

DelegatedController - Represents an instance of a DNC controller.

func (DelegatedController) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type DelegatedController.

func (*DelegatedController) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type DelegatedController.

type DelegatedControllerProperties

type DelegatedControllerProperties struct {
	// READ-ONLY; dnc application id should be used by customer to authenticate with dnc gateway.
	DncAppID *string

	// READ-ONLY; dnc endpoint url that customers can use to connect to
	DncEndpoint *string

	// READ-ONLY; tenant id of dnc application id
	DncTenantID *string

	// READ-ONLY; The current state of dnc controller resource.
	ProvisioningState *ControllerState

	// READ-ONLY; Resource guid.
	ResourceGUID *string
}

DelegatedControllerProperties - Properties of Delegated controller resource.

func (DelegatedControllerProperties) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type DelegatedControllerProperties.

func (*DelegatedControllerProperties) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type DelegatedControllerProperties.

type DelegatedControllers

type DelegatedControllers struct {
	// REQUIRED; An array of Delegated controller resources.
	Value []*DelegatedController

	// READ-ONLY; The URL to get the next set of controllers.
	NextLink *string
}

DelegatedControllers - An array of Delegated controller resources.

func (DelegatedControllers) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type DelegatedControllers.

func (*DelegatedControllers) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type DelegatedControllers.

type DelegatedSubnet

type DelegatedSubnet struct {
	// Location of the resource.
	Location *string

	// Properties of the provision operation request.
	Properties *DelegatedSubnetProperties

	// The resource tags.
	Tags map[string]*string

	// READ-ONLY; An identifier that represents the resource.
	ID *string

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

	// READ-ONLY; The type of resource.
	Type *string
}

DelegatedSubnet - Represents an instance of a orchestrator.

func (DelegatedSubnet) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type DelegatedSubnet.

func (*DelegatedSubnet) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type DelegatedSubnet.

type DelegatedSubnetProperties

type DelegatedSubnetProperties struct {
	// Properties of the controller.
	ControllerDetails *ControllerDetails

	// subnet details
	SubnetDetails *SubnetDetails

	// READ-ONLY; The current state of dnc delegated subnet resource.
	ProvisioningState *DelegatedSubnetState

	// READ-ONLY; Resource guid.
	ResourceGUID *string
}

DelegatedSubnetProperties - Properties of delegated subnet

func (DelegatedSubnetProperties) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type DelegatedSubnetProperties.

func (*DelegatedSubnetProperties) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type DelegatedSubnetProperties.

type DelegatedSubnetResource

type DelegatedSubnetResource struct {
	// Location of the resource.
	Location *string

	// The resource tags.
	Tags map[string]*string

	// READ-ONLY; An identifier that represents the resource.
	ID *string

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

	// READ-ONLY; The type of resource.
	Type *string
}

DelegatedSubnetResource - Represents an instance of a resource.

func (DelegatedSubnetResource) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type DelegatedSubnetResource.

func (*DelegatedSubnetResource) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type DelegatedSubnetResource.

type DelegatedSubnetServiceClient

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

DelegatedSubnetServiceClient contains the methods for the DelegatedSubnetService group. Don't use this type directly, use NewDelegatedSubnetServiceClient() instead.

func NewDelegatedSubnetServiceClient

func NewDelegatedSubnetServiceClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*DelegatedSubnetServiceClient, error)

NewDelegatedSubnetServiceClient creates a new instance of DelegatedSubnetServiceClient 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 (*DelegatedSubnetServiceClient) BeginDeleteDetails

BeginDeleteDetails - Delete dnc DelegatedSubnet. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • options - DelegatedSubnetServiceClientBeginDeleteDetailsOptions contains the optional parameters for the DelegatedSubnetServiceClient.BeginDeleteDetails method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/deleteDelegatedSubnet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewDelegatedSubnetServiceClient().BeginDeleteDetails(ctx, "TestRG", "delegated1", &armdelegatednetwork.DelegatedSubnetServiceClientBeginDeleteDetailsOptions{ForceDelete: 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 (*DelegatedSubnetServiceClient) BeginPatchDetails

BeginPatchDetails - Patch delegated subnet resource If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • parameters - Delegated subnet details.
  • options - DelegatedSubnetServiceClientBeginPatchDetailsOptions contains the optional parameters for the DelegatedSubnetServiceClient.BeginPatchDetails method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/patchDelegatedSubnet.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/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewDelegatedSubnetServiceClient().BeginPatchDetails(ctx, "TestRG", "delegated1", armdelegatednetwork.ResourceUpdateParameters{
		Tags: map[string]*string{
			"key": to.Ptr("value"),
		},
	}, 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.DelegatedSubnet = armdelegatednetwork.DelegatedSubnet{
	// 	Name: to.Ptr("delegated1"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/delegatedSubnets"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/delegatedSubnets/delegated1"),
	// 	Location: to.Ptr("West US"),
	// 	Tags: map[string]*string{
	// 		"key": to.Ptr("value"),
	// 	},
	// 	Properties: &armdelegatednetwork.DelegatedSubnetProperties{
	// 		ControllerDetails: &armdelegatednetwork.ControllerDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/dnctestcontroller"),
	// 		},
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.DelegatedSubnetStateSucceeded),
	// 		ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
	// 		SubnetDetails: &armdelegatednetwork.SubnetDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.Network/virtualNetworks/testvnet/subnets/testsubnet"),
	// 		},
	// 	},
	// }
}
Output:

func (*DelegatedSubnetServiceClient) BeginPutDetails

BeginPutDetails - Put delegated subnet resource If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • parameters - Delegated subnet details.
  • options - DelegatedSubnetServiceClientBeginPutDetailsOptions contains the optional parameters for the DelegatedSubnetServiceClient.BeginPutDetails method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/putDelegatedSubnet.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/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewDelegatedSubnetServiceClient().BeginPutDetails(ctx, "TestRG", "delegated1", armdelegatednetwork.DelegatedSubnet{
		Location: to.Ptr("West US"),
		Properties: &armdelegatednetwork.DelegatedSubnetProperties{
			ControllerDetails: &armdelegatednetwork.ControllerDetails{
				ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/dnctestcontroller"),
			},
			SubnetDetails: &armdelegatednetwork.SubnetDetails{
				ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.Network/virtualNetworks/testvnet/subnets/testsubnet"),
			},
		},
	}, 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.DelegatedSubnet = armdelegatednetwork.DelegatedSubnet{
	// 	Name: to.Ptr("delegated1"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/delegatedSubnets"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/delegatedSubnets/delegated1"),
	// 	Location: to.Ptr("West US"),
	// 	Properties: &armdelegatednetwork.DelegatedSubnetProperties{
	// 		ControllerDetails: &armdelegatednetwork.ControllerDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/dnctestcontroller"),
	// 		},
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.DelegatedSubnetStateSucceeded),
	// 		ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
	// 		SubnetDetails: &armdelegatednetwork.SubnetDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.Network/virtualNetworks/testvnet/subnets/testsubnet"),
	// 		},
	// 	},
	// }
}
Output:

func (*DelegatedSubnetServiceClient) GetDetails

GetDetails - Gets details about the specified dnc DelegatedSubnet Link. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • options - DelegatedSubnetServiceClientGetDetailsOptions contains the optional parameters for the DelegatedSubnetServiceClient.GetDetails method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/getDelegatedSubnet.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewDelegatedSubnetServiceClient().GetDetails(ctx, "TestRG", "delegated1", 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.DelegatedSubnet = armdelegatednetwork.DelegatedSubnet{
	// 	Name: to.Ptr("delegated1"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/delegatedSubnets"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/delegatedSubnets/delegated1"),
	// 	Location: to.Ptr("West US"),
	// 	Properties: &armdelegatednetwork.DelegatedSubnetProperties{
	// 		ControllerDetails: &armdelegatednetwork.ControllerDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/dnctestcontroller"),
	// 		},
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.DelegatedSubnetStateSucceeded),
	// 		ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
	// 		SubnetDetails: &armdelegatednetwork.SubnetDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.Network/virtualNetworks/testvnet/subnets/testsubnet"),
	// 		},
	// 	},
	// }
}
Output:

func (*DelegatedSubnetServiceClient) NewListByResourceGroupPager

NewListByResourceGroupPager - Get all the DelegatedSubnets resources in a resource group.

Generated from API version 2021-03-15

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

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/delegatedSubnetListByRG.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewDelegatedSubnetServiceClient().NewListByResourceGroupPager("testRG", 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.DelegatedSubnets = armdelegatednetwork.DelegatedSubnets{
		// 	Value: []*armdelegatednetwork.DelegatedSubnet{
		// 		{
		// 			Name: to.Ptr("delegated1"),
		// 			Type: to.Ptr("Microsoft.DelegatedNetwork/delegatedSubnets"),
		// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/delegatedSubnets/delegated1"),
		// 			Location: to.Ptr("West US"),
		// 			Properties: &armdelegatednetwork.DelegatedSubnetProperties{
		// 				ControllerDetails: &armdelegatednetwork.ControllerDetails{
		// 					ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/dnctestcontroller"),
		// 				},
		// 				ProvisioningState: to.Ptr(armdelegatednetwork.DelegatedSubnetStateSucceeded),
		// 				ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
		// 				SubnetDetails: &armdelegatednetwork.SubnetDetails{
		// 					ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.Network/virtualNetworks/testvnet/subnets/testsubnet"),
		// 				},
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*DelegatedSubnetServiceClient) NewListBySubscriptionPager

NewListBySubscriptionPager - Get all the DelegatedSubnets resources in a subscription.

Generated from API version 2021-03-15

  • options - DelegatedSubnetServiceClientListBySubscriptionOptions contains the optional parameters for the DelegatedSubnetServiceClient.NewListBySubscriptionPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/delegatedSubnetListBySub.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewDelegatedSubnetServiceClient().NewListBySubscriptionPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.DelegatedSubnets = armdelegatednetwork.DelegatedSubnets{
		// 	Value: []*armdelegatednetwork.DelegatedSubnet{
		// 		{
		// 			Name: to.Ptr("delegated1"),
		// 			Type: to.Ptr("Microsoft.DelegatedNetwork/delegatedSubnets"),
		// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.Network/virtualNetworks/testvnet/subnets/testsubnet/providers/Microsoft.DelegatedNetwork/delegatedSubnets/delegated1"),
		// 			Location: to.Ptr("West US"),
		// 			Properties: &armdelegatednetwork.DelegatedSubnetProperties{
		// 				ControllerDetails: &armdelegatednetwork.ControllerDetails{
		// 					ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/dnctestcontroller"),
		// 				},
		// 				ProvisioningState: to.Ptr(armdelegatednetwork.DelegatedSubnetStateSucceeded),
		// 				ResourceGUID: to.Ptr("5a82cbcf-e8ea-4175-ac2b-ad36a73f9801"),
		// 				SubnetDetails: &armdelegatednetwork.SubnetDetails{
		// 					ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.Network/virtualNetworks/testvnet/subnets/testsubnet"),
		// 				},
		// 			},
		// 	}},
		// }
	}
}
Output:

type DelegatedSubnetServiceClientBeginDeleteDetailsOptions

type DelegatedSubnetServiceClientBeginDeleteDetailsOptions struct {
	// Force delete resource
	ForceDelete *bool

	// Resumes the LRO from the provided token.
	ResumeToken string
}

DelegatedSubnetServiceClientBeginDeleteDetailsOptions contains the optional parameters for the DelegatedSubnetServiceClient.BeginDeleteDetails method.

type DelegatedSubnetServiceClientBeginPatchDetailsOptions

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

DelegatedSubnetServiceClientBeginPatchDetailsOptions contains the optional parameters for the DelegatedSubnetServiceClient.BeginPatchDetails method.

type DelegatedSubnetServiceClientBeginPutDetailsOptions

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

DelegatedSubnetServiceClientBeginPutDetailsOptions contains the optional parameters for the DelegatedSubnetServiceClient.BeginPutDetails method.

type DelegatedSubnetServiceClientDeleteDetailsResponse

type DelegatedSubnetServiceClientDeleteDetailsResponse struct {
}

DelegatedSubnetServiceClientDeleteDetailsResponse contains the response from method DelegatedSubnetServiceClient.BeginDeleteDetails.

type DelegatedSubnetServiceClientGetDetailsOptions

type DelegatedSubnetServiceClientGetDetailsOptions struct {
}

DelegatedSubnetServiceClientGetDetailsOptions contains the optional parameters for the DelegatedSubnetServiceClient.GetDetails method.

type DelegatedSubnetServiceClientGetDetailsResponse

type DelegatedSubnetServiceClientGetDetailsResponse struct {
	// Represents an instance of a orchestrator.
	DelegatedSubnet
}

DelegatedSubnetServiceClientGetDetailsResponse contains the response from method DelegatedSubnetServiceClient.GetDetails.

type DelegatedSubnetServiceClientListByResourceGroupOptions

type DelegatedSubnetServiceClientListByResourceGroupOptions struct {
}

DelegatedSubnetServiceClientListByResourceGroupOptions contains the optional parameters for the DelegatedSubnetServiceClient.NewListByResourceGroupPager method.

type DelegatedSubnetServiceClientListByResourceGroupResponse

type DelegatedSubnetServiceClientListByResourceGroupResponse struct {
	// An array of DelegatedSubnet resources.
	DelegatedSubnets
}

DelegatedSubnetServiceClientListByResourceGroupResponse contains the response from method DelegatedSubnetServiceClient.NewListByResourceGroupPager.

type DelegatedSubnetServiceClientListBySubscriptionOptions

type DelegatedSubnetServiceClientListBySubscriptionOptions struct {
}

DelegatedSubnetServiceClientListBySubscriptionOptions contains the optional parameters for the DelegatedSubnetServiceClient.NewListBySubscriptionPager method.

type DelegatedSubnetServiceClientListBySubscriptionResponse

type DelegatedSubnetServiceClientListBySubscriptionResponse struct {
	// An array of DelegatedSubnet resources.
	DelegatedSubnets
}

DelegatedSubnetServiceClientListBySubscriptionResponse contains the response from method DelegatedSubnetServiceClient.NewListBySubscriptionPager.

type DelegatedSubnetServiceClientPatchDetailsResponse

type DelegatedSubnetServiceClientPatchDetailsResponse struct {
	// Represents an instance of a orchestrator.
	DelegatedSubnet
}

DelegatedSubnetServiceClientPatchDetailsResponse contains the response from method DelegatedSubnetServiceClient.BeginPatchDetails.

type DelegatedSubnetServiceClientPutDetailsResponse

type DelegatedSubnetServiceClientPutDetailsResponse struct {
	// Represents an instance of a orchestrator.
	DelegatedSubnet
}

DelegatedSubnetServiceClientPutDetailsResponse contains the response from method DelegatedSubnetServiceClient.BeginPutDetails.

type DelegatedSubnetState

type DelegatedSubnetState string

DelegatedSubnetState - The current state of dnc delegated subnet resource.

const (
	DelegatedSubnetStateDeleting     DelegatedSubnetState = "Deleting"
	DelegatedSubnetStateFailed       DelegatedSubnetState = "Failed"
	DelegatedSubnetStateProvisioning DelegatedSubnetState = "Provisioning"
	DelegatedSubnetStateSucceeded    DelegatedSubnetState = "Succeeded"
)

func PossibleDelegatedSubnetStateValues

func PossibleDelegatedSubnetStateValues() []DelegatedSubnetState

PossibleDelegatedSubnetStateValues returns the possible values for the DelegatedSubnetState const type.

type DelegatedSubnets

type DelegatedSubnets struct {
	// REQUIRED; An array of DelegatedSubnet resources.
	Value []*DelegatedSubnet

	// READ-ONLY; The URL to get the next set of DelegatedSubnet resources.
	NextLink *string
}

DelegatedSubnets - An array of DelegatedSubnet resources.

func (DelegatedSubnets) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type DelegatedSubnets.

func (*DelegatedSubnets) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type DelegatedSubnets.

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

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

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 OperationsClient

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

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

func NewOperationsClient

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

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

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

func (*OperationsClient) NewListPager

NewListPager - Lists all of the available DelegatedNetwork service REST API operations.

Generated from API version 2021-03-15

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

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/delegatedNetworkOperationsList.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewOperationsClient().NewListPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.OperationListResult = armdelegatednetwork.OperationListResult{
		// 	Value: []*armdelegatednetwork.Operation{
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/controller/write"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Create or update a Controller Service instance."),
		// 				Operation: to.Ptr("Create or update a Controller Service instance."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Service"),
		// 				Resource: to.Ptr("Microsoft Delegated Network Controller Service instance"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/controller/read"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Get a Controller Service instance."),
		// 				Operation: to.Ptr("Get a Controller Service instance."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Service"),
		// 				Resource: to.Ptr("Microsoft Delegated Network Controller Service instance"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/controller/delete"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Delete a Controller Service instance."),
		// 				Operation: to.Ptr("Delete a Controller Service instance."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Service"),
		// 				Resource: to.Ptr("Microsoft Delegated Network Controller Service instance"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/orchestratorInstances/write"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Create or update a orchestratorInstance."),
		// 				Operation: to.Ptr("Create or update a orchestratorInstance."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Service"),
		// 				Resource: to.Ptr("Microsoft Delegated Network orchestratorInstance"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/controller/read"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Get a orchestratorInstance."),
		// 				Operation: to.Ptr("Get a orchestratorInstances."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Service"),
		// 				Resource: to.Ptr("Microsoft Delegated Network orchestratorInstance"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/controller/delete"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Delete a orchestratorInstance."),
		// 				Operation: to.Ptr("Delete a orchestratorInstance."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Service"),
		// 				Resource: to.Ptr("Microsoft Delegated Network orchestratorInstance"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/delegatedSubnets/write"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Create or update a Delegated subnet instance."),
		// 				Operation: to.Ptr("Create or update a Delegated subnet instance."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Service"),
		// 				Resource: to.Ptr("Microsoft Delegated subnet instance"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/delegatedSubnets/read"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Get a Delegated subnet instance."),
		// 				Operation: to.Ptr("Get a Delegated subnet instance."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Service"),
		// 				Resource: to.Ptr("Microsoft Delegated subnet instance"),
		// 			},
		// 		},
		// 		{
		// 			Name: to.Ptr("Microsoft.DelegatedNetwork/delegatedSubnets/delete"),
		// 			Display: &armdelegatednetwork.OperationDisplay{
		// 				Description: to.Ptr("Delete a Delegated subnet instance."),
		// 				Operation: to.Ptr("Delete a Delegated subnet instance."),
		// 				Provider: to.Ptr("Microsoft Delegated Network Controller Service"),
		// 				Resource: to.Ptr("Microsoft Delegated subnet instance"),
		// 			},
		// 	}},
		// }
	}
}
Output:

type OperationsClientListOptions

type OperationsClientListOptions struct {
}

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

type OperationsClientListResponse

type OperationsClientListResponse struct {
	// A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results.
	OperationListResult
}

OperationsClientListResponse contains the response from method OperationsClient.NewListPager.

type Orchestrator

type Orchestrator struct {
	// REQUIRED; The kind of workbook. Choices are user and shared.
	Kind *OrchestratorKind

	// The identity of the orchestrator
	Identity *OrchestratorIdentity

	// Location of the resource.
	Location *string

	// Properties of the provision operation request.
	Properties *OrchestratorResourceProperties

	// The resource tags.
	Tags map[string]*string

	// READ-ONLY; An identifier that represents the resource.
	ID *string

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

	// READ-ONLY; The type of resource.
	Type *string
}

Orchestrator - Represents an instance of a orchestrator.

func (Orchestrator) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type Orchestrator.

func (*Orchestrator) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type Orchestrator.

type OrchestratorIdentity

type OrchestratorIdentity struct {
	// The type of identity used for orchestrator cluster. Type 'SystemAssigned' will use an implicitly created identity orchestrator
	// clusters
	Type *ResourceIdentityType

	// READ-ONLY; The principal id of the system assigned identity which is used by orchestrator.
	PrincipalID *string

	// READ-ONLY; The tenant id of the system assigned identity which is used by orchestrator.
	TenantID *string
}

func (OrchestratorIdentity) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type OrchestratorIdentity.

func (*OrchestratorIdentity) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type OrchestratorIdentity.

type OrchestratorInstanceServiceClient

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

OrchestratorInstanceServiceClient contains the methods for the OrchestratorInstanceService group. Don't use this type directly, use NewOrchestratorInstanceServiceClient() instead.

func NewOrchestratorInstanceServiceClient

func NewOrchestratorInstanceServiceClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*OrchestratorInstanceServiceClient, error)

NewOrchestratorInstanceServiceClient creates a new instance of OrchestratorInstanceServiceClient 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 (*OrchestratorInstanceServiceClient) BeginCreate

BeginCreate - Create a orchestrator instance If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • parameters - OrchestratorInstance type parameters
  • options - OrchestratorInstanceServiceClientBeginCreateOptions contains the optional parameters for the OrchestratorInstanceServiceClient.BeginCreate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/putOrchestrator.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/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewOrchestratorInstanceServiceClient().BeginCreate(ctx, "TestRG", "testk8s1", armdelegatednetwork.Orchestrator{
		Identity: &armdelegatednetwork.OrchestratorIdentity{
			Type: to.Ptr(armdelegatednetwork.ResourceIdentityTypeSystemAssigned),
		},
		Kind:     to.Ptr(armdelegatednetwork.OrchestratorKindKubernetes),
		Location: to.Ptr("West US"),
		Properties: &armdelegatednetwork.OrchestratorResourceProperties{
			APIServerEndpoint: to.Ptr("https://testk8s.cloudapp.net"),
			ClusterRootCA:     to.Ptr("ddsadsad344mfdsfdl"),
			ControllerDetails: &armdelegatednetwork.ControllerDetails{
				ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
			},
			OrchestratorAppID:     to.Ptr("546192d7-503f-477a-9cfe-4efc3ee2b6e1"),
			OrchestratorTenantID:  to.Ptr("da6192d7-503f-477a-9cfe-4efc3ee2b6c3"),
			PrivateLinkResourceID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.Network/privateLinkServices/plresource1"),
		},
	}, 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.Orchestrator = armdelegatednetwork.Orchestrator{
	// 	Name: to.Ptr("testk8s1"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/orchestrators"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/orchestrators/testk8s1"),
	// 	Identity: &armdelegatednetwork.OrchestratorIdentity{
	// 		Type: to.Ptr(armdelegatednetwork.ResourceIdentityTypeSystemAssigned),
	// 		PrincipalID: to.Ptr("7a2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		TenantID: to.Ptr("3e2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 	},
	// 	Kind: to.Ptr(armdelegatednetwork.OrchestratorKindKubernetes),
	// 	Location: to.Ptr("West US"),
	// 	Properties: &armdelegatednetwork.OrchestratorResourceProperties{
	// 		APIServerEndpoint: to.Ptr("https://testk8s.cloudapp.net"),
	// 		ClusterRootCA: to.Ptr("ddsadsad344mfdsfdl"),
	// 		ControllerDetails: &armdelegatednetwork.ControllerDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
	// 		},
	// 		OrchestratorAppID: to.Ptr("546192d7-503f-477a-9cfe-4efc3ee2b6e1"),
	// 		OrchestratorTenantID: to.Ptr("da6192d7-503f-477a-9cfe-4efc3ee2b6c3"),
	// 		PrivateLinkResourceID: to.Ptr("/subscriptions/d21192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/plrg/Microsoft.Network/PrivateLink/pl1"),
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.OrchestratorInstanceStateSucceeded),
	// 		ResourceGUID: to.Ptr("1b2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 	},
	// }
}
Output:

func (*OrchestratorInstanceServiceClient) BeginDelete

BeginDelete - Deletes the Orchestrator Instance If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • options - OrchestratorInstanceServiceClientBeginDeleteOptions contains the optional parameters for the OrchestratorInstanceServiceClient.BeginDelete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/deleteOrchestrator.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewOrchestratorInstanceServiceClient().BeginDelete(ctx, "TestRG", "k8stest1", &armdelegatednetwork.OrchestratorInstanceServiceClientBeginDeleteOptions{ForceDelete: 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 (*OrchestratorInstanceServiceClient) GetDetails

GetDetails - Gets details about the orchestrator instance. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • options - OrchestratorInstanceServiceClientGetDetailsOptions contains the optional parameters for the OrchestratorInstanceServiceClient.GetDetails method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/getOrchestrator.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewOrchestratorInstanceServiceClient().GetDetails(ctx, "TestRG", "testk8s1", 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.Orchestrator = armdelegatednetwork.Orchestrator{
	// 	Name: to.Ptr("testk8s1"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/orchestrators"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/orchestrators/testk8s1"),
	// 	Identity: &armdelegatednetwork.OrchestratorIdentity{
	// 		Type: to.Ptr(armdelegatednetwork.ResourceIdentityTypeSystemAssigned),
	// 		PrincipalID: to.Ptr("7a2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		TenantID: to.Ptr("3e2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 	},
	// 	Kind: to.Ptr(armdelegatednetwork.OrchestratorKindKubernetes),
	// 	Location: to.Ptr("West US"),
	// 	Properties: &armdelegatednetwork.OrchestratorResourceProperties{
	// 		APIServerEndpoint: to.Ptr("https://testk8s.cloudapp.net"),
	// 		ClusterRootCA: to.Ptr("ddsadsad344mfdsfdl"),
	// 		ControllerDetails: &armdelegatednetwork.ControllerDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
	// 		},
	// 		OrchestratorAppID: to.Ptr("546192d7-503f-477a-9cfe-4efc3ee2b6e1"),
	// 		OrchestratorTenantID: to.Ptr("da6192d7-503f-477a-9cfe-4efc3ee2b6c3"),
	// 		PrivateLinkResourceID: to.Ptr("/subscriptions/d21192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/plrg/Microsoft.Network/PrivateLink/pl1"),
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.OrchestratorInstanceStateSucceeded),
	// 		ResourceGUID: to.Ptr("1b2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 	},
	// }
}
Output:

func (*OrchestratorInstanceServiceClient) NewListByResourceGroupPager

NewListByResourceGroupPager - Get all the OrchestratorInstances resources in a resource group.

Generated from API version 2021-03-15

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

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/orchestratorInstanceListByRG.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewOrchestratorInstanceServiceClient().NewListByResourceGroupPager("testRG", 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.Orchestrators = armdelegatednetwork.Orchestrators{
		// 	Value: []*armdelegatednetwork.Orchestrator{
		// 		{
		// 			Name: to.Ptr("testk8s1"),
		// 			Type: to.Ptr("Microsoft.DelegatedNetwork/orchestrators"),
		// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/orchestrators/testk8s1"),
		// 			Identity: &armdelegatednetwork.OrchestratorIdentity{
		// 				Type: to.Ptr(armdelegatednetwork.ResourceIdentityTypeSystemAssigned),
		// 				PrincipalID: to.Ptr("7a2192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 				TenantID: to.Ptr("3e2192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 			},
		// 			Kind: to.Ptr(armdelegatednetwork.OrchestratorKindKubernetes),
		// 			Location: to.Ptr("West US"),
		// 			Properties: &armdelegatednetwork.OrchestratorResourceProperties{
		// 				APIServerEndpoint: to.Ptr("https://testk8s.cloudapp.net"),
		// 				ClusterRootCA: to.Ptr("ddsadsad344mfdsfdl"),
		// 				ControllerDetails: &armdelegatednetwork.ControllerDetails{
		// 					ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
		// 				},
		// 				OrchestratorAppID: to.Ptr("546192d7-503f-477a-9cfe-4efc3ee2b6e1"),
		// 				OrchestratorTenantID: to.Ptr("da6192d7-503f-477a-9cfe-4efc3ee2b6c3"),
		// 				PrivateLinkResourceID: to.Ptr("/subscriptions/d21192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/plrg/Microsoft.Network/PrivateLink/pl1"),
		// 				ProvisioningState: to.Ptr(armdelegatednetwork.OrchestratorInstanceStateSucceeded),
		// 				ResourceGUID: to.Ptr("1b2192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*OrchestratorInstanceServiceClient) NewListBySubscriptionPager

NewListBySubscriptionPager - Get all the orchestratorInstance resources in a subscription.

Generated from API version 2021-03-15

  • options - OrchestratorInstanceServiceClientListBySubscriptionOptions contains the optional parameters for the OrchestratorInstanceServiceClient.NewListBySubscriptionPager method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/orchestratorInstanceListBySub.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewOrchestratorInstanceServiceClient().NewListBySubscriptionPager(nil)
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.Orchestrators = armdelegatednetwork.Orchestrators{
		// 	Value: []*armdelegatednetwork.Orchestrator{
		// 		{
		// 			Name: to.Ptr("testk8s1"),
		// 			Type: to.Ptr("Microsoft.DelegatedNetwork/orchestrators"),
		// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/orchestrators/testk8s1"),
		// 			Identity: &armdelegatednetwork.OrchestratorIdentity{
		// 				Type: to.Ptr(armdelegatednetwork.ResourceIdentityTypeSystemAssigned),
		// 				PrincipalID: to.Ptr("7a2192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 				TenantID: to.Ptr("3e2192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 			},
		// 			Kind: to.Ptr(armdelegatednetwork.OrchestratorKindKubernetes),
		// 			Location: to.Ptr("West US"),
		// 			Properties: &armdelegatednetwork.OrchestratorResourceProperties{
		// 				APIServerEndpoint: to.Ptr("https://testk8s.cloudapp.net"),
		// 				ClusterRootCA: to.Ptr("ddsadsad344mfdsfdl"),
		// 				ControllerDetails: &armdelegatednetwork.ControllerDetails{
		// 					ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
		// 				},
		// 				OrchestratorAppID: to.Ptr("546192d7-503f-477a-9cfe-4efc3ee2b6e1"),
		// 				OrchestratorTenantID: to.Ptr("da6192d7-503f-477a-9cfe-4efc3ee2b6c3"),
		// 				PrivateLinkResourceID: to.Ptr("/subscriptions/d21192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/plrg/Microsoft.Network/PrivateLink/pl1"),
		// 				ProvisioningState: to.Ptr(armdelegatednetwork.OrchestratorInstanceStateSucceeded),
		// 				ResourceGUID: to.Ptr("1b2192d7-503f-477a-9cfe-4efc3ee2bd60"),
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*OrchestratorInstanceServiceClient) Patch

Patch - Update Orchestrator Instance If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2021-03-15

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • resourceName - The name of the resource. It must be a minimum of 3 characters, and a maximum of 63.
  • parameters - OrchestratorInstance update parameters
  • options - OrchestratorInstanceServiceClientPatchOptions contains the optional parameters for the OrchestratorInstanceServiceClient.Patch method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/163e27c0ca7570bc39e00a46f255740d9b3ba3cb/specification/dnc/resource-manager/Microsoft.DelegatedNetwork/stable/2021-03-15/examples/patchOrchestrator.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/delegatednetwork/armdelegatednetwork"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdelegatednetwork.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewOrchestratorInstanceServiceClient().Patch(ctx, "TestRG", "testk8s1", armdelegatednetwork.OrchestratorResourceUpdateParameters{
		Tags: map[string]*string{
			"key": to.Ptr("value"),
		},
	}, 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.Orchestrator = armdelegatednetwork.Orchestrator{
	// 	Name: to.Ptr("testk8s1"),
	// 	Type: to.Ptr("Microsoft.DelegatedNetwork/orchestrators"),
	// 	ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/orchestrators/testk8s1"),
	// 	Identity: &armdelegatednetwork.OrchestratorIdentity{
	// 		Type: to.Ptr(armdelegatednetwork.ResourceIdentityTypeSystemAssigned),
	// 		PrincipalID: to.Ptr("7a2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 		TenantID: to.Ptr("3e2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 	},
	// 	Kind: to.Ptr(armdelegatednetwork.OrchestratorKindKubernetes),
	// 	Location: to.Ptr("West US"),
	// 	Tags: map[string]*string{
	// 		"key": to.Ptr("value"),
	// 	},
	// 	Properties: &armdelegatednetwork.OrchestratorResourceProperties{
	// 		APIServerEndpoint: to.Ptr("https://testk8s.cloudapp.net"),
	// 		ClusterRootCA: to.Ptr("ddsadsad344mfdsfdl"),
	// 		ControllerDetails: &armdelegatednetwork.ControllerDetails{
	// 			ID: to.Ptr("/subscriptions/613192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/TestRG/providers/Microsoft.DelegatedNetwork/controller/testcontroller"),
	// 		},
	// 		OrchestratorAppID: to.Ptr("546192d7-503f-477a-9cfe-4efc3ee2b6e1"),
	// 		OrchestratorTenantID: to.Ptr("da6192d7-503f-477a-9cfe-4efc3ee2b6c3"),
	// 		PrivateLinkResourceID: to.Ptr("/subscriptions/d21192d7-503f-477a-9cfe-4efc3ee2bd60/resourceGroups/plrg/Microsoft.Network/PrivateLink/pl1"),
	// 		ProvisioningState: to.Ptr(armdelegatednetwork.OrchestratorInstanceStateSucceeded),
	// 		ResourceGUID: to.Ptr("1b2192d7-503f-477a-9cfe-4efc3ee2bd60"),
	// 	},
	// }
}
Output:

type OrchestratorInstanceServiceClientBeginCreateOptions

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

OrchestratorInstanceServiceClientBeginCreateOptions contains the optional parameters for the OrchestratorInstanceServiceClient.BeginCreate method.

type OrchestratorInstanceServiceClientBeginDeleteOptions

type OrchestratorInstanceServiceClientBeginDeleteOptions struct {
	// Force delete resource
	ForceDelete *bool

	// Resumes the LRO from the provided token.
	ResumeToken string
}

OrchestratorInstanceServiceClientBeginDeleteOptions contains the optional parameters for the OrchestratorInstanceServiceClient.BeginDelete method.

type OrchestratorInstanceServiceClientCreateResponse

type OrchestratorInstanceServiceClientCreateResponse struct {
	// Represents an instance of a orchestrator.
	Orchestrator
}

OrchestratorInstanceServiceClientCreateResponse contains the response from method OrchestratorInstanceServiceClient.BeginCreate.

type OrchestratorInstanceServiceClientDeleteResponse

type OrchestratorInstanceServiceClientDeleteResponse struct {
}

OrchestratorInstanceServiceClientDeleteResponse contains the response from method OrchestratorInstanceServiceClient.BeginDelete.

type OrchestratorInstanceServiceClientGetDetailsOptions

type OrchestratorInstanceServiceClientGetDetailsOptions struct {
}

OrchestratorInstanceServiceClientGetDetailsOptions contains the optional parameters for the OrchestratorInstanceServiceClient.GetDetails method.

type OrchestratorInstanceServiceClientGetDetailsResponse

type OrchestratorInstanceServiceClientGetDetailsResponse struct {
	// Represents an instance of a orchestrator.
	Orchestrator
}

OrchestratorInstanceServiceClientGetDetailsResponse contains the response from method OrchestratorInstanceServiceClient.GetDetails.

type OrchestratorInstanceServiceClientListByResourceGroupOptions

type OrchestratorInstanceServiceClientListByResourceGroupOptions struct {
}

OrchestratorInstanceServiceClientListByResourceGroupOptions contains the optional parameters for the OrchestratorInstanceServiceClient.NewListByResourceGroupPager method.

type OrchestratorInstanceServiceClientListByResourceGroupResponse

type OrchestratorInstanceServiceClientListByResourceGroupResponse struct {
	// An array of OrchestratorInstance resources.
	Orchestrators
}

OrchestratorInstanceServiceClientListByResourceGroupResponse contains the response from method OrchestratorInstanceServiceClient.NewListByResourceGroupPager.

type OrchestratorInstanceServiceClientListBySubscriptionOptions

type OrchestratorInstanceServiceClientListBySubscriptionOptions struct {
}

OrchestratorInstanceServiceClientListBySubscriptionOptions contains the optional parameters for the OrchestratorInstanceServiceClient.NewListBySubscriptionPager method.

type OrchestratorInstanceServiceClientListBySubscriptionResponse

type OrchestratorInstanceServiceClientListBySubscriptionResponse struct {
	// An array of OrchestratorInstance resources.
	Orchestrators
}

OrchestratorInstanceServiceClientListBySubscriptionResponse contains the response from method OrchestratorInstanceServiceClient.NewListBySubscriptionPager.

type OrchestratorInstanceServiceClientPatchOptions

type OrchestratorInstanceServiceClientPatchOptions struct {
}

OrchestratorInstanceServiceClientPatchOptions contains the optional parameters for the OrchestratorInstanceServiceClient.Patch method.

type OrchestratorInstanceServiceClientPatchResponse

type OrchestratorInstanceServiceClientPatchResponse struct {
	// Represents an instance of a orchestrator.
	Orchestrator
}

OrchestratorInstanceServiceClientPatchResponse contains the response from method OrchestratorInstanceServiceClient.Patch.

type OrchestratorInstanceState

type OrchestratorInstanceState string

OrchestratorInstanceState - The current state of orchestratorInstance resource.

const (
	OrchestratorInstanceStateDeleting     OrchestratorInstanceState = "Deleting"
	OrchestratorInstanceStateFailed       OrchestratorInstanceState = "Failed"
	OrchestratorInstanceStateProvisioning OrchestratorInstanceState = "Provisioning"
	OrchestratorInstanceStateSucceeded    OrchestratorInstanceState = "Succeeded"
)

func PossibleOrchestratorInstanceStateValues

func PossibleOrchestratorInstanceStateValues() []OrchestratorInstanceState

PossibleOrchestratorInstanceStateValues returns the possible values for the OrchestratorInstanceState const type.

type OrchestratorKind

type OrchestratorKind string

OrchestratorKind - The kind of workbook. Choices are user and shared.

const (
	OrchestratorKindKubernetes OrchestratorKind = "Kubernetes"
)

func PossibleOrchestratorKindValues

func PossibleOrchestratorKindValues() []OrchestratorKind

PossibleOrchestratorKindValues returns the possible values for the OrchestratorKind const type.

type OrchestratorResource

type OrchestratorResource struct {
	// REQUIRED; The kind of workbook. Choices are user and shared.
	Kind *OrchestratorKind

	// The identity of the orchestrator
	Identity *OrchestratorIdentity

	// Location of the resource.
	Location *string

	// The resource tags.
	Tags map[string]*string

	// READ-ONLY; An identifier that represents the resource.
	ID *string

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

	// READ-ONLY; The type of resource.
	Type *string
}

OrchestratorResource - Represents an instance of a resource.

func (OrchestratorResource) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type OrchestratorResource.

func (*OrchestratorResource) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type OrchestratorResource.

type OrchestratorResourceProperties

type OrchestratorResourceProperties struct {
	// REQUIRED; Properties of the controller.
	ControllerDetails *ControllerDetails

	// K8s APIServer url. Either one of apiServerEndpoint or privateLinkResourceId can be specified
	APIServerEndpoint *string

	// RootCA certificate of kubernetes cluster base64 encoded
	ClusterRootCA *string

	// AAD ID used with apiserver
	OrchestratorAppID *string

	// TenantID of server App ID
	OrchestratorTenantID *string

	// private link arm resource id. Either one of apiServerEndpoint or privateLinkResourceId can be specified
	PrivateLinkResourceID *string

	// READ-ONLY; The current state of orchestratorInstance resource.
	ProvisioningState *OrchestratorInstanceState

	// READ-ONLY; Resource guid.
	ResourceGUID *string
}

OrchestratorResourceProperties - Properties of orchestrator

func (OrchestratorResourceProperties) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type OrchestratorResourceProperties.

func (*OrchestratorResourceProperties) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type OrchestratorResourceProperties.

type OrchestratorResourceUpdateParameters

type OrchestratorResourceUpdateParameters struct {
	// The resource tags.
	Tags map[string]*string
}

OrchestratorResourceUpdateParameters - Parameters for updating a resource.

func (OrchestratorResourceUpdateParameters) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type OrchestratorResourceUpdateParameters.

func (*OrchestratorResourceUpdateParameters) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type OrchestratorResourceUpdateParameters.

type Orchestrators

type Orchestrators struct {
	// REQUIRED; An array of OrchestratorInstance resources.
	Value []*Orchestrator

	// READ-ONLY; The URL to get the next set of orchestrators.
	NextLink *string
}

Orchestrators - An array of OrchestratorInstance resources.

func (Orchestrators) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type Orchestrators.

func (*Orchestrators) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type Orchestrators.

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 ResourceIdentityType

type ResourceIdentityType string

ResourceIdentityType - The type of identity used for orchestrator cluster. Type 'SystemAssigned' will use an implicitly created identity orchestrator clusters

const (
	ResourceIdentityTypeNone           ResourceIdentityType = "None"
	ResourceIdentityTypeSystemAssigned ResourceIdentityType = "SystemAssigned"
)

func PossibleResourceIdentityTypeValues

func PossibleResourceIdentityTypeValues() []ResourceIdentityType

PossibleResourceIdentityTypeValues returns the possible values for the ResourceIdentityType const type.

type ResourceUpdateParameters

type ResourceUpdateParameters struct {
	// The resource tags.
	Tags map[string]*string
}

ResourceUpdateParameters - Parameters for updating a resource.

func (ResourceUpdateParameters) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type ResourceUpdateParameters.

func (*ResourceUpdateParameters) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type ResourceUpdateParameters.

type SubnetDetails

type SubnetDetails struct {
	// subnet arm resource id
	ID *string
}

SubnetDetails - Properties of orchestrator

func (SubnetDetails) MarshalJSON added in v1.1.0

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

MarshalJSON implements the json.Marshaller interface for type SubnetDetails.

func (*SubnetDetails) UnmarshalJSON added in v1.1.0

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

UnmarshalJSON implements the json.Unmarshaller interface for type SubnetDetails.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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