apiproduct

package
v0.20240715.1103416 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2024 License: MPL-2.0 Imports: 11 Imported by: 0

README

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

The apiproduct 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/apiproduct"

Client Initialization

client := apiproduct.NewApiProductClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ApiProductClient.ListByApis

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

// alternatively `client.ListByApis(ctx, id, apiproduct.DefaultListByApisOperationOptions())` can be used to do batched pagination
items, err := client.ListByApisComplete(ctx, id, apiproduct.DefaultListByApisOperationOptions())
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 PossibleValuesForProductState

func PossibleValuesForProductState() []string

func ValidateApiID

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

ValidateApiID checks that 'input' can be parsed as a Api 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

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 ApiProductClient

type ApiProductClient struct {
	Client *resourcemanager.Client
}

func NewApiProductClientWithBaseURI

func NewApiProductClientWithBaseURI(sdkApi sdkEnv.Api) (*ApiProductClient, error)

func (ApiProductClient) ListByApis

ListByApis ...

func (ApiProductClient) ListByApisComplete

ListByApisComplete retrieves all the results into a single object

func (ApiProductClient) ListByApisCompleteMatchingPredicate

func (c ApiProductClient) ListByApisCompleteMatchingPredicate(ctx context.Context, id ApiId, options ListByApisOperationOptions, predicate ProductContractOperationPredicate) (result ListByApisCompleteResult, err error)

ListByApisCompleteMatchingPredicate retrieves all the results and then applies the predicate

type ListByApisCompleteResult

type ListByApisCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ProductContract
}

type ListByApisCustomPager added in v0.20240628.1153531

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

type ListByApisOperationOptions

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

func DefaultListByApisOperationOptions

func DefaultListByApisOperationOptions() ListByApisOperationOptions

func (ListByApisOperationOptions) ToHeaders

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

func (ListByApisOperationOptions) ToOData

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

func (ListByApisOperationOptions) ToQuery

type ListByApisOperationResponse

type ListByApisOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ProductContract
}

type ProductContract

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

type ProductContractOperationPredicate

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

func (ProductContractOperationPredicate) Matches

type ProductContractProperties

type ProductContractProperties struct {
	ApprovalRequired     *bool         `json:"approvalRequired,omitempty"`
	Description          *string       `json:"description,omitempty"`
	DisplayName          string        `json:"displayName"`
	State                *ProductState `json:"state,omitempty"`
	SubscriptionRequired *bool         `json:"subscriptionRequired,omitempty"`
	SubscriptionsLimit   *int64        `json:"subscriptionsLimit,omitempty"`
	Terms                *string       `json:"terms,omitempty"`
}

type ProductState

type ProductState string
const (
	ProductStateNotPublished ProductState = "notPublished"
	ProductStatePublished    ProductState = "published"
)

func (*ProductState) UnmarshalJSON

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

Jump to

Keyboard shortcuts

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