Constants
AdvisoryNotificationsService_ListNotifications_FullMethodName, AdvisoryNotificationsService_GetNotification_FullMethodName, AdvisoryNotificationsService_GetSettings_FullMethodName, AdvisoryNotificationsService_UpdateSettings_FullMethodName
const (
AdvisoryNotificationsService_ListNotifications_FullMethodName = "/google.cloud.advisorynotifications.v1.AdvisoryNotificationsService/ListNotifications"
AdvisoryNotificationsService_GetNotification_FullMethodName = "/google.cloud.advisorynotifications.v1.AdvisoryNotificationsService/GetNotification"
AdvisoryNotificationsService_GetSettings_FullMethodName = "/google.cloud.advisorynotifications.v1.AdvisoryNotificationsService/GetSettings"
AdvisoryNotificationsService_UpdateSettings_FullMethodName = "/google.cloud.advisorynotifications.v1.AdvisoryNotificationsService/UpdateSettings"
)Variables
NotificationView_name, NotificationView_value
var (
NotificationView_name = map[int32]string{
0: "NOTIFICATION_VIEW_UNSPECIFIED",
1: "BASIC",
2: "FULL",
}
NotificationView_value = map[string]int32{
"NOTIFICATION_VIEW_UNSPECIFIED": 0,
"BASIC": 1,
"FULL": 2,
}
)Enum value maps for NotificationView.
LocalizationState_name, LocalizationState_value
var (
LocalizationState_name = map[int32]string{
0: "LOCALIZATION_STATE_UNSPECIFIED",
1: "LOCALIZATION_STATE_NOT_APPLICABLE",
2: "LOCALIZATION_STATE_PENDING",
3: "LOCALIZATION_STATE_COMPLETED",
}
LocalizationState_value = map[string]int32{
"LOCALIZATION_STATE_UNSPECIFIED": 0,
"LOCALIZATION_STATE_NOT_APPLICABLE": 1,
"LOCALIZATION_STATE_PENDING": 2,
"LOCALIZATION_STATE_COMPLETED": 3,
}
)Enum value maps for LocalizationState.
NotificationType_name, NotificationType_value
var (
NotificationType_name = map[int32]string{
0: "NOTIFICATION_TYPE_UNSPECIFIED",
1: "NOTIFICATION_TYPE_SECURITY_PRIVACY_ADVISORY",
2: "NOTIFICATION_TYPE_SENSITIVE_ACTIONS",
3: "NOTIFICATION_TYPE_SECURITY_MSA",
4: "NOTIFICATION_TYPE_THREAT_HORIZONS",
}
NotificationType_value = map[string]int32{
"NOTIFICATION_TYPE_UNSPECIFIED": 0,
"NOTIFICATION_TYPE_SECURITY_PRIVACY_ADVISORY": 1,
"NOTIFICATION_TYPE_SENSITIVE_ACTIONS": 2,
"NOTIFICATION_TYPE_SECURITY_MSA": 3,
"NOTIFICATION_TYPE_THREAT_HORIZONS": 4,
}
)Enum value maps for NotificationType.
AdvisoryNotificationsService_ServiceDesc
var AdvisoryNotificationsService_ServiceDesc = grpc.ServiceDesc{
ServiceName: "google.cloud.advisorynotifications.v1.AdvisoryNotificationsService",
HandlerType: (*AdvisoryNotificationsServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "ListNotifications",
Handler: _AdvisoryNotificationsService_ListNotifications_Handler,
},
{
MethodName: "GetNotification",
Handler: _AdvisoryNotificationsService_GetNotification_Handler,
},
{
MethodName: "GetSettings",
Handler: _AdvisoryNotificationsService_GetSettings_Handler,
},
{
MethodName: "UpdateSettings",
Handler: _AdvisoryNotificationsService_UpdateSettings_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "google/cloud/advisorynotifications/v1/service.proto",
}AdvisoryNotificationsService_ServiceDesc is the grpc.ServiceDesc for AdvisoryNotificationsService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
File_google_cloud_advisorynotifications_v1_service_proto
var File_google_cloud_advisorynotifications_v1_service_proto protoreflect.FileDescriptorFunctions
func RegisterAdvisoryNotificationsServiceServer
func RegisterAdvisoryNotificationsServiceServer(s grpc.ServiceRegistrar, srv AdvisoryNotificationsServiceServer)AdvisoryNotificationsServiceClient
type AdvisoryNotificationsServiceClient interface {
// Lists notifications under a given parent.
ListNotifications(ctx context.Context, in *ListNotificationsRequest, opts ...grpc.CallOption) (*ListNotificationsResponse, error)
// Gets a notification.
GetNotification(ctx context.Context, in *GetNotificationRequest, opts ...grpc.CallOption) (*Notification, error)
// Get notification settings.
GetSettings(ctx context.Context, in *GetSettingsRequest, opts ...grpc.CallOption) (*Settings, error)
// Update notification settings.
UpdateSettings(ctx context.Context, in *UpdateSettingsRequest, opts ...grpc.CallOption) (*Settings, error)
}AdvisoryNotificationsServiceClient is the client API for AdvisoryNotificationsService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewAdvisoryNotificationsServiceClient
func NewAdvisoryNotificationsServiceClient(cc grpc.ClientConnInterface) AdvisoryNotificationsServiceClientAdvisoryNotificationsServiceServer
type AdvisoryNotificationsServiceServer interface {
// Lists notifications under a given parent.
ListNotifications(context.Context, *ListNotificationsRequest) (*ListNotificationsResponse, error)
// Gets a notification.
GetNotification(context.Context, *GetNotificationRequest) (*Notification, error)
// Get notification settings.
GetSettings(context.Context, *GetSettingsRequest) (*Settings, error)
// Update notification settings.
UpdateSettings(context.Context, *UpdateSettingsRequest) (*Settings, error)
}AdvisoryNotificationsServiceServer is the server API for AdvisoryNotificationsService service. All implementations should embed UnimplementedAdvisoryNotificationsServiceServer for forward compatibility
Attachment
type Attachment struct {
// Data type of the attachment.
//
// Types that are assignable to Data:
//
// *Attachment_Csv
Data isAttachment_Data `protobuf_oneof:"data"`
// The title of the attachment.
DisplayName string `protobuf:"bytes,1,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"`
// contains filtered or unexported fields
}Attachment with specific information about the issue.
func (*Attachment) Descriptor
func (*Attachment) Descriptor() ([]byte, []int)Deprecated: Use Attachment.ProtoReflect.Descriptor instead.
func (*Attachment) GetCsv
func (x *Attachment) GetCsv() *Csvfunc (*Attachment) GetData
func (m *Attachment) GetData() isAttachment_Datafunc (*Attachment) GetDisplayName
func (x *Attachment) GetDisplayName() stringfunc (*Attachment) ProtoMessage
func (*Attachment) ProtoMessage()func (*Attachment) ProtoReflect
func (x *Attachment) ProtoReflect() protoreflect.Messagefunc (*Attachment) Reset
func (x *Attachment) Reset()func (*Attachment) String
func (x *Attachment) String() stringAttachment_Csv
type Attachment_Csv struct {
// A CSV file attachment. Max size is 10 MB.
Csv *Csv `protobuf:"bytes,2,opt,name=csv,proto3,oneof"`
}Csv
type Csv struct {
// The list of headers for data columns in a CSV file.
Headers []string `protobuf:"bytes,1,rep,name=headers,proto3" json:"headers,omitempty"`
// The list of data rows in a CSV file, as string arrays rather than as a
// single comma-separated string.
DataRows []*Csv_CsvRow `protobuf:"bytes,2,rep,name=data_rows,json=dataRows,proto3" json:"data_rows,omitempty"`
// contains filtered or unexported fields
}A representation of a CSV file attachment, as a list of column headers and a list of data rows.
func (*Csv) Descriptor
Deprecated: Use Csv.ProtoReflect.Descriptor instead.
func (*Csv) GetDataRows
func (x *Csv) GetDataRows() []*Csv_CsvRowfunc (*Csv) GetHeaders
func (*Csv) ProtoMessage
func (*Csv) ProtoMessage()func (*Csv) ProtoReflect
func (x *Csv) ProtoReflect() protoreflect.Messagefunc (*Csv) Reset
func (x *Csv) Reset()func (*Csv) String
Csv_CsvRow
type Csv_CsvRow struct {
// The data entries in a CSV file row, as a string array rather than a
// single comma-separated string.
Entries []string `protobuf:"bytes,1,rep,name=entries,proto3" json:"entries,omitempty"`
// contains filtered or unexported fields
}A representation of a single data row in a CSV file.
func (*Csv_CsvRow) Descriptor
func (*Csv_CsvRow) Descriptor() ([]byte, []int)Deprecated: Use Csv_CsvRow.ProtoReflect.Descriptor instead.
func (*Csv_CsvRow) GetEntries
func (x *Csv_CsvRow) GetEntries() []stringfunc (*Csv_CsvRow) ProtoMessage
func (*Csv_CsvRow) ProtoMessage()func (*Csv_CsvRow) ProtoReflect
func (x *Csv_CsvRow) ProtoReflect() protoreflect.Messagefunc (*Csv_CsvRow) Reset
func (x *Csv_CsvRow) Reset()func (*Csv_CsvRow) String
func (x *Csv_CsvRow) String() stringGetNotificationRequest
type GetNotificationRequest struct {
// Required. A name of the notification to retrieve.
// Format:
// organizations/{organization}/locations/{location}/notifications/{notification}
// or projects/{projects}/locations/{location}/notifications/{notification}.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// ISO code for requested localization language. If unset, will be
// interpereted as "en". If the requested language is valid, but not supported
// for this notification, English will be returned with an "Not applicable"
// LocalizationState. If the ISO code is invalid (i.e. not a real language),
// this RPC will throw an error.
LanguageCode string `protobuf:"bytes,5,opt,name=language_code,json=languageCode,proto3" json:"language_code,omitempty"`
// contains filtered or unexported fields
}Request for fetching a notification.
func (*GetNotificationRequest) Descriptor
func (*GetNotificationRequest) Descriptor() ([]byte, []int)Deprecated: Use GetNotificationRequest.ProtoReflect.Descriptor instead.
func (*GetNotificationRequest) GetLanguageCode
func (x *GetNotificationRequest) GetLanguageCode() stringfunc (*GetNotificationRequest) GetName
func (x *GetNotificationRequest) GetName() stringfunc (*GetNotificationRequest) ProtoMessage
func (*GetNotificationRequest) ProtoMessage()func (*GetNotificationRequest) ProtoReflect
func (x *GetNotificationRequest) ProtoReflect() protoreflect.Messagefunc (*GetNotificationRequest) Reset
func (x *GetNotificationRequest) Reset()func (*GetNotificationRequest) String
func (x *GetNotificationRequest) String() stringGetSettingsRequest
type GetSettingsRequest struct {
// Required. The resource name of the settings to retrieve.
// Format:
// organizations/{organization}/locations/{location}/settings or
// projects/{projects}/locations/{location}/settings.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// contains filtered or unexported fields
}Request of GetSettings endpoint.
func (*GetSettingsRequest) Descriptor
func (*GetSettingsRequest) Descriptor() ([]byte, []int)Deprecated: Use GetSettingsRequest.ProtoReflect.Descriptor instead.
func (*GetSettingsRequest) GetName
func (x *GetSettingsRequest) GetName() stringfunc (*GetSettingsRequest) ProtoMessage
func (*GetSettingsRequest) ProtoMessage()func (*GetSettingsRequest) ProtoReflect
func (x *GetSettingsRequest) ProtoReflect() protoreflect.Messagefunc (*GetSettingsRequest) Reset
func (x *GetSettingsRequest) Reset()func (*GetSettingsRequest) String
func (x *GetSettingsRequest) String() stringListNotificationsRequest
type ListNotificationsRequest struct {
// Required. The parent, which owns this collection of notifications.
// Must be of the form "organizations/{organization}/locations/{location}"
// or "projects/{project}/locations/{location}".
Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
// The maximum number of notifications to return. The service may return
// fewer than this value. If unspecified or equal to 0, at most 50
// notifications will be returned. The maximum value is 50; values above 50
// will be coerced to 50.
PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
// A page token returned from a previous request.
// When paginating, all other parameters provided in the request
// must match the call that returned the page token.
PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
// Specifies which parts of the notification resource should be returned
// in the response.
View NotificationView `protobuf:"varint,4,opt,name=view,proto3,enum=google.cloud.advisorynotifications.v1.NotificationView" json:"view,omitempty"`
// ISO code for requested localization language. If unset, will be
// interpereted as "en". If the requested language is valid, but not supported
// for this notification, English will be returned with an "Not applicable"
// LocalizationState. If the ISO code is invalid (i.e. not a real language),
// this RPC will throw an error.
LanguageCode string `protobuf:"bytes,5,opt,name=language_code,json=languageCode,proto3" json:"language_code,omitempty"`
// contains filtered or unexported fields
}Request for fetching all notifications for a given parent.
func (*ListNotificationsRequest) Descriptor
func (*ListNotificationsRequest) Descriptor() ([]byte, []int)Deprecated: Use ListNotificationsRequest.ProtoReflect.Descriptor instead.
func (*ListNotificationsRequest) GetLanguageCode
func (x *ListNotificationsRequest) GetLanguageCode() stringfunc (*ListNotificationsRequest) GetPageSize
func (x *ListNotificationsRequest) GetPageSize() int32func (*ListNotificationsRequest) GetPageToken
func (x *ListNotificationsRequest) GetPageToken() stringfunc (*ListNotificationsRequest) GetParent
func (x *ListNotificationsRequest) GetParent() stringfunc (*ListNotificationsRequest) GetView
func (x *ListNotificationsRequest) GetView() NotificationViewfunc (*ListNotificationsRequest) ProtoMessage
func (*ListNotificationsRequest) ProtoMessage()func (*ListNotificationsRequest) ProtoReflect
func (x *ListNotificationsRequest) ProtoReflect() protoreflect.Messagefunc (*ListNotificationsRequest) Reset
func (x *ListNotificationsRequest) Reset()func (*ListNotificationsRequest) String
func (x *ListNotificationsRequest) String() stringListNotificationsResponse
type ListNotificationsResponse struct {
// List of notifications under a given parent.
Notifications []*Notification `protobuf:"bytes,1,rep,name=notifications,proto3" json:"notifications,omitempty"`
// A token, which can be sent as `page_token` to retrieve the next page.
// If this field is omitted, there are no subsequent pages.
NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
// Estimation of a total number of notifications.
TotalSize int32 `protobuf:"varint,3,opt,name=total_size,json=totalSize,proto3" json:"total_size,omitempty"`
// contains filtered or unexported fields
}Response of ListNotifications endpoint.
func (*ListNotificationsResponse) Descriptor
func (*ListNotificationsResponse) Descriptor() ([]byte, []int)Deprecated: Use ListNotificationsResponse.ProtoReflect.Descriptor instead.
func (*ListNotificationsResponse) GetNextPageToken
func (x *ListNotificationsResponse) GetNextPageToken() stringfunc (*ListNotificationsResponse) GetNotifications
func (x *ListNotificationsResponse) GetNotifications() []*Notificationfunc (*ListNotificationsResponse) GetTotalSize
func (x *ListNotificationsResponse) GetTotalSize() int32func (*ListNotificationsResponse) ProtoMessage
func (*ListNotificationsResponse) ProtoMessage()func (*ListNotificationsResponse) ProtoReflect
func (x *ListNotificationsResponse) ProtoReflect() protoreflect.Messagefunc (*ListNotificationsResponse) Reset
func (x *ListNotificationsResponse) Reset()func (*ListNotificationsResponse) String
func (x *ListNotificationsResponse) String() stringLocalizationState
type LocalizationState int32Status of localized text.
LocalizationState_LOCALIZATION_STATE_UNSPECIFIED, LocalizationState_LOCALIZATION_STATE_NOT_APPLICABLE, LocalizationState_LOCALIZATION_STATE_PENDING, LocalizationState_LOCALIZATION_STATE_COMPLETED
const (
// Not used.
LocalizationState_LOCALIZATION_STATE_UNSPECIFIED LocalizationState = 0
// Localization is not applicable for requested language. This can happen
// when:
// - The requested language was not supported by Advisory Notifications at the
// time of localization (including notifications created before the
// localization feature was launched).
// - The requested language is English, so only the English text is returned.
LocalizationState_LOCALIZATION_STATE_NOT_APPLICABLE LocalizationState = 1
// Localization for requested language is in progress, and not ready yet.
LocalizationState_LOCALIZATION_STATE_PENDING LocalizationState = 2
// Localization for requested language is completed.
LocalizationState_LOCALIZATION_STATE_COMPLETED LocalizationState = 3
)func (LocalizationState) Descriptor
func (LocalizationState) Descriptor() protoreflect.EnumDescriptorfunc (LocalizationState) Enum
func (x LocalizationState) Enum() *LocalizationStatefunc (LocalizationState) EnumDescriptor
func (LocalizationState) EnumDescriptor() ([]byte, []int)Deprecated: Use LocalizationState.Descriptor instead.
func (LocalizationState) Number
func (x LocalizationState) Number() protoreflect.EnumNumberfunc (LocalizationState) String
func (x LocalizationState) String() stringfunc (LocalizationState) Type
func (LocalizationState) Type() protoreflect.EnumTypeMessage
type Message struct {
// The message content.
Body *Message_Body `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"`
// The attachments to download.
Attachments []*Attachment `protobuf:"bytes,2,rep,name=attachments,proto3" json:"attachments,omitempty"`
// The Message creation timestamp.
CreateTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
// Time when Message was localized
LocalizationTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=localization_time,json=localizationTime,proto3" json:"localization_time,omitempty"`
// contains filtered or unexported fields
}A message which contains notification details.
func (*Message) Descriptor
Deprecated: Use Message.ProtoReflect.Descriptor instead.
func (*Message) GetAttachments
func (x *Message) GetAttachments() []*Attachmentfunc (*Message) GetBody
func (x *Message) GetBody() *Message_Bodyfunc (*Message) GetCreateTime
func (x *Message) GetCreateTime() *timestamppb.Timestampfunc (*Message) GetLocalizationTime
func (x *Message) GetLocalizationTime() *timestamppb.Timestampfunc (*Message) ProtoMessage
func (*Message) ProtoMessage()func (*Message) ProtoReflect
func (x *Message) ProtoReflect() protoreflect.Messagefunc (*Message) Reset
func (x *Message) Reset()func (*Message) String
Message_Body
type Message_Body struct {
// The text content of the message body.
Text *Text `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"`
// contains filtered or unexported fields
}A message body containing text.
func (*Message_Body) Descriptor
func (*Message_Body) Descriptor() ([]byte, []int)Deprecated: Use Message_Body.ProtoReflect.Descriptor instead.
func (*Message_Body) GetText
func (x *Message_Body) GetText() *Textfunc (*Message_Body) ProtoMessage
func (*Message_Body) ProtoMessage()func (*Message_Body) ProtoReflect
func (x *Message_Body) ProtoReflect() protoreflect.Messagefunc (*Message_Body) Reset
func (x *Message_Body) Reset()func (*Message_Body) String
func (x *Message_Body) String() stringNotification
type Notification struct {
// The resource name of the notification.
// Format:
// organizations/{organization}/locations/{location}/notifications/{notification}
// or projects/{project}/locations/{location}/notifications/{notification}.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// The subject line of the notification.
Subject *Subject `protobuf:"bytes,2,opt,name=subject,proto3" json:"subject,omitempty"`
// A list of messages in the notification.
Messages []*Message `protobuf:"bytes,3,rep,name=messages,proto3" json:"messages,omitempty"`
// Output only. Time the notification was created.
CreateTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
// Type of notification
NotificationType NotificationType `protobuf:"varint,12,opt,name=notification_type,json=notificationType,proto3,enum=google.cloud.advisorynotifications.v1.NotificationType" json:"notification_type,omitempty"`
// contains filtered or unexported fields
}A notification object for notifying customers about security and privacy issues.
func (*Notification) Descriptor
func (*Notification) Descriptor() ([]byte, []int)Deprecated: Use Notification.ProtoReflect.Descriptor instead.
func (*Notification) GetCreateTime
func (x *Notification) GetCreateTime() *timestamppb.Timestampfunc (*Notification) GetMessages
func (x *Notification) GetMessages() []*Messagefunc (*Notification) GetName
func (x *Notification) GetName() stringfunc (*Notification) GetNotificationType
func (x *Notification) GetNotificationType() NotificationTypefunc (*Notification) GetSubject
func (x *Notification) GetSubject() *Subjectfunc (*Notification) ProtoMessage
func (*Notification) ProtoMessage()func (*Notification) ProtoReflect
func (x *Notification) ProtoReflect() protoreflect.Messagefunc (*Notification) Reset
func (x *Notification) Reset()func (*Notification) String
func (x *Notification) String() stringNotificationSettings
type NotificationSettings struct {
// Whether the associated NotificationType is enabled.
Enabled bool `protobuf:"varint,1,opt,name=enabled,proto3" json:"enabled,omitempty"`
// contains filtered or unexported fields
}Settings for each NotificationType.
func (*NotificationSettings) Descriptor
func (*NotificationSettings) Descriptor() ([]byte, []int)Deprecated: Use NotificationSettings.ProtoReflect.Descriptor instead.
func (*NotificationSettings) GetEnabled
func (x *NotificationSettings) GetEnabled() boolfunc (*NotificationSettings) ProtoMessage
func (*NotificationSettings) ProtoMessage()func (*NotificationSettings) ProtoReflect
func (x *NotificationSettings) ProtoReflect() protoreflect.Messagefunc (*NotificationSettings) Reset
func (x *NotificationSettings) Reset()func (*NotificationSettings) String
func (x *NotificationSettings) String() stringNotificationType
type NotificationType int32Type of notification
NotificationType_NOTIFICATION_TYPE_UNSPECIFIED, NotificationType_NOTIFICATION_TYPE_SECURITY_PRIVACY_ADVISORY, NotificationType_NOTIFICATION_TYPE_SENSITIVE_ACTIONS, NotificationType_NOTIFICATION_TYPE_SECURITY_MSA, NotificationType_NOTIFICATION_TYPE_THREAT_HORIZONS
const (
// Default type
NotificationType_NOTIFICATION_TYPE_UNSPECIFIED NotificationType = 0
// Security and privacy advisory notifications
NotificationType_NOTIFICATION_TYPE_SECURITY_PRIVACY_ADVISORY NotificationType = 1
// Sensitive action notifications
NotificationType_NOTIFICATION_TYPE_SENSITIVE_ACTIONS NotificationType = 2
// General security MSA
NotificationType_NOTIFICATION_TYPE_SECURITY_MSA NotificationType = 3
// Threat horizons MSA
NotificationType_NOTIFICATION_TYPE_THREAT_HORIZONS NotificationType = 4
)func (NotificationType) Descriptor
func (NotificationType) Descriptor() protoreflect.EnumDescriptorfunc (NotificationType) Enum
func (x NotificationType) Enum() *NotificationTypefunc (NotificationType) EnumDescriptor
func (NotificationType) EnumDescriptor() ([]byte, []int)Deprecated: Use NotificationType.Descriptor instead.
func (NotificationType) Number
func (x NotificationType) Number() protoreflect.EnumNumberfunc (NotificationType) String
func (x NotificationType) String() stringfunc (NotificationType) Type
func (NotificationType) Type() protoreflect.EnumTypeNotificationView
type NotificationView int32Notification view.
NotificationView_NOTIFICATION_VIEW_UNSPECIFIED, NotificationView_BASIC, NotificationView_FULL
const (
// Not specified, equivalent to BASIC.
NotificationView_NOTIFICATION_VIEW_UNSPECIFIED NotificationView = 0
// Server responses only include title, creation time and Notification ID.
// Note: for internal use responses also include the last update time,
// the latest message text and whether notification has attachments.
NotificationView_BASIC NotificationView = 1
// Include everything.
NotificationView_FULL NotificationView = 2
)func (NotificationView) Descriptor
func (NotificationView) Descriptor() protoreflect.EnumDescriptorfunc (NotificationView) Enum
func (x NotificationView) Enum() *NotificationViewfunc (NotificationView) EnumDescriptor
func (NotificationView) EnumDescriptor() ([]byte, []int)Deprecated: Use NotificationView.Descriptor instead.
func (NotificationView) Number
func (x NotificationView) Number() protoreflect.EnumNumberfunc (NotificationView) String
func (x NotificationView) String() stringfunc (NotificationView) Type
func (NotificationView) Type() protoreflect.EnumTypeSettings
type Settings struct {
// Identifier. The resource name of the settings to retrieve.
// Format:
// organizations/{organization}/locations/{location}/settings or
// projects/{projects}/locations/{location}/settings.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Required. Map of each notification type and its settings to get/set all
// settings at once. The server will validate the value for each notification
// type.
NotificationSettings map[string]*NotificationSettings `protobuf:"bytes,2,rep,name=notification_settings,json=notificationSettings,proto3" json:"notification_settings,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
// Required. Fingerprint for optimistic concurrency returned in Get requests.
// Must be provided for Update requests. If the value provided does not match
// the value known to the server, ABORTED will be thrown, and the client
// should retry the read-modify-write cycle.
Etag string `protobuf:"bytes,3,opt,name=etag,proto3" json:"etag,omitempty"`
// contains filtered or unexported fields
}Settings for Advisory Notifications.
func (*Settings) Descriptor
Deprecated: Use Settings.ProtoReflect.Descriptor instead.
func (*Settings) GetEtag
func (*Settings) GetName
func (*Settings) GetNotificationSettings
func (x *Settings) GetNotificationSettings() map[string]*NotificationSettingsfunc (*Settings) ProtoMessage
func (*Settings) ProtoMessage()func (*Settings) ProtoReflect
func (x *Settings) ProtoReflect() protoreflect.Messagefunc (*Settings) Reset
func (x *Settings) Reset()func (*Settings) String
Subject
type Subject struct {
// The text content.
Text *Text `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"`
// contains filtered or unexported fields
}A subject line of a notification.
func (*Subject) Descriptor
Deprecated: Use Subject.ProtoReflect.Descriptor instead.
func (*Subject) GetText
func (*Subject) ProtoMessage
func (*Subject) ProtoMessage()func (*Subject) ProtoReflect
func (x *Subject) ProtoReflect() protoreflect.Messagefunc (*Subject) Reset
func (x *Subject) Reset()func (*Subject) String
Text
type Text struct {
// The English copy.
EnText string `protobuf:"bytes,1,opt,name=en_text,json=enText,proto3" json:"en_text,omitempty"`
// The requested localized copy (if applicable).
LocalizedText string `protobuf:"bytes,2,opt,name=localized_text,json=localizedText,proto3" json:"localized_text,omitempty"`
// Status of the localization.
LocalizationState LocalizationState `protobuf:"varint,3,opt,name=localization_state,json=localizationState,proto3,enum=google.cloud.advisorynotifications.v1.LocalizationState" json:"localization_state,omitempty"`
// contains filtered or unexported fields
}A text object containing the English text and its localized copies.
func (*Text) Descriptor
Deprecated: Use Text.ProtoReflect.Descriptor instead.
func (*Text) GetEnText
func (*Text) GetLocalizationState
func (x *Text) GetLocalizationState() LocalizationStatefunc (*Text) GetLocalizedText
func (*Text) ProtoMessage
func (*Text) ProtoMessage()func (*Text) ProtoReflect
func (x *Text) ProtoReflect() protoreflect.Messagefunc (*Text) Reset
func (x *Text) Reset()func (*Text) String
UnimplementedAdvisoryNotificationsServiceServer
type UnimplementedAdvisoryNotificationsServiceServer struct {
}UnimplementedAdvisoryNotificationsServiceServer should be embedded to have forward compatible implementations.
func (UnimplementedAdvisoryNotificationsServiceServer) GetNotification
func (UnimplementedAdvisoryNotificationsServiceServer) GetNotification(context.Context, *GetNotificationRequest) (*Notification, error)func (UnimplementedAdvisoryNotificationsServiceServer) GetSettings
func (UnimplementedAdvisoryNotificationsServiceServer) GetSettings(context.Context, *GetSettingsRequest) (*Settings, error)func (UnimplementedAdvisoryNotificationsServiceServer) ListNotifications
func (UnimplementedAdvisoryNotificationsServiceServer) ListNotifications(context.Context, *ListNotificationsRequest) (*ListNotificationsResponse, error)func (UnimplementedAdvisoryNotificationsServiceServer) UpdateSettings
func (UnimplementedAdvisoryNotificationsServiceServer) UpdateSettings(context.Context, *UpdateSettingsRequest) (*Settings, error)UnsafeAdvisoryNotificationsServiceServer
type UnsafeAdvisoryNotificationsServiceServer interface {
// contains filtered or unexported methods
}UnsafeAdvisoryNotificationsServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AdvisoryNotificationsServiceServer will result in compilation errors.
UpdateSettingsRequest
type UpdateSettingsRequest struct {
// Required. New settings.
Settings *Settings `protobuf:"bytes,1,opt,name=settings,proto3" json:"settings,omitempty"`
// contains filtered or unexported fields
}Request of UpdateSettings endpoint.
func (*UpdateSettingsRequest) Descriptor
func (*UpdateSettingsRequest) Descriptor() ([]byte, []int)Deprecated: Use UpdateSettingsRequest.ProtoReflect.Descriptor instead.
func (*UpdateSettingsRequest) GetSettings
func (x *UpdateSettingsRequest) GetSettings() *Settingsfunc (*UpdateSettingsRequest) ProtoMessage
func (*UpdateSettingsRequest) ProtoMessage()func (*UpdateSettingsRequest) ProtoReflect
func (x *UpdateSettingsRequest) ProtoReflect() protoreflect.Messagefunc (*UpdateSettingsRequest) Reset
func (x *UpdateSettingsRequest) Reset()func (*UpdateSettingsRequest) String
func (x *UpdateSettingsRequest) String() string