actions

package
v0.20221207.1121859 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2022 License: MPL-2.0 Imports: 9 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/securityinsights/2021-09-01-preview/actions Documentation

The actions SDK allows for interaction with the Azure Resource Manager Service securityinsights (API Version 2021-09-01-preview).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/securityinsights/2021-09-01-preview/actions"

Client Initialization

client := actions.NewActionsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ActionsClient.CreateOrUpdate

ctx := context.TODO()
id := actions.NewActionID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue", "ruleIdValue", "actionIdValue")

payload := actions.ActionRequest{
	// ...
}


read, err := client.CreateOrUpdate(ctx, id, payload)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ActionsClient.Delete

ctx := context.TODO()
id := actions.NewActionID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue", "ruleIdValue", "actionIdValue")

read, err := client.Delete(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ActionsClient.Get

ctx := context.TODO()
id := actions.NewActionID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue", "ruleIdValue", "actionIdValue")

read, err := client.Get(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ActionsClient.ListByAlertRule

ctx := context.TODO()
id := actions.NewAlertRuleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue", "ruleIdValue")

// alternatively `client.ListByAlertRule(ctx, id)` can be used to do batched pagination
items, err := client.ListByAlertRuleComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ValidateActionID

func ValidateActionID(input interface{}, key string) (warnings []string, errors []error)

ValidateActionID checks that 'input' can be parsed as a Action ID

func ValidateAlertRuleID

func ValidateAlertRuleID(input interface{}, key string) (warnings []string, errors []error)

ValidateAlertRuleID checks that 'input' can be parsed as a Alert Rule ID

Types

type ActionId

type ActionId struct {
	SubscriptionId    string
	ResourceGroupName string
	WorkspaceName     string
	RuleId            string
	ActionId          string
}

ActionId is a struct representing the Resource ID for a Action

func NewActionID

func NewActionID(subscriptionId string, resourceGroupName string, workspaceName string, ruleId string, actionId string) ActionId

NewActionID returns a new ActionId struct

func ParseActionID

func ParseActionID(input string) (*ActionId, error)

ParseActionID parses 'input' into a ActionId

func ParseActionIDInsensitively

func ParseActionIDInsensitively(input string) (*ActionId, error)

ParseActionIDInsensitively parses 'input' case-insensitively into a ActionId note: this method should only be used for API response data and not user input

func (ActionId) ID

func (id ActionId) ID() string

ID returns the formatted Action ID

func (ActionId) Segments

func (id ActionId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Action ID

func (ActionId) String

func (id ActionId) String() string

String returns a human-readable description of this Action ID

type ActionRequest

type ActionRequest struct {
	Etag       *string                  `json:"etag,omitempty"`
	Id         *string                  `json:"id,omitempty"`
	Name       *string                  `json:"name,omitempty"`
	Properties *ActionRequestProperties `json:"properties,omitempty"`
	SystemData *systemdata.SystemData   `json:"systemData,omitempty"`
	Type       *string                  `json:"type,omitempty"`
}

type ActionRequestProperties

type ActionRequestProperties struct {
	LogicAppResourceId string `json:"logicAppResourceId"`
	TriggerUri         string `json:"triggerUri"`
}

type ActionResponse

type ActionResponse struct {
	Etag       *string                   `json:"etag,omitempty"`
	Id         *string                   `json:"id,omitempty"`
	Name       *string                   `json:"name,omitempty"`
	Properties *ActionResponseProperties `json:"properties,omitempty"`
	SystemData *systemdata.SystemData    `json:"systemData,omitempty"`
	Type       *string                   `json:"type,omitempty"`
}

type ActionResponseOperationPredicate

type ActionResponseOperationPredicate struct {
	Etag *string
	Id   *string
	Name *string
	Type *string
}

func (ActionResponseOperationPredicate) Matches

type ActionResponseProperties

type ActionResponseProperties struct {
	LogicAppResourceId string  `json:"logicAppResourceId"`
	WorkflowId         *string `json:"workflowId,omitempty"`
}

type ActionsClient

type ActionsClient struct {
	Client autorest.Client
	// contains filtered or unexported fields
}

func NewActionsClientWithBaseURI

func NewActionsClientWithBaseURI(endpoint string) ActionsClient

func (ActionsClient) CreateOrUpdate

func (c ActionsClient) CreateOrUpdate(ctx context.Context, id ActionId, input ActionRequest) (result CreateOrUpdateOperationResponse, err error)

CreateOrUpdate ...

func (ActionsClient) Delete

func (c ActionsClient) Delete(ctx context.Context, id ActionId) (result DeleteOperationResponse, err error)

Delete ...

func (ActionsClient) Get

func (c ActionsClient) Get(ctx context.Context, id ActionId) (result GetOperationResponse, err error)

Get ...

func (ActionsClient) ListByAlertRule

func (c ActionsClient) ListByAlertRule(ctx context.Context, id AlertRuleId) (resp ListByAlertRuleOperationResponse, err error)

ListByAlertRule ...

func (ActionsClient) ListByAlertRuleComplete

func (c ActionsClient) ListByAlertRuleComplete(ctx context.Context, id AlertRuleId) (ListByAlertRuleCompleteResult, error)

ListByAlertRuleComplete retrieves all of the results into a single object

func (ActionsClient) ListByAlertRuleCompleteMatchingPredicate

func (c ActionsClient) ListByAlertRuleCompleteMatchingPredicate(ctx context.Context, id AlertRuleId, predicate ActionResponseOperationPredicate) (resp ListByAlertRuleCompleteResult, err error)

ListByAlertRuleCompleteMatchingPredicate retrieves all of the results and then applied the predicate

type AlertRuleId

type AlertRuleId struct {
	SubscriptionId    string
	ResourceGroupName string
	WorkspaceName     string
	RuleId            string
}

AlertRuleId is a struct representing the Resource ID for a Alert Rule

func NewAlertRuleID

func NewAlertRuleID(subscriptionId string, resourceGroupName string, workspaceName string, ruleId string) AlertRuleId

NewAlertRuleID returns a new AlertRuleId struct

func ParseAlertRuleID

func ParseAlertRuleID(input string) (*AlertRuleId, error)

ParseAlertRuleID parses 'input' into a AlertRuleId

func ParseAlertRuleIDInsensitively

func ParseAlertRuleIDInsensitively(input string) (*AlertRuleId, error)

ParseAlertRuleIDInsensitively parses 'input' case-insensitively into a AlertRuleId note: this method should only be used for API response data and not user input

func (AlertRuleId) ID

func (id AlertRuleId) ID() string

ID returns the formatted Alert Rule ID

func (AlertRuleId) Segments

func (id AlertRuleId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Alert Rule ID

func (AlertRuleId) String

func (id AlertRuleId) String() string

String returns a human-readable description of this Alert Rule ID

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	Model        *ActionResponse
}

type DeleteOperationResponse

type DeleteOperationResponse struct {
	HttpResponse *http.Response
}

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	Model        *ActionResponse
}

type ListByAlertRuleCompleteResult

type ListByAlertRuleCompleteResult struct {
	Items []ActionResponse
}

type ListByAlertRuleOperationResponse

type ListByAlertRuleOperationResponse struct {
	HttpResponse *http.Response
	Model        *[]ActionResponse
	// contains filtered or unexported fields
}

func (ListByAlertRuleOperationResponse) HasMore

func (ListByAlertRuleOperationResponse) LoadMore

Jump to

Keyboard shortcuts

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