keyevent

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jun 26, 2023 License: Apache-2.0 Imports: 4 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Delete

func Delete(client *golangsdk.ServiceClient, opts DeleteOpts) (err error)

Types

type CreateNotificationOpts

type CreateNotificationOpts struct {
	// Notification name.
	NotificationName string `json:"notification_name"`
	// Operation type. Possible options include complete and customized.
	// If you choose complete, you do not need to specify operations and notify_user_list,
	// and notifications will be sent when any supported operations occur on any of the connected cloud services.
	// If you choose customized, notifications will be sent when operations defined in operations occur.
	// Enumerated values:
	// complete
	// customized
	OperationType string `json:"operation_type"`
	// Operation list.
	Operations []Operations `json:"operations,omitempty"`
	// List of users whose operations will trigger notifications.
	// Currently, up to 50 users in 10 user groups can be configured.
	NotifyUserList []NotificationUsers `json:"notify_user_list,omitempty"`
	// Topic URN.
	// To obtain the topic_urn, call the SMN API for querying topics.
	// Example URN: urn:smn:regionId:f96188c7ccaf4ffba0c9aa149ab2bd57:test_topic_v2
	TopicId string `json:"topic_id,omitempty"`
}

type DeleteOpts

type DeleteOpts struct {
	NotificationId []string `q:"notification_id"`
}

type ListNotificationsOpts

type ListNotificationsOpts struct {
	// Notification type.
	// Enumerated value:
	// smn
	NotificationType string
	// Notification name. If this parameter is not specified, all key event notifications configured in the current tenant account are returned.
	NotificationName string `q:"notification_name,omitempty"`
}

type NotificationResponse

type NotificationResponse struct {
	// Notification name.
	NotificationName string `json:"notification_name,omitempty"`
	// Operation type. Possible options include complete and customized.
	// Enumerated values:
	// customized
	// complete
	OperationType string `json:"operation_type,omitempty"`
	// Operation list.
	Operations []Operations `json:"operations,omitempty"`
	// List of users whose operations will trigger notifications.
	// Currently, up to 50 users in 10 user groups can be configured.
	NotifyUserList []NotificationUsers `json:"notify_user_list,omitempty"`
	// Notification status. Possible options include enabled and disabled.
	// Enumerated values:
	// enabled
	// disabled
	Status string `json:"status,omitempty"`
	// Unique resource ID of an SMN topic. You can obtain the ID by querying the topic list.
	TopicId string `json:"topic_id,omitempty"`
	// Unique notification ID.
	NotificationId string `json:"notification_id,omitempty"`
	// Notification type.
	// Enumerated value:
	// smn
	NotificationType string `json:"notification_type,omitempty"`
	// Project ID.
	ProjectId string `json:"project_id,omitempty"`
	// Time when a notification rule was created.
	CreateTime int64 `json:"create_time,omitempty"`
}

type NotificationUsers

type NotificationUsers struct {
	// IAM user group.
	UserGroup string `json:"user_group"`
	// IAM user.
	UserList []string `json:"user_list"`
}

type Operations

type Operations struct {
	// Cloud service. The value must be the acronym of a cloud service that has been connected with CTS. It is a word composed of uppercase letters.
	// For cloud services that can be connected with CTS, see section "Supported Services and Operations" in the Cloud Trace Service User Guide.
	ServiceType string `json:"service_type"`
	// Resource type.
	ResourceType string `json:"resource_type"`
	// Trace name.
	TraceNames []string `json:"trace_names"`
}

type UpdateNotificationOpts

type UpdateNotificationOpts struct {
	// Notification name.
	NotificationName string `json:"notification_name"`
	// Operation type. Possible options include complete and customized.
	// If you choose complete, you do not need to specify operations and notify_user_list,
	// and notifications will be sent when any supported operations occur on any of the connected cloud services.
	// If you choose customized, notifications will be sent when operations defined in operations occur.
	// Enumerated values:
	// complete
	// customized
	OperationType string `json:"operation_type"`
	// Operation list.
	Operations []Operations `json:"operations,omitempty"`
	// List of users whose operations will trigger notifications.
	// Currently, up to 50 users in 10 user groups can be configured.
	NotifyUserList []NotificationUsers `json:"notify_user_list,omitempty"`
	// Notification status. Possible options include enabled and disabled.
	// Enumerated values:
	// enabled
	// disabled
	Status string `json:"status"`
	// Topic URN.
	// To obtain the topic_urn, call the SMN API for querying topics.
	// Example URN: urn:smn:regionId:f96188c7ccaf4ffba0c9aa149ab2bd57:test_topic_v2
	TopicId string `json:"topic_id,omitempty"`
	// Notification ID.
	NotificationId string `json:"notification_id"`
}

Jump to

Keyboard shortcuts

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