channels

package
v0.20240612.1122027 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2024 License: MPL-2.0 Imports: 15 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/eventgrid/2023-12-15-preview/channels Documentation

The channels SDK allows for interaction with the Azure Resource Manager Service eventgrid (API Version 2023-12-15-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/eventgrid/2023-12-15-preview/channels"

Client Initialization

client := channels.NewChannelsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ChannelsClient.CreateOrUpdate

ctx := context.TODO()
id := channels.NewChannelID("12345678-1234-9876-4563-123456789012", "example-resource-group", "partnerNamespaceValue", "channelValue")

payload := channels.Channel{
	// ...
}


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

ctx := context.TODO()
id := channels.NewChannelID("12345678-1234-9876-4563-123456789012", "example-resource-group", "partnerNamespaceValue", "channelValue")

if err := client.DeleteThenPoll(ctx, id); err != nil {
	// handle the error
}

Example Usage: ChannelsClient.Get

ctx := context.TODO()
id := channels.NewChannelID("12345678-1234-9876-4563-123456789012", "example-resource-group", "partnerNamespaceValue", "channelValue")

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: ChannelsClient.GetFullUrl

ctx := context.TODO()
id := channels.NewChannelID("12345678-1234-9876-4563-123456789012", "example-resource-group", "partnerNamespaceValue", "channelValue")

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

Example Usage: ChannelsClient.ListByPartnerNamespace

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

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

Example Usage: ChannelsClient.Update

ctx := context.TODO()
id := channels.NewChannelID("12345678-1234-9876-4563-123456789012", "example-resource-group", "partnerNamespaceValue", "channelValue")

payload := channels.ChannelUpdateParameters{
	// ...
}


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

func PossibleValuesForChannelProvisioningState() []string

func PossibleValuesForChannelType

func PossibleValuesForChannelType() []string

func PossibleValuesForEventDefinitionKind

func PossibleValuesForEventDefinitionKind() []string

func PossibleValuesForPartnerClientAuthenticationType

func PossibleValuesForPartnerClientAuthenticationType() []string

func PossibleValuesForPartnerEndpointType

func PossibleValuesForPartnerEndpointType() []string

func PossibleValuesForReadinessState

func PossibleValuesForReadinessState() []string

func ValidateChannelID

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

ValidateChannelID checks that 'input' can be parsed as a Channel ID

func ValidatePartnerNamespaceID

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

ValidatePartnerNamespaceID checks that 'input' can be parsed as a Partner Namespace ID

Types

type AzureADPartnerClientAuthentication

type AzureADPartnerClientAuthentication struct {
	Properties *AzureADPartnerClientAuthenticationProperties `json:"properties,omitempty"`
}

func (AzureADPartnerClientAuthentication) MarshalJSON

func (s AzureADPartnerClientAuthentication) MarshalJSON() ([]byte, error)

type AzureADPartnerClientAuthenticationProperties

type AzureADPartnerClientAuthenticationProperties struct {
	AzureActiveDirectoryApplicationIdOrUri *string `json:"azureActiveDirectoryApplicationIdOrUri,omitempty"`
	AzureActiveDirectoryTenantId           *string `json:"azureActiveDirectoryTenantId,omitempty"`
}

type Channel

type Channel struct {
	Id         *string                `json:"id,omitempty"`
	Name       *string                `json:"name,omitempty"`
	Properties *ChannelProperties     `json:"properties,omitempty"`
	SystemData *systemdata.SystemData `json:"systemData,omitempty"`
	Type       *string                `json:"type,omitempty"`
}

type ChannelId

type ChannelId struct {
	SubscriptionId       string
	ResourceGroupName    string
	PartnerNamespaceName string
	ChannelName          string
}

ChannelId is a struct representing the Resource ID for a Channel

func NewChannelID

func NewChannelID(subscriptionId string, resourceGroupName string, partnerNamespaceName string, channelName string) ChannelId

NewChannelID returns a new ChannelId struct

func ParseChannelID

func ParseChannelID(input string) (*ChannelId, error)

ParseChannelID parses 'input' into a ChannelId

func ParseChannelIDInsensitively

func ParseChannelIDInsensitively(input string) (*ChannelId, error)

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

func (*ChannelId) FromParseResult

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

func (ChannelId) ID

func (id ChannelId) ID() string

ID returns the formatted Channel ID

func (ChannelId) Segments

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

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

func (ChannelId) String

func (id ChannelId) String() string

String returns a human-readable description of this Channel ID

type ChannelOperationPredicate

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

func (ChannelOperationPredicate) Matches

func (p ChannelOperationPredicate) Matches(input Channel) bool

type ChannelProperties

type ChannelProperties struct {
	ChannelType                     *ChannelType              `json:"channelType,omitempty"`
	ExpirationTimeIfNotActivatedUtc *string                   `json:"expirationTimeIfNotActivatedUtc,omitempty"`
	MessageForActivation            *string                   `json:"messageForActivation,omitempty"`
	PartnerDestinationInfo          PartnerDestinationInfo    `json:"partnerDestinationInfo"`
	PartnerTopicInfo                *PartnerTopicInfo         `json:"partnerTopicInfo,omitempty"`
	ProvisioningState               *ChannelProvisioningState `json:"provisioningState,omitempty"`
	ReadinessState                  *ReadinessState           `json:"readinessState,omitempty"`
}

func (*ChannelProperties) GetExpirationTimeIfNotActivatedUtcAsTime

func (o *ChannelProperties) GetExpirationTimeIfNotActivatedUtcAsTime() (*time.Time, error)

func (*ChannelProperties) SetExpirationTimeIfNotActivatedUtcAsTime

func (o *ChannelProperties) SetExpirationTimeIfNotActivatedUtcAsTime(input time.Time)

func (*ChannelProperties) UnmarshalJSON

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

type ChannelProvisioningState

type ChannelProvisioningState string
const (
	ChannelProvisioningStateCanceled                                    ChannelProvisioningState = "Canceled"
	ChannelProvisioningStateCreating                                    ChannelProvisioningState = "Creating"
	ChannelProvisioningStateDeleting                                    ChannelProvisioningState = "Deleting"
	ChannelProvisioningStateFailed                                      ChannelProvisioningState = "Failed"
	ChannelProvisioningStateIdleDueToMirroredPartnerDestinationDeletion ChannelProvisioningState = "IdleDueToMirroredPartnerDestinationDeletion"
	ChannelProvisioningStateIdleDueToMirroredPartnerTopicDeletion       ChannelProvisioningState = "IdleDueToMirroredPartnerTopicDeletion"
	ChannelProvisioningStateSucceeded                                   ChannelProvisioningState = "Succeeded"
	ChannelProvisioningStateUpdating                                    ChannelProvisioningState = "Updating"
)

func (*ChannelProvisioningState) UnmarshalJSON

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

type ChannelType

type ChannelType string
const (
	ChannelTypePartnerDestination ChannelType = "PartnerDestination"
	ChannelTypePartnerTopic       ChannelType = "PartnerTopic"
)

func (*ChannelType) UnmarshalJSON

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

type ChannelUpdateParameters

type ChannelUpdateParameters struct {
	Properties *ChannelUpdateParametersProperties `json:"properties,omitempty"`
}

type ChannelUpdateParametersProperties

type ChannelUpdateParametersProperties struct {
	ExpirationTimeIfNotActivatedUtc *string                      `json:"expirationTimeIfNotActivatedUtc,omitempty"`
	PartnerDestinationInfo          PartnerUpdateDestinationInfo `json:"partnerDestinationInfo"`
	PartnerTopicInfo                *PartnerUpdateTopicInfo      `json:"partnerTopicInfo,omitempty"`
}

func (*ChannelUpdateParametersProperties) GetExpirationTimeIfNotActivatedUtcAsTime

func (o *ChannelUpdateParametersProperties) GetExpirationTimeIfNotActivatedUtcAsTime() (*time.Time, error)

func (*ChannelUpdateParametersProperties) SetExpirationTimeIfNotActivatedUtcAsTime

func (o *ChannelUpdateParametersProperties) SetExpirationTimeIfNotActivatedUtcAsTime(input time.Time)

func (*ChannelUpdateParametersProperties) UnmarshalJSON

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

type ChannelsClient

type ChannelsClient struct {
	Client *resourcemanager.Client
}

func NewChannelsClientWithBaseURI

func NewChannelsClientWithBaseURI(sdkApi sdkEnv.Api) (*ChannelsClient, error)

func (ChannelsClient) CreateOrUpdate

func (c ChannelsClient) CreateOrUpdate(ctx context.Context, id ChannelId, input Channel) (result CreateOrUpdateOperationResponse, err error)

CreateOrUpdate ...

func (ChannelsClient) Delete

func (c ChannelsClient) Delete(ctx context.Context, id ChannelId) (result DeleteOperationResponse, err error)

Delete ...

func (ChannelsClient) DeleteThenPoll

func (c ChannelsClient) DeleteThenPoll(ctx context.Context, id ChannelId) error

DeleteThenPoll performs Delete then polls until it's completed

func (ChannelsClient) Get

func (c ChannelsClient) Get(ctx context.Context, id ChannelId) (result GetOperationResponse, err error)

Get ...

func (ChannelsClient) GetFullUrl

func (c ChannelsClient) GetFullUrl(ctx context.Context, id ChannelId) (result GetFullUrlOperationResponse, err error)

GetFullUrl ...

func (ChannelsClient) ListByPartnerNamespace

ListByPartnerNamespace ...

func (ChannelsClient) ListByPartnerNamespaceComplete

ListByPartnerNamespaceComplete retrieves all the results into a single object

func (ChannelsClient) ListByPartnerNamespaceCompleteMatchingPredicate

func (c ChannelsClient) ListByPartnerNamespaceCompleteMatchingPredicate(ctx context.Context, id PartnerNamespaceId, options ListByPartnerNamespaceOperationOptions, predicate ChannelOperationPredicate) (result ListByPartnerNamespaceCompleteResult, err error)

ListByPartnerNamespaceCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ChannelsClient) Update

Update ...

type CreateOrUpdateOperationResponse

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

type DeleteOperationResponse

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

type EventDefinitionKind

type EventDefinitionKind string
const (
	EventDefinitionKindInline EventDefinitionKind = "Inline"
)

func (*EventDefinitionKind) UnmarshalJSON

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

type EventSubscriptionFullUrl

type EventSubscriptionFullUrl struct {
	EndpointUrl *string `json:"endpointUrl,omitempty"`
}

type EventTypeInfo

type EventTypeInfo struct {
	InlineEventTypes *map[string]InlineEventProperties `json:"inlineEventTypes,omitempty"`
	Kind             *EventDefinitionKind              `json:"kind,omitempty"`
}

type GetFullUrlOperationResponse

type GetFullUrlOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *EventSubscriptionFullUrl
}

type GetOperationResponse

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

type InlineEventProperties

type InlineEventProperties struct {
	DataSchemaUrl    *string `json:"dataSchemaUrl,omitempty"`
	Description      *string `json:"description,omitempty"`
	DisplayName      *string `json:"displayName,omitempty"`
	DocumentationUrl *string `json:"documentationUrl,omitempty"`
}

type ListByPartnerNamespaceCompleteResult

type ListByPartnerNamespaceCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []Channel
}

type ListByPartnerNamespaceOperationOptions

type ListByPartnerNamespaceOperationOptions struct {
	Filter *string
	Top    *int64
}

func DefaultListByPartnerNamespaceOperationOptions

func DefaultListByPartnerNamespaceOperationOptions() ListByPartnerNamespaceOperationOptions

func (ListByPartnerNamespaceOperationOptions) ToHeaders

func (ListByPartnerNamespaceOperationOptions) ToOData

func (ListByPartnerNamespaceOperationOptions) ToQuery

type ListByPartnerNamespaceOperationResponse

type ListByPartnerNamespaceOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Channel
}

type PartnerClientAuthentication

type PartnerClientAuthentication interface {
}

type PartnerClientAuthenticationType

type PartnerClientAuthenticationType string
const (
	PartnerClientAuthenticationTypeAzureAD PartnerClientAuthenticationType = "AzureAD"
)

func (*PartnerClientAuthenticationType) UnmarshalJSON

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

type PartnerDestinationInfo

type PartnerDestinationInfo interface {
}

type PartnerEndpointType

type PartnerEndpointType string
const (
	PartnerEndpointTypeWebHook PartnerEndpointType = "WebHook"
)

func (*PartnerEndpointType) UnmarshalJSON

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

type PartnerNamespaceId

type PartnerNamespaceId struct {
	SubscriptionId       string
	ResourceGroupName    string
	PartnerNamespaceName string
}

PartnerNamespaceId is a struct representing the Resource ID for a Partner Namespace

func NewPartnerNamespaceID

func NewPartnerNamespaceID(subscriptionId string, resourceGroupName string, partnerNamespaceName string) PartnerNamespaceId

NewPartnerNamespaceID returns a new PartnerNamespaceId struct

func ParsePartnerNamespaceID

func ParsePartnerNamespaceID(input string) (*PartnerNamespaceId, error)

ParsePartnerNamespaceID parses 'input' into a PartnerNamespaceId

func ParsePartnerNamespaceIDInsensitively

func ParsePartnerNamespaceIDInsensitively(input string) (*PartnerNamespaceId, error)

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

func (*PartnerNamespaceId) FromParseResult

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

func (PartnerNamespaceId) ID

func (id PartnerNamespaceId) ID() string

ID returns the formatted Partner Namespace ID

func (PartnerNamespaceId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Partner Namespace ID

func (PartnerNamespaceId) String

func (id PartnerNamespaceId) String() string

String returns a human-readable description of this Partner Namespace ID

type PartnerTopicInfo

type PartnerTopicInfo struct {
	AzureSubscriptionId *string        `json:"azureSubscriptionId,omitempty"`
	EventTypeInfo       *EventTypeInfo `json:"eventTypeInfo,omitempty"`
	Name                *string        `json:"name,omitempty"`
	ResourceGroupName   *string        `json:"resourceGroupName,omitempty"`
	Source              *string        `json:"source,omitempty"`
}

type PartnerUpdateDestinationInfo

type PartnerUpdateDestinationInfo interface {
}

type PartnerUpdateTopicInfo

type PartnerUpdateTopicInfo struct {
	EventTypeInfo *EventTypeInfo `json:"eventTypeInfo,omitempty"`
}

type RawPartnerClientAuthenticationImpl

type RawPartnerClientAuthenticationImpl struct {
	Type   string
	Values map[string]interface{}
}

RawPartnerClientAuthenticationImpl is returned when the Discriminated Value doesn't match any of the defined types NOTE: this should only be used when a type isn't defined for this type of Object (as a workaround) and is used only for Deserialization (e.g. this cannot be used as a Request Payload).

type RawPartnerDestinationInfoImpl

type RawPartnerDestinationInfoImpl struct {
	Type   string
	Values map[string]interface{}
}

RawPartnerDestinationInfoImpl is returned when the Discriminated Value doesn't match any of the defined types NOTE: this should only be used when a type isn't defined for this type of Object (as a workaround) and is used only for Deserialization (e.g. this cannot be used as a Request Payload).

type RawPartnerUpdateDestinationInfoImpl

type RawPartnerUpdateDestinationInfoImpl struct {
	Type   string
	Values map[string]interface{}
}

RawPartnerUpdateDestinationInfoImpl is returned when the Discriminated Value doesn't match any of the defined types NOTE: this should only be used when a type isn't defined for this type of Object (as a workaround) and is used only for Deserialization (e.g. this cannot be used as a Request Payload).

type ReadinessState

type ReadinessState string
const (
	ReadinessStateActivated      ReadinessState = "Activated"
	ReadinessStateNeverActivated ReadinessState = "NeverActivated"
)

func (*ReadinessState) UnmarshalJSON

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

type ResourceMoveChangeHistory

type ResourceMoveChangeHistory struct {
	AzureSubscriptionId *string `json:"azureSubscriptionId,omitempty"`
	ChangedTimeUtc      *string `json:"changedTimeUtc,omitempty"`
	ResourceGroupName   *string `json:"resourceGroupName,omitempty"`
}

func (*ResourceMoveChangeHistory) GetChangedTimeUtcAsTime

func (o *ResourceMoveChangeHistory) GetChangedTimeUtcAsTime() (*time.Time, error)

func (*ResourceMoveChangeHistory) SetChangedTimeUtcAsTime

func (o *ResourceMoveChangeHistory) SetChangedTimeUtcAsTime(input time.Time)

type UpdateOperationResponse

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

type WebhookPartnerDestinationInfo

type WebhookPartnerDestinationInfo struct {
	Properties *WebhookPartnerDestinationProperties `json:"properties,omitempty"`

	// Fields inherited from PartnerDestinationInfo
	AzureSubscriptionId       *string                      `json:"azureSubscriptionId,omitempty"`
	EndpointServiceContext    *string                      `json:"endpointServiceContext,omitempty"`
	Name                      *string                      `json:"name,omitempty"`
	ResourceGroupName         *string                      `json:"resourceGroupName,omitempty"`
	ResourceMoveChangeHistory *[]ResourceMoveChangeHistory `json:"resourceMoveChangeHistory,omitempty"`
}

func (WebhookPartnerDestinationInfo) MarshalJSON

func (s WebhookPartnerDestinationInfo) MarshalJSON() ([]byte, error)

type WebhookPartnerDestinationProperties

type WebhookPartnerDestinationProperties struct {
	ClientAuthentication PartnerClientAuthentication `json:"clientAuthentication"`
	EndpointBaseUrl      *string                     `json:"endpointBaseUrl,omitempty"`
	EndpointUrl          *string                     `json:"endpointUrl,omitempty"`
}

func (*WebhookPartnerDestinationProperties) UnmarshalJSON

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

type WebhookUpdatePartnerDestinationInfo

type WebhookUpdatePartnerDestinationInfo struct {
	Properties *WebhookPartnerDestinationProperties `json:"properties,omitempty"`
}

func (WebhookUpdatePartnerDestinationInfo) MarshalJSON

func (s WebhookUpdatePartnerDestinationInfo) MarshalJSON() ([]byte, error)

Jump to

Keyboard shortcuts

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