productapilink

package
v0.20240701.1082110 Latest Latest
Warning

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

Go to latest
Published: Jul 1, 2024 License: MPL-2.0 Imports: 10 Imported by: 1

README

The productapilink SDK allows for interaction with the Azure Resource Manager Service apimanagement (API Version 2023-05-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/apimanagement/2023-05-01-preview/productapilink"

Client Initialization

client := productapilink.NewProductApiLinkClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ProductApiLinkClient.CreateOrUpdate

ctx := context.TODO()
id := productapilink.NewProductApiLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "productIdValue", "apiLinkIdValue")

payload := productapilink.ProductApiLinkContract{
	// ...
}


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: ProductApiLinkClient.Delete

ctx := context.TODO()
id := productapilink.NewProductApiLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "productIdValue", "apiLinkIdValue")

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: ProductApiLinkClient.Get

ctx := context.TODO()
id := productapilink.NewProductApiLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "productIdValue", "apiLinkIdValue")

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: ProductApiLinkClient.ListByProduct

ctx := context.TODO()
id := productapilink.NewProductID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "productIdValue")

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

Example Usage: ProductApiLinkClient.WorkspaceProductApiLinkCreateOrUpdate

ctx := context.TODO()
id := productapilink.NewWorkspaceProductApiLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "workspaceIdValue", "productIdValue", "apiLinkIdValue")

payload := productapilink.ProductApiLinkContract{
	// ...
}


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

Example Usage: ProductApiLinkClient.WorkspaceProductApiLinkDelete

ctx := context.TODO()
id := productapilink.NewWorkspaceProductApiLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "workspaceIdValue", "productIdValue", "apiLinkIdValue")

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

Example Usage: ProductApiLinkClient.WorkspaceProductApiLinkGet

ctx := context.TODO()
id := productapilink.NewWorkspaceProductApiLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "workspaceIdValue", "productIdValue", "apiLinkIdValue")

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

Example Usage: ProductApiLinkClient.WorkspaceProductApiLinkListByProduct

ctx := context.TODO()
id := productapilink.NewWorkspaceProductID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "workspaceIdValue", "productIdValue")

// alternatively `client.WorkspaceProductApiLinkListByProduct(ctx, id, productapilink.DefaultWorkspaceProductApiLinkListByProductOperationOptions())` can be used to do batched pagination
items, err := client.WorkspaceProductApiLinkListByProductComplete(ctx, id, productapilink.DefaultWorkspaceProductApiLinkListByProductOperationOptions())
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 ValidateProductApiLinkID

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

ValidateProductApiLinkID checks that 'input' can be parsed as a Product Api Link ID

func ValidateProductID

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

ValidateProductID checks that 'input' can be parsed as a Product ID

func ValidateWorkspaceProductApiLinkID

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

ValidateWorkspaceProductApiLinkID checks that 'input' can be parsed as a Workspace Product Api Link ID

func ValidateWorkspaceProductID

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

ValidateWorkspaceProductID checks that 'input' can be parsed as a Workspace Product ID

Types

type CreateOrUpdateOperationResponse

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

type DeleteOperationResponse

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

type GetOperationResponse

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

type ListByProductCompleteResult

type ListByProductCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ProductApiLinkContract
}

type ListByProductCustomPager added in v0.20240628.1153531

type ListByProductCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByProductCustomPager) NextPageLink() *odata.Link

type ListByProductOperationOptions

type ListByProductOperationOptions struct {
	Filter *string
	Skip   *int64
	Top    *int64
}

func DefaultListByProductOperationOptions

func DefaultListByProductOperationOptions() ListByProductOperationOptions

func (ListByProductOperationOptions) ToHeaders

func (ListByProductOperationOptions) ToOData

func (ListByProductOperationOptions) ToQuery

type ListByProductOperationResponse

type ListByProductOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ProductApiLinkContract
}

type ProductApiLinkClient

type ProductApiLinkClient struct {
	Client *resourcemanager.Client
}

func NewProductApiLinkClientWithBaseURI

func NewProductApiLinkClientWithBaseURI(sdkApi sdkEnv.Api) (*ProductApiLinkClient, error)

func (ProductApiLinkClient) CreateOrUpdate

CreateOrUpdate ...

func (ProductApiLinkClient) Delete

Delete ...

func (ProductApiLinkClient) Get

Get ...

func (ProductApiLinkClient) ListByProduct

ListByProduct ...

func (ProductApiLinkClient) ListByProductComplete

ListByProductComplete retrieves all the results into a single object

func (ProductApiLinkClient) ListByProductCompleteMatchingPredicate

func (c ProductApiLinkClient) ListByProductCompleteMatchingPredicate(ctx context.Context, id ProductId, options ListByProductOperationOptions, predicate ProductApiLinkContractOperationPredicate) (result ListByProductCompleteResult, err error)

ListByProductCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ProductApiLinkClient) WorkspaceProductApiLinkCreateOrUpdate

WorkspaceProductApiLinkCreateOrUpdate ...

func (ProductApiLinkClient) WorkspaceProductApiLinkDelete

WorkspaceProductApiLinkDelete ...

func (ProductApiLinkClient) WorkspaceProductApiLinkGet

WorkspaceProductApiLinkGet ...

func (ProductApiLinkClient) WorkspaceProductApiLinkListByProduct

WorkspaceProductApiLinkListByProduct ...

func (ProductApiLinkClient) WorkspaceProductApiLinkListByProductComplete

WorkspaceProductApiLinkListByProductComplete retrieves all the results into a single object

func (ProductApiLinkClient) WorkspaceProductApiLinkListByProductCompleteMatchingPredicate

WorkspaceProductApiLinkListByProductCompleteMatchingPredicate retrieves all the results and then applies the predicate

type ProductApiLinkContract

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

type ProductApiLinkContractOperationPredicate

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

func (ProductApiLinkContractOperationPredicate) Matches

type ProductApiLinkContractProperties

type ProductApiLinkContractProperties struct {
	ApiId string `json:"apiId"`
}

type ProductApiLinkId

type ProductApiLinkId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
	ProductId         string
	ApiLinkId         string
}

ProductApiLinkId is a struct representing the Resource ID for a Product Api Link

func NewProductApiLinkID

func NewProductApiLinkID(subscriptionId string, resourceGroupName string, serviceName string, productId string, apiLinkId string) ProductApiLinkId

NewProductApiLinkID returns a new ProductApiLinkId struct

func ParseProductApiLinkID

func ParseProductApiLinkID(input string) (*ProductApiLinkId, error)

ParseProductApiLinkID parses 'input' into a ProductApiLinkId

func ParseProductApiLinkIDInsensitively

func ParseProductApiLinkIDInsensitively(input string) (*ProductApiLinkId, error)

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

func (*ProductApiLinkId) FromParseResult

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

func (ProductApiLinkId) ID

func (id ProductApiLinkId) ID() string

ID returns the formatted Product Api Link ID

func (ProductApiLinkId) Segments

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

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

func (ProductApiLinkId) String

func (id ProductApiLinkId) String() string

String returns a human-readable description of this Product Api Link ID

type ProductId

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

ProductId is a struct representing the Resource ID for a Product

func NewProductID

func NewProductID(subscriptionId string, resourceGroupName string, serviceName string, productId string) ProductId

NewProductID returns a new ProductId struct

func ParseProductID

func ParseProductID(input string) (*ProductId, error)

ParseProductID parses 'input' into a ProductId

func ParseProductIDInsensitively

func ParseProductIDInsensitively(input string) (*ProductId, error)

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

func (*ProductId) FromParseResult

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

func (ProductId) ID

func (id ProductId) ID() string

ID returns the formatted Product ID

func (ProductId) Segments

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

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

func (ProductId) String

func (id ProductId) String() string

String returns a human-readable description of this Product ID

type WorkspaceProductApiLinkCreateOrUpdateOperationResponse

type WorkspaceProductApiLinkCreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ProductApiLinkContract
}

type WorkspaceProductApiLinkDeleteOperationResponse

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

type WorkspaceProductApiLinkGetOperationResponse

type WorkspaceProductApiLinkGetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ProductApiLinkContract
}

type WorkspaceProductApiLinkId

type WorkspaceProductApiLinkId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
	WorkspaceId       string
	ProductId         string
	ApiLinkId         string
}

WorkspaceProductApiLinkId is a struct representing the Resource ID for a Workspace Product Api Link

func NewWorkspaceProductApiLinkID

func NewWorkspaceProductApiLinkID(subscriptionId string, resourceGroupName string, serviceName string, workspaceId string, productId string, apiLinkId string) WorkspaceProductApiLinkId

NewWorkspaceProductApiLinkID returns a new WorkspaceProductApiLinkId struct

func ParseWorkspaceProductApiLinkID

func ParseWorkspaceProductApiLinkID(input string) (*WorkspaceProductApiLinkId, error)

ParseWorkspaceProductApiLinkID parses 'input' into a WorkspaceProductApiLinkId

func ParseWorkspaceProductApiLinkIDInsensitively

func ParseWorkspaceProductApiLinkIDInsensitively(input string) (*WorkspaceProductApiLinkId, error)

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

func (*WorkspaceProductApiLinkId) FromParseResult

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

func (WorkspaceProductApiLinkId) ID

ID returns the formatted Workspace Product Api Link ID

func (WorkspaceProductApiLinkId) Segments

Segments returns a slice of Resource ID Segments which comprise this Workspace Product Api Link ID

func (WorkspaceProductApiLinkId) String

func (id WorkspaceProductApiLinkId) String() string

String returns a human-readable description of this Workspace Product Api Link ID

type WorkspaceProductApiLinkListByProductCompleteResult

type WorkspaceProductApiLinkListByProductCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ProductApiLinkContract
}

type WorkspaceProductApiLinkListByProductCustomPager added in v0.20240628.1153531

type WorkspaceProductApiLinkListByProductCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}

type WorkspaceProductApiLinkListByProductOperationOptions

type WorkspaceProductApiLinkListByProductOperationOptions struct {
	Filter *string
	Skip   *int64
	Top    *int64
}

func DefaultWorkspaceProductApiLinkListByProductOperationOptions

func DefaultWorkspaceProductApiLinkListByProductOperationOptions() WorkspaceProductApiLinkListByProductOperationOptions

func (WorkspaceProductApiLinkListByProductOperationOptions) ToHeaders

func (WorkspaceProductApiLinkListByProductOperationOptions) ToOData

func (WorkspaceProductApiLinkListByProductOperationOptions) ToQuery

type WorkspaceProductApiLinkListByProductOperationResponse

type WorkspaceProductApiLinkListByProductOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ProductApiLinkContract
}

type WorkspaceProductId

type WorkspaceProductId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
	WorkspaceId       string
	ProductId         string
}

WorkspaceProductId is a struct representing the Resource ID for a Workspace Product

func NewWorkspaceProductID

func NewWorkspaceProductID(subscriptionId string, resourceGroupName string, serviceName string, workspaceId string, productId string) WorkspaceProductId

NewWorkspaceProductID returns a new WorkspaceProductId struct

func ParseWorkspaceProductID

func ParseWorkspaceProductID(input string) (*WorkspaceProductId, error)

ParseWorkspaceProductID parses 'input' into a WorkspaceProductId

func ParseWorkspaceProductIDInsensitively

func ParseWorkspaceProductIDInsensitively(input string) (*WorkspaceProductId, error)

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

func (*WorkspaceProductId) FromParseResult

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

func (WorkspaceProductId) ID

func (id WorkspaceProductId) ID() string

ID returns the formatted Workspace Product ID

func (WorkspaceProductId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Workspace Product ID

func (WorkspaceProductId) String

func (id WorkspaceProductId) String() string

String returns a human-readable description of this Workspace Product ID

Jump to

Keyboard shortcuts

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