apirelease

package
v0.20241104.1140654 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2024 License: MPL-2.0 Imports: 12 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/apimanagement/2023-03-01-preview/apirelease Documentation

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

Client Initialization

client := apirelease.NewApiReleaseClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ApiReleaseClient.CreateOrUpdate

ctx := context.TODO()
id := apirelease.NewReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "apiId", "releaseId")

payload := apirelease.ApiReleaseContract{
	// ...
}


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

Example Usage: ApiReleaseClient.Delete

ctx := context.TODO()
id := apirelease.NewReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "apiId", "releaseId")

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

Example Usage: ApiReleaseClient.Get

ctx := context.TODO()
id := apirelease.NewReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "apiId", "releaseId")

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: ApiReleaseClient.GetEntityTag

ctx := context.TODO()
id := apirelease.NewReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "apiId", "releaseId")

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: ApiReleaseClient.ListByService

ctx := context.TODO()
id := apirelease.NewApiID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "apiId")

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

Example Usage: ApiReleaseClient.Update

ctx := context.TODO()
id := apirelease.NewReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "apiId", "releaseId")

payload := apirelease.ApiReleaseContract{
	// ...
}


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

Example Usage: ApiReleaseClient.WorkspaceApiReleaseCreateOrUpdate

ctx := context.TODO()
id := apirelease.NewApiReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "workspaceId", "apiId", "releaseId")

payload := apirelease.ApiReleaseContract{
	// ...
}


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

Example Usage: ApiReleaseClient.WorkspaceApiReleaseDelete

ctx := context.TODO()
id := apirelease.NewApiReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "workspaceId", "apiId", "releaseId")

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

Example Usage: ApiReleaseClient.WorkspaceApiReleaseGet

ctx := context.TODO()
id := apirelease.NewApiReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "workspaceId", "apiId", "releaseId")

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

Example Usage: ApiReleaseClient.WorkspaceApiReleaseGetEntityTag

ctx := context.TODO()
id := apirelease.NewApiReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "workspaceId", "apiId", "releaseId")

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

Example Usage: ApiReleaseClient.WorkspaceApiReleaseListByService

ctx := context.TODO()
id := apirelease.NewWorkspaceApiID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "workspaceId", "apiId")

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

Example Usage: ApiReleaseClient.WorkspaceApiReleaseUpdate

ctx := context.TODO()
id := apirelease.NewApiReleaseID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceName", "workspaceId", "apiId", "releaseId")

payload := apirelease.ApiReleaseContract{
	// ...
}


read, err := client.WorkspaceApiReleaseUpdate(ctx, id, payload, apirelease.DefaultWorkspaceApiReleaseUpdateOperationOptions())
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 ValidateApiID

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

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

func ValidateApiReleaseID

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

ValidateApiReleaseID checks that 'input' can be parsed as a Api Release ID

func ValidateReleaseID

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

ValidateReleaseID checks that 'input' can be parsed as a Release ID

func ValidateWorkspaceApiID

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

ValidateWorkspaceApiID checks that 'input' can be parsed as a Workspace 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 ApiReleaseClient

type ApiReleaseClient struct {
	Client *resourcemanager.Client
}

func NewApiReleaseClientWithBaseURI

func NewApiReleaseClientWithBaseURI(sdkApi sdkEnv.Api) (*ApiReleaseClient, error)

func (ApiReleaseClient) CreateOrUpdate

CreateOrUpdate ...

func (ApiReleaseClient) Delete

Delete ...

func (ApiReleaseClient) Get

func (c ApiReleaseClient) Get(ctx context.Context, id ReleaseId) (result GetOperationResponse, err error)

Get ...

func (ApiReleaseClient) GetEntityTag

func (c ApiReleaseClient) GetEntityTag(ctx context.Context, id ReleaseId) (result GetEntityTagOperationResponse, err error)

GetEntityTag ...

func (ApiReleaseClient) ListByService

ListByService ...

func (ApiReleaseClient) ListByServiceComplete

ListByServiceComplete retrieves all the results into a single object

func (ApiReleaseClient) ListByServiceCompleteMatchingPredicate

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

ListByServiceCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ApiReleaseClient) Update

Update ...

func (ApiReleaseClient) WorkspaceApiReleaseCreateOrUpdate

WorkspaceApiReleaseCreateOrUpdate ...

func (ApiReleaseClient) WorkspaceApiReleaseDelete

WorkspaceApiReleaseDelete ...

func (ApiReleaseClient) WorkspaceApiReleaseGet

func (c ApiReleaseClient) WorkspaceApiReleaseGet(ctx context.Context, id ApiReleaseId) (result WorkspaceApiReleaseGetOperationResponse, err error)

WorkspaceApiReleaseGet ...

func (ApiReleaseClient) WorkspaceApiReleaseGetEntityTag

func (c ApiReleaseClient) WorkspaceApiReleaseGetEntityTag(ctx context.Context, id ApiReleaseId) (result WorkspaceApiReleaseGetEntityTagOperationResponse, err error)

WorkspaceApiReleaseGetEntityTag ...

func (ApiReleaseClient) WorkspaceApiReleaseListByService

WorkspaceApiReleaseListByService ...

func (ApiReleaseClient) WorkspaceApiReleaseListByServiceComplete

WorkspaceApiReleaseListByServiceComplete retrieves all the results into a single object

func (ApiReleaseClient) WorkspaceApiReleaseListByServiceCompleteMatchingPredicate

WorkspaceApiReleaseListByServiceCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ApiReleaseClient) WorkspaceApiReleaseUpdate

WorkspaceApiReleaseUpdate ...

type ApiReleaseContract

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

type ApiReleaseContractOperationPredicate

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

func (ApiReleaseContractOperationPredicate) Matches

type ApiReleaseContractProperties

type ApiReleaseContractProperties struct {
	ApiId           *string `json:"apiId,omitempty"`
	CreatedDateTime *string `json:"createdDateTime,omitempty"`
	Notes           *string `json:"notes,omitempty"`
	UpdatedDateTime *string `json:"updatedDateTime,omitempty"`
}

func (*ApiReleaseContractProperties) GetCreatedDateTimeAsTime

func (o *ApiReleaseContractProperties) GetCreatedDateTimeAsTime() (*time.Time, error)

func (*ApiReleaseContractProperties) GetUpdatedDateTimeAsTime

func (o *ApiReleaseContractProperties) GetUpdatedDateTimeAsTime() (*time.Time, error)

func (*ApiReleaseContractProperties) SetCreatedDateTimeAsTime

func (o *ApiReleaseContractProperties) SetCreatedDateTimeAsTime(input time.Time)

func (*ApiReleaseContractProperties) SetUpdatedDateTimeAsTime

func (o *ApiReleaseContractProperties) SetUpdatedDateTimeAsTime(input time.Time)

type ApiReleaseId

type ApiReleaseId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
	WorkspaceId       string
	ApiId             string
	ReleaseId         string
}

ApiReleaseId is a struct representing the Resource ID for a Api Release

func NewApiReleaseID

func NewApiReleaseID(subscriptionId string, resourceGroupName string, serviceName string, workspaceId string, apiId string, releaseId string) ApiReleaseId

NewApiReleaseID returns a new ApiReleaseId struct

func ParseApiReleaseID

func ParseApiReleaseID(input string) (*ApiReleaseId, error)

ParseApiReleaseID parses 'input' into a ApiReleaseId

func ParseApiReleaseIDInsensitively

func ParseApiReleaseIDInsensitively(input string) (*ApiReleaseId, error)

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

func (*ApiReleaseId) FromParseResult

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

func (ApiReleaseId) ID

func (id ApiReleaseId) ID() string

ID returns the formatted Api Release ID

func (ApiReleaseId) Segments

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

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

func (ApiReleaseId) String

func (id ApiReleaseId) String() string

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

type CreateOrUpdateOperationOptions

type CreateOrUpdateOperationOptions struct {
	IfMatch *string
}

func DefaultCreateOrUpdateOperationOptions

func DefaultCreateOrUpdateOperationOptions() CreateOrUpdateOperationOptions

func (CreateOrUpdateOperationOptions) ToHeaders

func (CreateOrUpdateOperationOptions) ToOData

func (CreateOrUpdateOperationOptions) ToQuery

type CreateOrUpdateOperationResponse

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

type DeleteOperationOptions

type DeleteOperationOptions struct {
	IfMatch *string
}

func DefaultDeleteOperationOptions

func DefaultDeleteOperationOptions() DeleteOperationOptions

func (DeleteOperationOptions) ToHeaders

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

func (DeleteOperationOptions) ToOData

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

func (DeleteOperationOptions) ToQuery

type DeleteOperationResponse

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

type GetEntityTagOperationResponse

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

type GetOperationResponse

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

type ListByServiceCompleteResult

type ListByServiceCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ApiReleaseContract
}

type ListByServiceCustomPager added in v0.20240628.1153531

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

type ListByServiceOperationOptions

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

func DefaultListByServiceOperationOptions

func DefaultListByServiceOperationOptions() ListByServiceOperationOptions

func (ListByServiceOperationOptions) ToHeaders

func (ListByServiceOperationOptions) ToOData

func (ListByServiceOperationOptions) ToQuery

type ListByServiceOperationResponse

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

type ReleaseId

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

ReleaseId is a struct representing the Resource ID for a Release

func NewReleaseID

func NewReleaseID(subscriptionId string, resourceGroupName string, serviceName string, apiId string, releaseId string) ReleaseId

NewReleaseID returns a new ReleaseId struct

func ParseReleaseID

func ParseReleaseID(input string) (*ReleaseId, error)

ParseReleaseID parses 'input' into a ReleaseId

func ParseReleaseIDInsensitively

func ParseReleaseIDInsensitively(input string) (*ReleaseId, error)

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

func (*ReleaseId) FromParseResult

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

func (ReleaseId) ID

func (id ReleaseId) ID() string

ID returns the formatted Release ID

func (ReleaseId) Segments

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

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

func (ReleaseId) String

func (id ReleaseId) String() string

String returns a human-readable description of this Release ID

type UpdateOperationOptions

type UpdateOperationOptions struct {
	IfMatch *string
}

func DefaultUpdateOperationOptions

func DefaultUpdateOperationOptions() UpdateOperationOptions

func (UpdateOperationOptions) ToHeaders

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

func (UpdateOperationOptions) ToOData

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

func (UpdateOperationOptions) ToQuery

type UpdateOperationResponse

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

type WorkspaceApiId

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

WorkspaceApiId is a struct representing the Resource ID for a Workspace Api

func NewWorkspaceApiID

func NewWorkspaceApiID(subscriptionId string, resourceGroupName string, serviceName string, workspaceId string, apiId string) WorkspaceApiId

NewWorkspaceApiID returns a new WorkspaceApiId struct

func ParseWorkspaceApiID

func ParseWorkspaceApiID(input string) (*WorkspaceApiId, error)

ParseWorkspaceApiID parses 'input' into a WorkspaceApiId

func ParseWorkspaceApiIDInsensitively

func ParseWorkspaceApiIDInsensitively(input string) (*WorkspaceApiId, error)

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

func (*WorkspaceApiId) FromParseResult

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

func (WorkspaceApiId) ID

func (id WorkspaceApiId) ID() string

ID returns the formatted Workspace Api ID

func (WorkspaceApiId) Segments

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

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

func (WorkspaceApiId) String

func (id WorkspaceApiId) String() string

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

type WorkspaceApiReleaseCreateOrUpdateOperationOptions

type WorkspaceApiReleaseCreateOrUpdateOperationOptions struct {
	IfMatch *string
}

func DefaultWorkspaceApiReleaseCreateOrUpdateOperationOptions

func DefaultWorkspaceApiReleaseCreateOrUpdateOperationOptions() WorkspaceApiReleaseCreateOrUpdateOperationOptions

func (WorkspaceApiReleaseCreateOrUpdateOperationOptions) ToHeaders

func (WorkspaceApiReleaseCreateOrUpdateOperationOptions) ToOData

func (WorkspaceApiReleaseCreateOrUpdateOperationOptions) ToQuery

type WorkspaceApiReleaseCreateOrUpdateOperationResponse

type WorkspaceApiReleaseCreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ApiReleaseContract
}

type WorkspaceApiReleaseDeleteOperationOptions

type WorkspaceApiReleaseDeleteOperationOptions struct {
	IfMatch *string
}

func DefaultWorkspaceApiReleaseDeleteOperationOptions

func DefaultWorkspaceApiReleaseDeleteOperationOptions() WorkspaceApiReleaseDeleteOperationOptions

func (WorkspaceApiReleaseDeleteOperationOptions) ToHeaders

func (WorkspaceApiReleaseDeleteOperationOptions) ToOData

func (WorkspaceApiReleaseDeleteOperationOptions) ToQuery

type WorkspaceApiReleaseDeleteOperationResponse

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

type WorkspaceApiReleaseGetEntityTagOperationResponse

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

type WorkspaceApiReleaseGetOperationResponse

type WorkspaceApiReleaseGetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ApiReleaseContract
}

type WorkspaceApiReleaseListByServiceCompleteResult

type WorkspaceApiReleaseListByServiceCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ApiReleaseContract
}

type WorkspaceApiReleaseListByServiceCustomPager added in v0.20240628.1153531

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

type WorkspaceApiReleaseListByServiceOperationOptions

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

func DefaultWorkspaceApiReleaseListByServiceOperationOptions

func DefaultWorkspaceApiReleaseListByServiceOperationOptions() WorkspaceApiReleaseListByServiceOperationOptions

func (WorkspaceApiReleaseListByServiceOperationOptions) ToHeaders

func (WorkspaceApiReleaseListByServiceOperationOptions) ToOData

func (WorkspaceApiReleaseListByServiceOperationOptions) ToQuery

type WorkspaceApiReleaseListByServiceOperationResponse

type WorkspaceApiReleaseListByServiceOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ApiReleaseContract
}

type WorkspaceApiReleaseUpdateOperationOptions

type WorkspaceApiReleaseUpdateOperationOptions struct {
	IfMatch *string
}

func DefaultWorkspaceApiReleaseUpdateOperationOptions

func DefaultWorkspaceApiReleaseUpdateOperationOptions() WorkspaceApiReleaseUpdateOperationOptions

func (WorkspaceApiReleaseUpdateOperationOptions) ToHeaders

func (WorkspaceApiReleaseUpdateOperationOptions) ToOData

func (WorkspaceApiReleaseUpdateOperationOptions) ToQuery

type WorkspaceApiReleaseUpdateOperationResponse

type WorkspaceApiReleaseUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ApiReleaseContract
}

Jump to

Keyboard shortcuts

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