Class: Google::Apis::MerchantapiNotificationsV1beta::NotificationSubscription
- Inherits:
-
Object
- Object
- Google::Apis::MerchantapiNotificationsV1beta::NotificationSubscription
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/merchantapi_notifications_v1beta/classes.rb,
lib/google/apis/merchantapi_notifications_v1beta/representations.rb,
lib/google/apis/merchantapi_notifications_v1beta/representations.rb
Overview
Represents a notification subscription owned by a Merchant account. See Decode notifications for information on how to decode the notification payload and how to interpret its contents.
Instance Attribute Summary collapse
-
#all_managed_accounts ⇒ Boolean
(also: #all_managed_accounts?)
If this value is true, the requesting account is notified of the specified event for all managed accounts (can be subaccounts or other linked accounts) including newly added accounts on a daily basis.
-
#call_back_uri ⇒ String
URL to be used to push the notification to the merchant.
-
#name ⇒ String
Output only.
-
#registered_event ⇒ String
The event that the merchant wants to be notified about.
-
#target_account ⇒ String
The
nameof the account you want to receive notifications for.
Instance Method Summary collapse
-
#initialize(**args) ⇒ NotificationSubscription
constructor
A new instance of NotificationSubscription.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ NotificationSubscription
Returns a new instance of NotificationSubscription.
106 107 108 |
# File 'lib/google/apis/merchantapi_notifications_v1beta/classes.rb', line 106 def initialize(**args) update!(**args) end |
Instance Attribute Details
#all_managed_accounts ⇒ Boolean Also known as: all_managed_accounts?
If this value is true, the requesting account is notified of the specified
event for all managed accounts (can be subaccounts or other linked accounts)
including newly added accounts on a daily basis.
Corresponds to the JSON property allManagedAccounts
79 80 81 |
# File 'lib/google/apis/merchantapi_notifications_v1beta/classes.rb', line 79 def all_managed_accounts @all_managed_accounts end |
#call_back_uri ⇒ String
URL to be used to push the notification to the merchant.
Corresponds to the JSON property callBackUri
85 86 87 |
# File 'lib/google/apis/merchantapi_notifications_v1beta/classes.rb', line 85 def call_back_uri @call_back_uri end |
#name ⇒ String
Output only. The name of the notification configuration. Generated by the
Content API upon creation of a new NotificationSubscription. The account
represents the merchant ID of the merchant that owns the configuration. Format:
accounts/account/notificationsubscriptions/notification_subscription`
Corresponds to the JSON propertyname`
93 94 95 |
# File 'lib/google/apis/merchantapi_notifications_v1beta/classes.rb', line 93 def name @name end |
#registered_event ⇒ String
The event that the merchant wants to be notified about.
Corresponds to the JSON property registeredEvent
98 99 100 |
# File 'lib/google/apis/merchantapi_notifications_v1beta/classes.rb', line 98 def registered_event @registered_event end |
#target_account ⇒ String
The name of the account you want to receive notifications for. Format:
accounts/account`
Corresponds to the JSON propertytargetAccount`
104 105 106 |
# File 'lib/google/apis/merchantapi_notifications_v1beta/classes.rb', line 104 def target_account @target_account end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
111 112 113 114 115 116 117 |
# File 'lib/google/apis/merchantapi_notifications_v1beta/classes.rb', line 111 def update!(**args) @all_managed_accounts = args[:all_managed_accounts] if args.key?(:all_managed_accounts) @call_back_uri = args[:call_back_uri] if args.key?(:call_back_uri) @name = args[:name] if args.key?(:name) @registered_event = args[:registered_event] if args.key?(:registered_event) @target_account = args[:target_account] if args.key?(:target_account) end |