README ¶
github.com/hashicorp/go-azure-sdk/resource-manager/apimanagement/2021-08-01/notification
Documentation
The notification
SDK allows for interaction with the Azure Resource Manager Service apimanagement
(API Version 2021-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/2021-08-01/notification"
Client Initialization
client := notification.NewNotificationClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: NotificationClient.CreateOrUpdate
ctx := context.TODO()
id := notification.NewNotificationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "AccountClosedPublisher")
read, err := client.CreateOrUpdate(ctx, id, notification.DefaultCreateOrUpdateOperationOptions())
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Example Usage: NotificationClient.Get
ctx := context.TODO()
id := notification.NewNotificationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "AccountClosedPublisher")
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: NotificationClient.ListByService
ctx := context.TODO()
id := notification.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")
// alternatively `client.ListByService(ctx, id, notification.DefaultListByServiceOperationOptions())` can be used to do batched pagination
items, err := client.ListByServiceComplete(ctx, id, notification.DefaultListByServiceOperationOptions())
if err != nil {
// handle the error
}
for _, item := range items {
// do something
}
Documentation ¶
Index ¶
- func PossibleValuesForNotificationName() []string
- func ValidateNotificationID(input interface{}, key string) (warnings []string, errors []error)
- func ValidateServiceID(input interface{}, key string) (warnings []string, errors []error)
- type CreateOrUpdateOperationOptions
- type CreateOrUpdateOperationResponse
- type GetOperationResponse
- type ListByServiceCompleteResult
- type ListByServiceOperationOptions
- type ListByServiceOperationResponse
- type NotificationClient
- func (c NotificationClient) CreateOrUpdate(ctx context.Context, id NotificationId, options CreateOrUpdateOperationOptions) (result CreateOrUpdateOperationResponse, err error)
- func (c NotificationClient) Get(ctx context.Context, id NotificationId) (result GetOperationResponse, err error)
- func (c NotificationClient) ListByService(ctx context.Context, id ServiceId, options ListByServiceOperationOptions) (resp ListByServiceOperationResponse, err error)
- func (c NotificationClient) ListByServiceComplete(ctx context.Context, id ServiceId, options ListByServiceOperationOptions) (ListByServiceCompleteResult, error)
- func (c NotificationClient) ListByServiceCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListByServiceOperationOptions, ...) (resp ListByServiceCompleteResult, err error)
- type NotificationContract
- type NotificationContractOperationPredicate
- type NotificationContractProperties
- type NotificationId
- type NotificationName
- type RecipientsContractProperties
- type ServiceId
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PossibleValuesForNotificationName ¶
func PossibleValuesForNotificationName() []string
func ValidateNotificationID ¶
ValidateNotificationID checks that 'input' can be parsed as a Notification ID
func ValidateServiceID ¶
ValidateServiceID checks that 'input' can be parsed as a Service ID
Types ¶
type CreateOrUpdateOperationOptions ¶
type CreateOrUpdateOperationOptions struct {
IfMatch *string
}
func DefaultCreateOrUpdateOperationOptions ¶
func DefaultCreateOrUpdateOperationOptions() CreateOrUpdateOperationOptions
type CreateOrUpdateOperationResponse ¶
type CreateOrUpdateOperationResponse struct { HttpResponse *http.Response Model *NotificationContract }
type GetOperationResponse ¶
type GetOperationResponse struct { HttpResponse *http.Response Model *NotificationContract }
type ListByServiceCompleteResult ¶
type ListByServiceCompleteResult struct {
Items []NotificationContract
}
type ListByServiceOperationOptions ¶
func DefaultListByServiceOperationOptions ¶
func DefaultListByServiceOperationOptions() ListByServiceOperationOptions
type ListByServiceOperationResponse ¶
type ListByServiceOperationResponse struct { HttpResponse *http.Response Model *[]NotificationContract // contains filtered or unexported fields }
func (ListByServiceOperationResponse) HasMore ¶
func (r ListByServiceOperationResponse) HasMore() bool
func (ListByServiceOperationResponse) LoadMore ¶
func (r ListByServiceOperationResponse) LoadMore(ctx context.Context) (resp ListByServiceOperationResponse, err error)
type NotificationClient ¶
func NewNotificationClientWithBaseURI ¶
func NewNotificationClientWithBaseURI(endpoint string) NotificationClient
func (NotificationClient) CreateOrUpdate ¶
func (c NotificationClient) CreateOrUpdate(ctx context.Context, id NotificationId, options CreateOrUpdateOperationOptions) (result CreateOrUpdateOperationResponse, err error)
CreateOrUpdate ...
func (NotificationClient) Get ¶
func (c NotificationClient) Get(ctx context.Context, id NotificationId) (result GetOperationResponse, err error)
Get ...
func (NotificationClient) ListByService ¶
func (c NotificationClient) ListByService(ctx context.Context, id ServiceId, options ListByServiceOperationOptions) (resp ListByServiceOperationResponse, err error)
ListByService ...
func (NotificationClient) ListByServiceComplete ¶
func (c NotificationClient) ListByServiceComplete(ctx context.Context, id ServiceId, options ListByServiceOperationOptions) (ListByServiceCompleteResult, error)
ListByServiceComplete retrieves all of the results into a single object
func (NotificationClient) ListByServiceCompleteMatchingPredicate ¶
func (c NotificationClient) ListByServiceCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListByServiceOperationOptions, predicate NotificationContractOperationPredicate) (resp ListByServiceCompleteResult, err error)
ListByServiceCompleteMatchingPredicate retrieves all of the results and then applied the predicate
type NotificationContract ¶
type NotificationContract struct { Id *string `json:"id,omitempty"` Name *string `json:"name,omitempty"` Properties *NotificationContractProperties `json:"properties,omitempty"` Type *string `json:"type,omitempty"` }
type NotificationContractOperationPredicate ¶
func (NotificationContractOperationPredicate) Matches ¶
func (p NotificationContractOperationPredicate) Matches(input NotificationContract) bool
type NotificationContractProperties ¶
type NotificationContractProperties struct { Description *string `json:"description,omitempty"` Recipients *RecipientsContractProperties `json:"recipients,omitempty"` Title string `json:"title"` }
type NotificationId ¶
type NotificationId struct { SubscriptionId string ResourceGroupName string ServiceName string NotificationName NotificationName }
NotificationId is a struct representing the Resource ID for a Notification
func NewNotificationID ¶
func NewNotificationID(subscriptionId string, resourceGroupName string, serviceName string, notificationName NotificationName) NotificationId
NewNotificationID returns a new NotificationId struct
func ParseNotificationID ¶
func ParseNotificationID(input string) (*NotificationId, error)
ParseNotificationID parses 'input' into a NotificationId
func ParseNotificationIDInsensitively ¶
func ParseNotificationIDInsensitively(input string) (*NotificationId, error)
ParseNotificationIDInsensitively parses 'input' case-insensitively into a NotificationId note: this method should only be used for API response data and not user input
func (NotificationId) ID ¶
func (id NotificationId) ID() string
ID returns the formatted Notification ID
func (NotificationId) Segments ¶
func (id NotificationId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Notification ID
func (NotificationId) String ¶
func (id NotificationId) String() string
String returns a human-readable description of this Notification ID
type NotificationName ¶
type NotificationName string
const ( NotificationNameAccountClosedPublisher NotificationName = "AccountClosedPublisher" NotificationNameBCC NotificationName = "BCC" NotificationNameNewApplicationNotificationMessage NotificationName = "NewApplicationNotificationMessage" NotificationNameNewIssuePublisherNotificationMessage NotificationName = "NewIssuePublisherNotificationMessage" NotificationNamePurchasePublisherNotificationMessage NotificationName = "PurchasePublisherNotificationMessage" NotificationNameQuotaLimitApproachingPublisherNotificationMessage NotificationName = "QuotaLimitApproachingPublisherNotificationMessage" NotificationNameRequestPublisherNotificationMessage NotificationName = "RequestPublisherNotificationMessage" )
type ServiceId ¶
ServiceId is a struct representing the Resource ID for a Service
func NewServiceID ¶
NewServiceID returns a new ServiceId struct
func ParseServiceID ¶
ParseServiceID parses 'input' into a ServiceId
func ParseServiceIDInsensitively ¶
ParseServiceIDInsensitively parses 'input' case-insensitively into a ServiceId note: this method should only be used for API response data and not user input
func (ServiceId) Segments ¶
func (id ServiceId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Service ID