Class: Google::Apis::AlertcenterV1beta1::CloudPubsubTopic

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

Overview

A reference to a Cloud Pubsub topic. To register for notifications, the owner of the topic must grant alerts-api-push-notifications@system.gserviceaccount.com the projects.topics.publish permission.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ CloudPubsubTopic

Returns a new instance of CloudPubsubTopic.



581
582
583
# File 'generated/google/apis/alertcenter_v1beta1/classes.rb', line 581

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

Instance Attribute Details

#payload_formatString

Optional. The format of the payload that would be sent. If not specified the format will be JSON. Corresponds to the JSON property payloadFormat

Returns:

  • (String)


573
574
575
# File 'generated/google/apis/alertcenter_v1beta1/classes.rb', line 573

def payload_format
  @payload_format
end

#topic_nameString

The name field of a Cloud Pubsub Topic. Corresponds to the JSON property topicName

Returns:

  • (String)


579
580
581
# File 'generated/google/apis/alertcenter_v1beta1/classes.rb', line 579

def topic_name
  @topic_name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



586
587
588
589
# File 'generated/google/apis/alertcenter_v1beta1/classes.rb', line 586

def update!(**args)
  @payload_format = args[:payload_format] if args.key?(:payload_format)
  @topic_name = args[:topic_name] if args.key?(:topic_name)
end