Documentation ¶
Index ¶
- type ActionType
- type AutoGeneratedDomainNameLabelScope
- type CreatedByType
- type ErrorAdditionalInfo
- type ErrorDetail
- type ErrorResponse
- type GrafanaClient
- func (client *GrafanaClient) BeginCreate(ctx context.Context, resourceGroupName string, workspaceName string, ...) (*runtime.Poller[GrafanaClientCreateResponse], error)
- func (client *GrafanaClient) BeginDelete(ctx context.Context, resourceGroupName string, workspaceName string, ...) (*runtime.Poller[GrafanaClientDeleteResponse], error)
- func (client *GrafanaClient) Get(ctx context.Context, resourceGroupName string, workspaceName string, ...) (GrafanaClientGetResponse, error)
- func (client *GrafanaClient) NewListByResourceGroupPager(resourceGroupName string, options *GrafanaClientListByResourceGroupOptions) *runtime.Pager[GrafanaClientListByResourceGroupResponse]
- func (client *GrafanaClient) NewListPager(options *GrafanaClientListOptions) *runtime.Pager[GrafanaClientListResponse]
- func (client *GrafanaClient) Update(ctx context.Context, resourceGroupName string, workspaceName string, ...) (GrafanaClientUpdateResponse, error)
- type GrafanaClientBeginCreateOptions
- type GrafanaClientBeginDeleteOptions
- type GrafanaClientCreateResponse
- type GrafanaClientDeleteResponse
- type GrafanaClientGetOptions
- type GrafanaClientGetResponse
- type GrafanaClientListByResourceGroupOptions
- type GrafanaClientListByResourceGroupResponse
- type GrafanaClientListOptions
- type GrafanaClientListResponse
- type GrafanaClientUpdateOptions
- type GrafanaClientUpdateResponse
- type IdentityType
- type LastModifiedByType
- type ManagedGrafana
- type ManagedGrafanaListResponse
- type ManagedGrafanaProperties
- type ManagedGrafanaUpdateParameters
- type ManagedIdentity
- type OperationDisplay
- type OperationListResult
- type OperationResult
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type Origin
- type ProvisioningState
- type ResourceSKU
- type SystemData
- type UserAssignedIdentity
- type ZoneRedundancy
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActionType ¶
type ActionType string
ActionType - 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 AutoGeneratedDomainNameLabelScope ¶
type AutoGeneratedDomainNameLabelScope string
const (
AutoGeneratedDomainNameLabelScopeTenantReuse AutoGeneratedDomainNameLabelScope = "TenantReuse"
)
func PossibleAutoGeneratedDomainNameLabelScopeValues ¶
func PossibleAutoGeneratedDomainNameLabelScopeValues() []AutoGeneratedDomainNameLabelScope
PossibleAutoGeneratedDomainNameLabelScopeValues returns the possible values for the AutoGeneratedDomainNameLabelScope const type.
type CreatedByType ¶
type CreatedByType string
CreatedByType - The type of identity that created the resource.
const ( CreatedByTypeApplication CreatedByType = "Application" CreatedByTypeKey CreatedByType = "Key" CreatedByTypeManagedIdentity CreatedByType = "ManagedIdentity" CreatedByTypeUser CreatedByType = "User" )
func PossibleCreatedByTypeValues ¶
func PossibleCreatedByTypeValues() []CreatedByType
PossibleCreatedByTypeValues returns the possible values for the CreatedByType const type.
type ErrorAdditionalInfo ¶
type ErrorAdditionalInfo struct { // READ-ONLY; The additional info. Info interface{} `json:"info,omitempty" azure:"ro"` // READ-ONLY; The additional info type. Type *string `json:"type,omitempty" azure:"ro"` }
ErrorAdditionalInfo - The resource management error additional info.
type ErrorDetail ¶
type ErrorDetail struct { // READ-ONLY; The error additional info. AdditionalInfo []*ErrorAdditionalInfo `json:"additionalInfo,omitempty" azure:"ro"` // READ-ONLY; The error code. Code *string `json:"code,omitempty" azure:"ro"` // READ-ONLY; The error details. Details []*ErrorDetail `json:"details,omitempty" azure:"ro"` // READ-ONLY; The error message. Message *string `json:"message,omitempty" azure:"ro"` // READ-ONLY; The error target. Target *string `json:"target,omitempty" azure:"ro"` }
ErrorDetail - The error detail.
type ErrorResponse ¶
type ErrorResponse struct { // The error object. Error *ErrorDetail `json:"error,omitempty"` }
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.).
type GrafanaClient ¶
type GrafanaClient struct {
// contains filtered or unexported fields
}
GrafanaClient contains the methods for the Grafana group. Don't use this type directly, use NewGrafanaClient() instead.
func NewGrafanaClient ¶
func NewGrafanaClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*GrafanaClient, error)
NewGrafanaClient creates a new instance of GrafanaClient with the specified values. subscriptionID - Gets subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*GrafanaClient) BeginCreate ¶
func (client *GrafanaClient) BeginCreate(ctx context.Context, resourceGroupName string, workspaceName string, requestBodyParameters ManagedGrafana, options *GrafanaClientBeginCreateOptions) (*runtime.Poller[GrafanaClientCreateResponse], error)
BeginCreate - Create or update a workspace for Grafana resource. This API is idempotent, so user can either create a new grafana or update an existing grafana. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-09-01-preview resourceGroupName - The name of the resource group. The name is case insensitive. workspaceName - The workspace name of Azure Managed Grafana. options - GrafanaClientBeginCreateOptions contains the optional parameters for the GrafanaClient.BeginCreate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/dashboard/resource-manager/Microsoft.Dashboard/preview/2021-09-01-preview/examples/Grafana_Create.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/dashboard/armdashboard" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armdashboard.NewGrafanaClient("00000000-0000-0000-0000-000000000000", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := client.BeginCreate(ctx, "myResourceGroup", "myWorkspace", armdashboard.ManagedGrafana{ Identity: &armdashboard.ManagedIdentity{ Type: to.Ptr(armdashboard.IdentityTypeSystemAssigned), }, Location: to.Ptr("West US"), Properties: &armdashboard.ManagedGrafanaProperties{ ProvisioningState: to.Ptr(armdashboard.ProvisioningStateAccepted), ZoneRedundancy: to.Ptr(armdashboard.ZoneRedundancyEnabled), }, SKU: &armdashboard.ResourceSKU{ Name: to.Ptr("Standard"), }, Tags: map[string]*string{ "Environment": to.Ptr("Dev"), }, }, 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) } // TODO: use response item _ = res }
Output:
func (*GrafanaClient) BeginDelete ¶
func (client *GrafanaClient) BeginDelete(ctx context.Context, resourceGroupName string, workspaceName string, options *GrafanaClientBeginDeleteOptions) (*runtime.Poller[GrafanaClientDeleteResponse], error)
BeginDelete - Delete a workspace for Grafana resource. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-09-01-preview resourceGroupName - The name of the resource group. The name is case insensitive. workspaceName - The workspace name of Azure Managed Grafana. options - GrafanaClientBeginDeleteOptions contains the optional parameters for the GrafanaClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/dashboard/resource-manager/Microsoft.Dashboard/preview/2021-09-01-preview/examples/Grafana_Delete.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/dashboard/armdashboard" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armdashboard.NewGrafanaClient("00000000-0000-0000-0000-000000000000", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := client.BeginDelete(ctx, "myResourceGroup", "myWorkspace", 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 (*GrafanaClient) Get ¶
func (client *GrafanaClient) Get(ctx context.Context, resourceGroupName string, workspaceName string, options *GrafanaClientGetOptions) (GrafanaClientGetResponse, error)
Get - Get the properties of a specific workspace for Grafana resource. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-09-01-preview resourceGroupName - The name of the resource group. The name is case insensitive. workspaceName - The workspace name of Azure Managed Grafana. options - GrafanaClientGetOptions contains the optional parameters for the GrafanaClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/dashboard/resource-manager/Microsoft.Dashboard/preview/2021-09-01-preview/examples/Grafana_Get.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/dashboard/armdashboard" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armdashboard.NewGrafanaClient("00000000-0000-0000-0000-000000000000", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := client.Get(ctx, "myResourceGroup", "myWorkspace", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // TODO: use response item _ = res }
Output:
func (*GrafanaClient) NewListByResourceGroupPager ¶ added in v0.2.0
func (client *GrafanaClient) NewListByResourceGroupPager(resourceGroupName string, options *GrafanaClientListByResourceGroupOptions) *runtime.Pager[GrafanaClientListByResourceGroupResponse]
NewListByResourceGroupPager - List all resources of workspaces for Grafana under the specified resource group. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-09-01-preview resourceGroupName - The name of the resource group. The name is case insensitive. options - GrafanaClientListByResourceGroupOptions contains the optional parameters for the GrafanaClient.ListByResourceGroup method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/dashboard/resource-manager/Microsoft.Dashboard/preview/2021-09-01-preview/examples/Grafana_ListByResourceGroup.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/dashboard/armdashboard" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armdashboard.NewGrafanaClient("00000000-0000-0000-0000-000000000000", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := client.NewListByResourceGroupPager("myResourceGroup", nil) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
func (*GrafanaClient) NewListPager ¶ added in v0.2.0
func (client *GrafanaClient) NewListPager(options *GrafanaClientListOptions) *runtime.Pager[GrafanaClientListResponse]
NewListPager - List all resources of workspaces for Grafana under the specified subscription. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-09-01-preview options - GrafanaClientListOptions contains the optional parameters for the GrafanaClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/dashboard/resource-manager/Microsoft.Dashboard/preview/2021-09-01-preview/examples/Grafana_List.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/dashboard/armdashboard" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armdashboard.NewGrafanaClient("00000000-0000-0000-0000-000000000000", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := client.NewListPager(nil) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
func (*GrafanaClient) Update ¶
func (client *GrafanaClient) Update(ctx context.Context, resourceGroupName string, workspaceName string, requestBodyParameters ManagedGrafanaUpdateParameters, options *GrafanaClientUpdateOptions) (GrafanaClientUpdateResponse, error)
Update - Update a workspace for Grafana resource. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-09-01-preview resourceGroupName - The name of the resource group. The name is case insensitive. workspaceName - The workspace name of Azure Managed Grafana. options - GrafanaClientUpdateOptions contains the optional parameters for the GrafanaClient.Update method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/dashboard/resource-manager/Microsoft.Dashboard/preview/2021-09-01-preview/examples/Grafana_Update.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/dashboard/armdashboard" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armdashboard.NewGrafanaClient("00000000-0000-0000-0000-000000000000", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := client.Update(ctx, "myResourceGroup", "myWorkspace", armdashboard.ManagedGrafanaUpdateParameters{ Tags: map[string]*string{ "Environment": to.Ptr("Dev 2"), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // TODO: use response item _ = res }
Output:
type GrafanaClientBeginCreateOptions ¶
type GrafanaClientBeginCreateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
GrafanaClientBeginCreateOptions contains the optional parameters for the GrafanaClient.BeginCreate method.
type GrafanaClientBeginDeleteOptions ¶
type GrafanaClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
GrafanaClientBeginDeleteOptions contains the optional parameters for the GrafanaClient.BeginDelete method.
type GrafanaClientCreateResponse ¶
type GrafanaClientCreateResponse struct {
ManagedGrafana
}
GrafanaClientCreateResponse contains the response from method GrafanaClient.Create.
type GrafanaClientDeleteResponse ¶
type GrafanaClientDeleteResponse struct { }
GrafanaClientDeleteResponse contains the response from method GrafanaClient.Delete.
type GrafanaClientGetOptions ¶
type GrafanaClientGetOptions struct { }
GrafanaClientGetOptions contains the optional parameters for the GrafanaClient.Get method.
type GrafanaClientGetResponse ¶
type GrafanaClientGetResponse struct {
ManagedGrafana
}
GrafanaClientGetResponse contains the response from method GrafanaClient.Get.
type GrafanaClientListByResourceGroupOptions ¶
type GrafanaClientListByResourceGroupOptions struct { }
GrafanaClientListByResourceGroupOptions contains the optional parameters for the GrafanaClient.ListByResourceGroup method.
type GrafanaClientListByResourceGroupResponse ¶
type GrafanaClientListByResourceGroupResponse struct {
ManagedGrafanaListResponse
}
GrafanaClientListByResourceGroupResponse contains the response from method GrafanaClient.ListByResourceGroup.
type GrafanaClientListOptions ¶
type GrafanaClientListOptions struct { }
GrafanaClientListOptions contains the optional parameters for the GrafanaClient.List method.
type GrafanaClientListResponse ¶
type GrafanaClientListResponse struct {
ManagedGrafanaListResponse
}
GrafanaClientListResponse contains the response from method GrafanaClient.List.
type GrafanaClientUpdateOptions ¶
type GrafanaClientUpdateOptions struct { }
GrafanaClientUpdateOptions contains the optional parameters for the GrafanaClient.Update method.
type GrafanaClientUpdateResponse ¶
type GrafanaClientUpdateResponse struct {
ManagedGrafana
}
GrafanaClientUpdateResponse contains the response from method GrafanaClient.Update.
type IdentityType ¶
type IdentityType string
IdentityType - The type 'SystemAssigned, UserAssigned' includes both an implicitly created identity and a set of user assigned identities. The type 'None' will remove any identities from the resource.
const ( IdentityTypeNone IdentityType = "None" IdentityTypeSystemAssigned IdentityType = "SystemAssigned" )
func PossibleIdentityTypeValues ¶
func PossibleIdentityTypeValues() []IdentityType
PossibleIdentityTypeValues returns the possible values for the IdentityType const type.
type LastModifiedByType ¶
type LastModifiedByType string
const ( LastModifiedByTypeApplication LastModifiedByType = "Application" LastModifiedByTypeKey LastModifiedByType = "Key" LastModifiedByTypeManagedIdentity LastModifiedByType = "ManagedIdentity" LastModifiedByTypeUser LastModifiedByType = "User" )
func PossibleLastModifiedByTypeValues ¶
func PossibleLastModifiedByTypeValues() []LastModifiedByType
PossibleLastModifiedByTypeValues returns the possible values for the LastModifiedByType const type.
type ManagedGrafana ¶
type ManagedGrafana struct { // The managed identity of the grafana resource. Identity *ManagedIdentity `json:"identity,omitempty"` // The geo-location where the grafana resource lives Location *string `json:"location,omitempty"` // Properties specific to the grafana resource. Properties *ManagedGrafanaProperties `json:"properties,omitempty"` // The Sku of the grafana resource. SKU *ResourceSKU `json:"sku,omitempty"` // The tags for grafana resource. Tags map[string]*string `json:"tags,omitempty"` // READ-ONLY; ARM id of the grafana resource ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; Name of the grafana resource. Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The system meta data relating to this grafana resource. SystemData *SystemData `json:"systemData,omitempty" azure:"ro"` // READ-ONLY; The type of the grafana resource. Type *string `json:"type,omitempty" azure:"ro"` }
ManagedGrafana - The grafana resource type.
func (ManagedGrafana) MarshalJSON ¶
func (m ManagedGrafana) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagedGrafana.
type ManagedGrafanaListResponse ¶
type ManagedGrafanaListResponse struct { NextLink *string `json:"nextLink,omitempty"` Value []*ManagedGrafana `json:"value,omitempty"` }
type ManagedGrafanaProperties ¶
type ManagedGrafanaProperties struct { AutoGeneratedDomainNameLabelScope *AutoGeneratedDomainNameLabelScope `json:"autoGeneratedDomainNameLabelScope,omitempty"` // Provisioning state of the resource. ProvisioningState *ProvisioningState `json:"provisioningState,omitempty"` ZoneRedundancy *ZoneRedundancy `json:"zoneRedundancy,omitempty"` // READ-ONLY; The endpoint of the Grafana instance. Endpoint *string `json:"endpoint,omitempty" azure:"ro"` // READ-ONLY; The Grafana software version. GrafanaVersion *string `json:"grafanaVersion,omitempty" azure:"ro"` }
ManagedGrafanaProperties - Properties specific to the grafana resource.
type ManagedGrafanaUpdateParameters ¶
type ManagedGrafanaUpdateParameters struct { // The managed identity of the grafana resource. Identity *ManagedIdentity `json:"identity,omitempty"` // The new tags of the grafana resource. Tags map[string]*string `json:"tags,omitempty"` }
ManagedGrafanaUpdateParameters - The parameters for a PATCH request to a grafana resource.
func (ManagedGrafanaUpdateParameters) MarshalJSON ¶
func (m ManagedGrafanaUpdateParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagedGrafanaUpdateParameters.
type ManagedIdentity ¶
type ManagedIdentity struct { // The type 'SystemAssigned, UserAssigned' includes both an implicitly created identity and a set of user assigned identities. // The type 'None' will remove any identities from the resource. Type *IdentityType `json:"type,omitempty"` // Dictionary of user assigned identities. UserAssignedIdentities map[string]*UserAssignedIdentity `json:"userAssignedIdentities,omitempty"` // READ-ONLY; The principal id of the system assigned identity. PrincipalID *string `json:"principalId,omitempty" azure:"ro"` // READ-ONLY; The tenant id of the system assigned identity. TenantID *string `json:"tenantId,omitempty" azure:"ro"` }
ManagedIdentity - The managed identity of a resource.
func (ManagedIdentity) MarshalJSON ¶
func (m ManagedIdentity) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagedIdentity.
type OperationDisplay ¶
type OperationDisplay struct { // READ-ONLY; Description of the operation, e.g., 'Read grafana'. Description *string `json:"description,omitempty" azure:"ro"` // READ-ONLY; Operation type, e.g., read, write, delete, etc. Operation *string `json:"operation,omitempty" azure:"ro"` // READ-ONLY; The localized friendly form of the resource provider name, i.e., Microsoft.Dashboard. Provider *string `json:"provider,omitempty" azure:"ro"` // READ-ONLY; The localized friendly name of the resource type related to this operation, e.g., 'grafana'. Resource *string `json:"resource,omitempty" azure:"ro"` }
OperationDisplay - Localized display information for this particular operation.
type OperationListResult ¶
type OperationListResult struct { // READ-ONLY; URL to get the next set of operation list results if there are any. NextLink *string `json:"nextLink,omitempty" azure:"ro"` // READ-ONLY; List of operations supported by the Microsoft.Dashboard provider. Value []*OperationResult `json:"value,omitempty" azure:"ro"` }
OperationListResult - A list of REST API operations supported by Microsoft.Dashboard provider. It contains an URL link to get the next set of results.
type OperationResult ¶
type OperationResult struct { // Localized display information for this particular operation. Display *OperationDisplay `json:"display,omitempty"` // READ-ONLY; Indicates the action type. "Internal" refers to actions that are for internal only APIs. ActionType *ActionType `json:"actionType,omitempty" azure:"ro"` // READ-ONLY; Indicates whether the operation applies to data-plane. Set "true" for data-plane operations and "false" for // ARM/control-plane operations. IsDataAction *bool `json:"isDataAction,omitempty" azure:"ro"` // READ-ONLY; Operation name, i.e., {provider}/{resource}/{operation}. Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The intended executor of the operation. Origin *Origin `json:"origin,omitempty" azure:"ro"` }
OperationResult - A Microsoft.Dashboard REST API operation.
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 ¶ added in v0.2.0
func (client *OperationsClient) NewListPager(options *OperationsClientListOptions) *runtime.Pager[OperationsClientListResponse]
NewListPager - List all available API operations provided by Microsoft.Dashboard. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-09-01-preview options - OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/dashboard/resource-manager/Microsoft.Dashboard/preview/2021-09-01-preview/examples/Operations_List.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/dashboard/armdashboard" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armdashboard.NewOperationsClient(cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := client.NewListPager(nil) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
type OperationsClientListOptions ¶
type OperationsClientListOptions struct { }
OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
type OperationsClientListResponse ¶
type OperationsClientListResponse struct {
OperationListResult
}
OperationsClientListResponse contains the response from method OperationsClient.List.
type Origin ¶
type Origin string
Origin - The intended executor of the operation.
func PossibleOriginValues ¶
func PossibleOriginValues() []Origin
PossibleOriginValues returns the possible values for the Origin const type.
type ProvisioningState ¶
type ProvisioningState string
const ( ProvisioningStateAccepted ProvisioningState = "Accepted" ProvisioningStateCanceled ProvisioningState = "Canceled" ProvisioningStateCreating ProvisioningState = "Creating" ProvisioningStateDeleted ProvisioningState = "Deleted" ProvisioningStateDeleting ProvisioningState = "Deleting" ProvisioningStateFailed ProvisioningState = "Failed" ProvisioningStateNotSpecified ProvisioningState = "NotSpecified" ProvisioningStateSucceeded ProvisioningState = "Succeeded" ProvisioningStateUpdating ProvisioningState = "Updating" )
func PossibleProvisioningStateValues ¶
func PossibleProvisioningStateValues() []ProvisioningState
PossibleProvisioningStateValues returns the possible values for the ProvisioningState const type.
type ResourceSKU ¶
type ResourceSKU struct { // REQUIRED Name *string `json:"name,omitempty"` }
type SystemData ¶
type SystemData struct { CreatedAt *time.Time `json:"createdAt,omitempty"` CreatedBy *string `json:"createdBy,omitempty"` // The type of identity that created the resource. CreatedByType *CreatedByType `json:"createdByType,omitempty"` LastModifiedAt *time.Time `json:"lastModifiedAt,omitempty"` LastModifiedBy *string `json:"lastModifiedBy,omitempty"` LastModifiedByType *LastModifiedByType `json:"lastModifiedByType,omitempty"` }
func (SystemData) MarshalJSON ¶
func (s SystemData) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SystemData.
func (*SystemData) UnmarshalJSON ¶
func (s *SystemData) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type SystemData.
type UserAssignedIdentity ¶
type ZoneRedundancy ¶
type ZoneRedundancy string
const ( ZoneRedundancyDisabled ZoneRedundancy = "Disabled" ZoneRedundancyEnabled ZoneRedundancy = "Enabled" )
func PossibleZoneRedundancyValues ¶
func PossibleZoneRedundancyValues() []ZoneRedundancy
PossibleZoneRedundancyValues returns the possible values for the ZoneRedundancy const type.