Class: Google::Apis::SecuritycenterV1::NotificationConfig

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/securitycenter_v1/classes.rb,
lib/google/apis/securitycenter_v1/representations.rb,
lib/google/apis/securitycenter_v1/representations.rb

Overview

Cloud Security Command Center (Cloud SCC) notification configs. A notification config is a Cloud SCC resource that contains the configuration to send notifications for create/update events of findings, assets and etc.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ NotificationConfig

Returns a new instance of NotificationConfig.



10172
10173
10174
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 10172

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#descriptionString

The description of the notification config (max of 1024 characters). Corresponds to the JSON property description

Returns:

  • (String)


10143
10144
10145
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 10143

def description
  @description
end

#nameString

The relative resource name of this notification config. See: https://cloud. google.com/apis/design/resource_names#relative_resource_name Example: " organizations/organization_id/notificationConfigs/notify_public_bucket", " folders/folder_id/notificationConfigs/notify_public_bucket", or "projects/ project_id/notificationConfigs/notify_public_bucket". Corresponds to the JSON property name

Returns:

  • (String)


10152
10153
10154
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 10152

def name
  @name
end

#pubsub_topicString

The Pub/Sub topic to send notifications to. Its format is "projects/[ project_id]/topics/[topic]". Corresponds to the JSON property pubsubTopic

Returns:

  • (String)


10158
10159
10160
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 10158

def pubsub_topic
  @pubsub_topic
end

#service_accountString

Output only. The service account that needs "pubsub.topics.publish" permission to publish to the Pub/Sub topic. Corresponds to the JSON property serviceAccount

Returns:

  • (String)


10164
10165
10166
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 10164

def 
  @service_account
end

#streaming_configGoogle::Apis::SecuritycenterV1::StreamingConfig

The config for streaming-based notifications, which send each event as soon as it is detected. Corresponds to the JSON property streamingConfig



10170
10171
10172
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 10170

def streaming_config
  @streaming_config
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



10177
10178
10179
10180
10181
10182
10183
# File 'lib/google/apis/securitycenter_v1/classes.rb', line 10177

def update!(**args)
  @description = args[:description] if args.key?(:description)
  @name = args[:name] if args.key?(:name)
  @pubsub_topic = args[:pubsub_topic] if args.key?(:pubsub_topic)
  @service_account = args[:service_account] if args.key?(:service_account)
  @streaming_config = args[:streaming_config] if args.key?(:streaming_config)
end