apiissue

package
v0.20231214.1134755 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2023 License: MPL-2.0 Imports: 12 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/apimanagement/2022-08-01/apiissue Documentation

The apiissue SDK allows for interaction with the Azure Resource Manager Service apimanagement (API Version 2022-08-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-sdk/resource-manager/apimanagement/2022-08-01/apiissue"

Client Initialization

client := apiissue.NewApiIssueClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ApiIssueClient.CreateOrUpdate

ctx := context.TODO()
id := apiissue.NewApiIssueID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "apiIdValue", "issueIdValue")

payload := apiissue.IssueContract{
	// ...
}


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

Example Usage: ApiIssueClient.Delete

ctx := context.TODO()
id := apiissue.NewApiIssueID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "apiIdValue", "issueIdValue")

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

Example Usage: ApiIssueClient.Get

ctx := context.TODO()
id := apiissue.NewApiIssueID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "apiIdValue", "issueIdValue")

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

Example Usage: ApiIssueClient.GetEntityTag

ctx := context.TODO()
id := apiissue.NewApiIssueID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "apiIdValue", "issueIdValue")

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

Example Usage: ApiIssueClient.ListByService

ctx := context.TODO()
id := apiissue.NewApiID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "apiIdValue")

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

Example Usage: ApiIssueClient.Update

ctx := context.TODO()
id := apiissue.NewApiIssueID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "apiIdValue", "issueIdValue")

payload := apiissue.IssueUpdateContract{
	// ...
}


read, err := client.Update(ctx, id, payload, apiissue.DefaultUpdateOperationOptions())
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 PossibleValuesForState

func PossibleValuesForState() []string

func ValidateApiID

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

ValidateApiID checks that 'input' can be parsed as a Api ID

func ValidateApiIssueID added in v0.20230727.1090744

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

ValidateApiIssueID checks that 'input' can be parsed as a Api Issue ID

Types

type ApiId

type ApiId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
	ApiId             string
}

ApiId is a struct representing the Resource ID for a Api

func NewApiID

func NewApiID(subscriptionId string, resourceGroupName string, serviceName string, apiId string) ApiId

NewApiID returns a new ApiId struct

func ParseApiID

func ParseApiID(input string) (*ApiId, error)

ParseApiID parses 'input' into a ApiId

func ParseApiIDInsensitively

func ParseApiIDInsensitively(input string) (*ApiId, error)

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

func (*ApiId) FromParseResult added in v0.20231127.1171502

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

func (ApiId) ID

func (id ApiId) ID() string

ID returns the formatted Api ID

func (ApiId) Segments

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

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

func (ApiId) String

func (id ApiId) String() string

String returns a human-readable description of this Api ID

type ApiIssueClient

type ApiIssueClient struct {
	Client *resourcemanager.Client
}

func NewApiIssueClientWithBaseURI

func NewApiIssueClientWithBaseURI(sdkApi sdkEnv.Api) (*ApiIssueClient, error)

func (ApiIssueClient) CreateOrUpdate

CreateOrUpdate ...

func (ApiIssueClient) Delete

Delete ...

func (ApiIssueClient) Get

Get ...

func (ApiIssueClient) GetEntityTag

func (c ApiIssueClient) GetEntityTag(ctx context.Context, id ApiIssueId) (result GetEntityTagOperationResponse, err error)

GetEntityTag ...

func (ApiIssueClient) ListByService

ListByService ...

func (ApiIssueClient) ListByServiceComplete

ListByServiceComplete retrieves all the results into a single object

func (ApiIssueClient) ListByServiceCompleteMatchingPredicate

func (c ApiIssueClient) ListByServiceCompleteMatchingPredicate(ctx context.Context, id ApiId, options ListByServiceOperationOptions, predicate IssueContractOperationPredicate) (result ListByServiceCompleteResult, err error)

ListByServiceCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ApiIssueClient) Update

Update ...

type ApiIssueId added in v0.20230727.1090744

type ApiIssueId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
	ApiId             string
	IssueId           string
}

ApiIssueId is a struct representing the Resource ID for a Api Issue

func NewApiIssueID added in v0.20230727.1090744

func NewApiIssueID(subscriptionId string, resourceGroupName string, serviceName string, apiId string, issueId string) ApiIssueId

NewApiIssueID returns a new ApiIssueId struct

func ParseApiIssueID added in v0.20230727.1090744

func ParseApiIssueID(input string) (*ApiIssueId, error)

ParseApiIssueID parses 'input' into a ApiIssueId

func ParseApiIssueIDInsensitively added in v0.20230727.1090744

func ParseApiIssueIDInsensitively(input string) (*ApiIssueId, error)

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

func (*ApiIssueId) FromParseResult added in v0.20231127.1171502

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

func (ApiIssueId) ID added in v0.20230727.1090744

func (id ApiIssueId) ID() string

ID returns the formatted Api Issue ID

func (ApiIssueId) Segments added in v0.20230727.1090744

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

Segments returns a slice of Resource ID Segments which comprise this Api Issue ID

func (ApiIssueId) String added in v0.20230727.1090744

func (id ApiIssueId) String() string

String returns a human-readable description of this Api Issue ID

type CreateOrUpdateOperationOptions

type CreateOrUpdateOperationOptions struct {
	IfMatch *string
}

func DefaultCreateOrUpdateOperationOptions

func DefaultCreateOrUpdateOperationOptions() CreateOrUpdateOperationOptions

func (CreateOrUpdateOperationOptions) ToHeaders added in v0.20230801.1071415

func (CreateOrUpdateOperationOptions) ToOData added in v0.20230801.1071415

func (CreateOrUpdateOperationOptions) ToQuery added in v0.20230801.1071415

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *IssueContract
}

type DeleteOperationOptions

type DeleteOperationOptions struct {
	IfMatch *string
}

func DefaultDeleteOperationOptions

func DefaultDeleteOperationOptions() DeleteOperationOptions

func (DeleteOperationOptions) ToHeaders added in v0.20230801.1071415

func (o DeleteOperationOptions) ToHeaders() *client.Headers

func (DeleteOperationOptions) ToOData added in v0.20230801.1071415

func (o DeleteOperationOptions) ToOData() *odata.Query

func (DeleteOperationOptions) ToQuery added in v0.20230801.1071415

type DeleteOperationResponse

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

type GetEntityTagOperationResponse

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

type GetOperationOptions

type GetOperationOptions struct {
	ExpandCommentsAttachments *bool
}

func DefaultGetOperationOptions

func DefaultGetOperationOptions() GetOperationOptions

func (GetOperationOptions) ToHeaders added in v0.20230801.1071415

func (o GetOperationOptions) ToHeaders() *client.Headers

func (GetOperationOptions) ToOData added in v0.20230801.1071415

func (o GetOperationOptions) ToOData() *odata.Query

func (GetOperationOptions) ToQuery added in v0.20230801.1071415

func (o GetOperationOptions) ToQuery() *client.QueryParams

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *IssueContract
}

type IssueContract

type IssueContract struct {
	Id         *string                  `json:"id,omitempty"`
	Name       *string                  `json:"name,omitempty"`
	Properties *IssueContractProperties `json:"properties,omitempty"`
	Type       *string                  `json:"type,omitempty"`
}

type IssueContractOperationPredicate

type IssueContractOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (IssueContractOperationPredicate) Matches

type IssueContractProperties

type IssueContractProperties struct {
	ApiId       *string `json:"apiId,omitempty"`
	CreatedDate *string `json:"createdDate,omitempty"`
	Description string  `json:"description"`
	State       *State  `json:"state,omitempty"`
	Title       string  `json:"title"`
	UserId      string  `json:"userId"`
}

func (*IssueContractProperties) GetCreatedDateAsTime

func (o *IssueContractProperties) GetCreatedDateAsTime() (*time.Time, error)

func (*IssueContractProperties) SetCreatedDateAsTime

func (o *IssueContractProperties) SetCreatedDateAsTime(input time.Time)

type IssueUpdateContract

type IssueUpdateContract struct {
	Properties *IssueUpdateContractProperties `json:"properties,omitempty"`
}

type IssueUpdateContractProperties

type IssueUpdateContractProperties struct {
	ApiId       *string `json:"apiId,omitempty"`
	CreatedDate *string `json:"createdDate,omitempty"`
	Description *string `json:"description,omitempty"`
	State       *State  `json:"state,omitempty"`
	Title       *string `json:"title,omitempty"`
	UserId      *string `json:"userId,omitempty"`
}

func (*IssueUpdateContractProperties) GetCreatedDateAsTime

func (o *IssueUpdateContractProperties) GetCreatedDateAsTime() (*time.Time, error)

func (*IssueUpdateContractProperties) SetCreatedDateAsTime

func (o *IssueUpdateContractProperties) SetCreatedDateAsTime(input time.Time)

type ListByServiceCompleteResult

type ListByServiceCompleteResult struct {
	Items []IssueContract
}

type ListByServiceOperationOptions

type ListByServiceOperationOptions struct {
	ExpandCommentsAttachments *bool
	Filter                    *string
	Skip                      *int64
	Top                       *int64
}

func DefaultListByServiceOperationOptions

func DefaultListByServiceOperationOptions() ListByServiceOperationOptions

func (ListByServiceOperationOptions) ToHeaders added in v0.20230801.1071415

func (ListByServiceOperationOptions) ToOData added in v0.20230801.1071415

func (ListByServiceOperationOptions) ToQuery added in v0.20230801.1071415

type ListByServiceOperationResponse

type ListByServiceOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]IssueContract
}

type State

type State string
const (
	StateClosed   State = "closed"
	StateOpen     State = "open"
	StateProposed State = "proposed"
	StateRemoved  State = "removed"
	StateResolved State = "resolved"
)

func (*State) UnmarshalJSON added in v0.20230801.1071415

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

type UpdateOperationOptions

type UpdateOperationOptions struct {
	IfMatch *string
}

func DefaultUpdateOperationOptions

func DefaultUpdateOperationOptions() UpdateOperationOptions

func (UpdateOperationOptions) ToHeaders added in v0.20230801.1071415

func (o UpdateOperationOptions) ToHeaders() *client.Headers

func (UpdateOperationOptions) ToOData added in v0.20230801.1071415

func (o UpdateOperationOptions) ToOData() *odata.Query

func (UpdateOperationOptions) ToQuery added in v0.20230801.1071415

type UpdateOperationResponse

type UpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *IssueContract
}

Jump to

Keyboard shortcuts

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