workbooksapis

package
v0.20240527.1094340 Latest Latest
Warning

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

Go to latest
Published: May 27, 2024 License: MPL-2.0 Imports: 16 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/applicationinsights/2022-04-01/workbooksapis Documentation

The workbooksapis SDK allows for interaction with the Azure Resource Manager Service applicationinsights (API Version 2022-04-01).

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-helpers/resourcemanager/commonids"
import "github.com/hashicorp/go-azure-sdk/resource-manager/applicationinsights/2022-04-01/workbooksapis"

Client Initialization

client := workbooksapis.NewWorkbooksAPIsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: WorkbooksAPIsClient.WorkbooksCreateOrUpdate

ctx := context.TODO()
id := workbooksapis.NewWorkbookID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workbookValue")

payload := workbooksapis.Workbook{
	// ...
}


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

Example Usage: WorkbooksAPIsClient.WorkbooksDelete

ctx := context.TODO()
id := workbooksapis.NewWorkbookID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workbookValue")

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

Example Usage: WorkbooksAPIsClient.WorkbooksGet

ctx := context.TODO()
id := workbooksapis.NewWorkbookID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workbookValue")

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

Example Usage: WorkbooksAPIsClient.WorkbooksListByResourceGroup

ctx := context.TODO()
id := commonids.NewResourceGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group")

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

Example Usage: WorkbooksAPIsClient.WorkbooksListBySubscription

ctx := context.TODO()
id := commonids.NewSubscriptionID("12345678-1234-9876-4563-123456789012")

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

Example Usage: WorkbooksAPIsClient.WorkbooksRevisionGet

ctx := context.TODO()
id := workbooksapis.NewRevisionID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workbookValue", "revisionIdValue")

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

Example Usage: WorkbooksAPIsClient.WorkbooksRevisionsList

ctx := context.TODO()
id := workbooksapis.NewWorkbookID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workbookValue")

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

Example Usage: WorkbooksAPIsClient.WorkbooksUpdate

ctx := context.TODO()
id := workbooksapis.NewWorkbookID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workbookValue")

payload := workbooksapis.WorkbookUpdateParameters{
	// ...
}


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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForCategoryType

func PossibleValuesForCategoryType() []string

func PossibleValuesForWorkbookSharedTypeKind

func PossibleValuesForWorkbookSharedTypeKind() []string

func PossibleValuesForWorkbookUpdateSharedTypeKind

func PossibleValuesForWorkbookUpdateSharedTypeKind() []string

func ValidateRevisionID

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

ValidateRevisionID checks that 'input' can be parsed as a Revision ID

func ValidateWorkbookID

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

ValidateWorkbookID checks that 'input' can be parsed as a Workbook ID

Types

type CategoryType

type CategoryType string
const (
	CategoryTypePerformance CategoryType = "performance"
	CategoryTypeRetention   CategoryType = "retention"
	CategoryTypeTSG         CategoryType = "TSG"
	CategoryTypeWorkbook    CategoryType = "workbook"
)

func (*CategoryType) UnmarshalJSON

func (s *CategoryType) UnmarshalJSON(bytes []byte) error

type RevisionId

type RevisionId struct {
	SubscriptionId    string
	ResourceGroupName string
	WorkbookName      string
	RevisionId        string
}

RevisionId is a struct representing the Resource ID for a Revision

func NewRevisionID

func NewRevisionID(subscriptionId string, resourceGroupName string, workbookName string, revisionId string) RevisionId

NewRevisionID returns a new RevisionId struct

func ParseRevisionID

func ParseRevisionID(input string) (*RevisionId, error)

ParseRevisionID parses 'input' into a RevisionId

func ParseRevisionIDInsensitively

func ParseRevisionIDInsensitively(input string) (*RevisionId, error)

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

func (*RevisionId) FromParseResult

func (id *RevisionId) FromParseResult(input resourceids.ParseResult) error

func (RevisionId) ID

func (id RevisionId) ID() string

ID returns the formatted Revision ID

func (RevisionId) Segments

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

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

func (RevisionId) String

func (id RevisionId) String() string

String returns a human-readable description of this Revision ID

type Workbook

type Workbook struct {
	Etag       *string                                  `json:"etag,omitempty"`
	Id         *string                                  `json:"id,omitempty"`
	Identity   *identity.LegacySystemAndUserAssignedMap `json:"identity,omitempty"`
	Kind       *WorkbookSharedTypeKind                  `json:"kind,omitempty"`
	Location   string                                   `json:"location"`
	Name       *string                                  `json:"name,omitempty"`
	Properties *WorkbookProperties                      `json:"properties,omitempty"`
	SystemData *systemdata.SystemData                   `json:"systemData,omitempty"`
	Tags       *map[string]string                       `json:"tags,omitempty"`
	Type       *string                                  `json:"type,omitempty"`
}

type WorkbookId

type WorkbookId struct {
	SubscriptionId    string
	ResourceGroupName string
	WorkbookName      string
}

WorkbookId is a struct representing the Resource ID for a Workbook

func NewWorkbookID

func NewWorkbookID(subscriptionId string, resourceGroupName string, workbookName string) WorkbookId

NewWorkbookID returns a new WorkbookId struct

func ParseWorkbookID

func ParseWorkbookID(input string) (*WorkbookId, error)

ParseWorkbookID parses 'input' into a WorkbookId

func ParseWorkbookIDInsensitively

func ParseWorkbookIDInsensitively(input string) (*WorkbookId, error)

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

func (*WorkbookId) FromParseResult

func (id *WorkbookId) FromParseResult(input resourceids.ParseResult) error

func (WorkbookId) ID

func (id WorkbookId) ID() string

ID returns the formatted Workbook ID

func (WorkbookId) Segments

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

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

func (WorkbookId) String

func (id WorkbookId) String() string

String returns a human-readable description of this Workbook ID

type WorkbookOperationPredicate

type WorkbookOperationPredicate struct {
	Etag     *string
	Id       *string
	Location *string
	Name     *string
	Type     *string
}

func (WorkbookOperationPredicate) Matches

func (p WorkbookOperationPredicate) Matches(input Workbook) bool

type WorkbookProperties

type WorkbookProperties struct {
	Category       string    `json:"category"`
	Description    *string   `json:"description,omitempty"`
	DisplayName    string    `json:"displayName"`
	Revision       *string   `json:"revision,omitempty"`
	SerializedData string    `json:"serializedData"`
	SourceId       *string   `json:"sourceId,omitempty"`
	StorageUri     *string   `json:"storageUri,omitempty"`
	Tags           *[]string `json:"tags,omitempty"`
	TimeModified   *string   `json:"timeModified,omitempty"`
	UserId         *string   `json:"userId,omitempty"`
	Version        *string   `json:"version,omitempty"`
}

func (*WorkbookProperties) GetTimeModifiedAsTime

func (o *WorkbookProperties) GetTimeModifiedAsTime() (*time.Time, error)

func (*WorkbookProperties) SetTimeModifiedAsTime

func (o *WorkbookProperties) SetTimeModifiedAsTime(input time.Time)

type WorkbookPropertiesUpdateParameters

type WorkbookPropertiesUpdateParameters struct {
	Category       *string   `json:"category,omitempty"`
	Description    *string   `json:"description,omitempty"`
	DisplayName    *string   `json:"displayName,omitempty"`
	Revision       *string   `json:"revision,omitempty"`
	SerializedData *string   `json:"serializedData,omitempty"`
	Tags           *[]string `json:"tags,omitempty"`
}

type WorkbookSharedTypeKind

type WorkbookSharedTypeKind string
const (
	WorkbookSharedTypeKindShared WorkbookSharedTypeKind = "shared"
)

func (*WorkbookSharedTypeKind) UnmarshalJSON

func (s *WorkbookSharedTypeKind) UnmarshalJSON(bytes []byte) error

type WorkbookUpdateParameters

type WorkbookUpdateParameters struct {
	Kind       *WorkbookUpdateSharedTypeKind       `json:"kind,omitempty"`
	Properties *WorkbookPropertiesUpdateParameters `json:"properties,omitempty"`
	Tags       *map[string]string                  `json:"tags,omitempty"`
}

type WorkbookUpdateSharedTypeKind

type WorkbookUpdateSharedTypeKind string
const (
	WorkbookUpdateSharedTypeKindShared WorkbookUpdateSharedTypeKind = "shared"
)

func (*WorkbookUpdateSharedTypeKind) UnmarshalJSON

func (s *WorkbookUpdateSharedTypeKind) UnmarshalJSON(bytes []byte) error

type WorkbooksAPIsClient

type WorkbooksAPIsClient struct {
	Client *resourcemanager.Client
}

func NewWorkbooksAPIsClientWithBaseURI

func NewWorkbooksAPIsClientWithBaseURI(sdkApi sdkEnv.Api) (*WorkbooksAPIsClient, error)

func (WorkbooksAPIsClient) WorkbooksCreateOrUpdate

WorkbooksCreateOrUpdate ...

func (WorkbooksAPIsClient) WorkbooksDelete

func (c WorkbooksAPIsClient) WorkbooksDelete(ctx context.Context, id WorkbookId) (result WorkbooksDeleteOperationResponse, err error)

WorkbooksDelete ...

func (WorkbooksAPIsClient) WorkbooksGet

WorkbooksGet ...

func (WorkbooksAPIsClient) WorkbooksListByResourceGroup

WorkbooksListByResourceGroup ...

func (WorkbooksAPIsClient) WorkbooksListByResourceGroupComplete

WorkbooksListByResourceGroupComplete retrieves all the results into a single object

func (WorkbooksAPIsClient) WorkbooksListByResourceGroupCompleteMatchingPredicate

func (c WorkbooksAPIsClient) WorkbooksListByResourceGroupCompleteMatchingPredicate(ctx context.Context, id commonids.ResourceGroupId, options WorkbooksListByResourceGroupOperationOptions, predicate WorkbookOperationPredicate) (result WorkbooksListByResourceGroupCompleteResult, err error)

WorkbooksListByResourceGroupCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (WorkbooksAPIsClient) WorkbooksListBySubscription

WorkbooksListBySubscription ...

func (WorkbooksAPIsClient) WorkbooksListBySubscriptionComplete

WorkbooksListBySubscriptionComplete retrieves all the results into a single object

func (WorkbooksAPIsClient) WorkbooksListBySubscriptionCompleteMatchingPredicate

func (c WorkbooksAPIsClient) WorkbooksListBySubscriptionCompleteMatchingPredicate(ctx context.Context, id commonids.SubscriptionId, options WorkbooksListBySubscriptionOperationOptions, predicate WorkbookOperationPredicate) (result WorkbooksListBySubscriptionCompleteResult, err error)

WorkbooksListBySubscriptionCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (WorkbooksAPIsClient) WorkbooksRevisionGet

func (c WorkbooksAPIsClient) WorkbooksRevisionGet(ctx context.Context, id RevisionId) (result WorkbooksRevisionGetOperationResponse, err error)

WorkbooksRevisionGet ...

func (WorkbooksAPIsClient) WorkbooksRevisionsList

func (c WorkbooksAPIsClient) WorkbooksRevisionsList(ctx context.Context, id WorkbookId) (result WorkbooksRevisionsListOperationResponse, err error)

WorkbooksRevisionsList ...

func (WorkbooksAPIsClient) WorkbooksRevisionsListComplete

func (c WorkbooksAPIsClient) WorkbooksRevisionsListComplete(ctx context.Context, id WorkbookId) (WorkbooksRevisionsListCompleteResult, error)

WorkbooksRevisionsListComplete retrieves all the results into a single object

func (WorkbooksAPIsClient) WorkbooksRevisionsListCompleteMatchingPredicate

func (c WorkbooksAPIsClient) WorkbooksRevisionsListCompleteMatchingPredicate(ctx context.Context, id WorkbookId, predicate WorkbookOperationPredicate) (result WorkbooksRevisionsListCompleteResult, err error)

WorkbooksRevisionsListCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (WorkbooksAPIsClient) WorkbooksUpdate

WorkbooksUpdate ...

type WorkbooksCreateOrUpdateOperationOptions

type WorkbooksCreateOrUpdateOperationOptions struct {
	SourceId *string
}

func DefaultWorkbooksCreateOrUpdateOperationOptions

func DefaultWorkbooksCreateOrUpdateOperationOptions() WorkbooksCreateOrUpdateOperationOptions

func (WorkbooksCreateOrUpdateOperationOptions) ToHeaders

func (WorkbooksCreateOrUpdateOperationOptions) ToOData

func (WorkbooksCreateOrUpdateOperationOptions) ToQuery

type WorkbooksCreateOrUpdateOperationResponse

type WorkbooksCreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *Workbook
}

type WorkbooksDeleteOperationResponse

type WorkbooksDeleteOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
}

type WorkbooksGetOperationOptions

type WorkbooksGetOperationOptions struct {
	CanFetchContent *bool
}

func DefaultWorkbooksGetOperationOptions

func DefaultWorkbooksGetOperationOptions() WorkbooksGetOperationOptions

func (WorkbooksGetOperationOptions) ToHeaders

func (WorkbooksGetOperationOptions) ToOData

func (WorkbooksGetOperationOptions) ToQuery

type WorkbooksGetOperationResponse

type WorkbooksGetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *Workbook
}

type WorkbooksListByResourceGroupCompleteResult

type WorkbooksListByResourceGroupCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []Workbook
}

type WorkbooksListByResourceGroupOperationOptions

type WorkbooksListByResourceGroupOperationOptions struct {
	CanFetchContent *bool
	Category        *CategoryType
	SourceId        *string
	Tags            *string
}

func DefaultWorkbooksListByResourceGroupOperationOptions

func DefaultWorkbooksListByResourceGroupOperationOptions() WorkbooksListByResourceGroupOperationOptions

func (WorkbooksListByResourceGroupOperationOptions) ToHeaders

func (WorkbooksListByResourceGroupOperationOptions) ToOData

func (WorkbooksListByResourceGroupOperationOptions) ToQuery

type WorkbooksListByResourceGroupOperationResponse

type WorkbooksListByResourceGroupOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Workbook
}

type WorkbooksListBySubscriptionCompleteResult

type WorkbooksListBySubscriptionCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []Workbook
}

type WorkbooksListBySubscriptionOperationOptions

type WorkbooksListBySubscriptionOperationOptions struct {
	CanFetchContent *bool
	Category        *CategoryType
	Tags            *string
}

func DefaultWorkbooksListBySubscriptionOperationOptions

func DefaultWorkbooksListBySubscriptionOperationOptions() WorkbooksListBySubscriptionOperationOptions

func (WorkbooksListBySubscriptionOperationOptions) ToHeaders

func (WorkbooksListBySubscriptionOperationOptions) ToOData

func (WorkbooksListBySubscriptionOperationOptions) ToQuery

type WorkbooksListBySubscriptionOperationResponse

type WorkbooksListBySubscriptionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Workbook
}

type WorkbooksRevisionGetOperationResponse

type WorkbooksRevisionGetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *Workbook
}

type WorkbooksRevisionsListCompleteResult

type WorkbooksRevisionsListCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []Workbook
}

type WorkbooksRevisionsListOperationResponse

type WorkbooksRevisionsListOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Workbook
}

type WorkbooksUpdateOperationOptions

type WorkbooksUpdateOperationOptions struct {
	SourceId *string
}

func DefaultWorkbooksUpdateOperationOptions

func DefaultWorkbooksUpdateOperationOptions() WorkbooksUpdateOperationOptions

func (WorkbooksUpdateOperationOptions) ToHeaders

func (WorkbooksUpdateOperationOptions) ToOData

func (WorkbooksUpdateOperationOptions) ToQuery

type WorkbooksUpdateOperationResponse

type WorkbooksUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *Workbook
}

Jump to

Keyboard shortcuts

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