Class: Google::Apis::MerchantapiAccountsV1beta::ProductStatusChangeMessage

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

Overview

The message that the merchant will receive to notify about product status change event

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ProductStatusChangeMessage

Returns a new instance of ProductStatusChangeMessage.



3319
3320
3321
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3319

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

Instance Attribute Details

#accountString

The target account that owns the entity that changed. Format : accounts/ merchant_id` Corresponds to the JSON propertyaccount`

Returns:

  • (String)


3272
3273
3274
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3272

def 
  @account
end

#attributeString

The attribute in the resource that changed, in this case it will be always Status. Corresponds to the JSON property attribute

Returns:

  • (String)


3278
3279
3280
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3278

def attribute
  @attribute
end

#changesArray<Google::Apis::MerchantapiAccountsV1beta::ProductChange>

A message to describe the change that happened to the product Corresponds to the JSON property changes



3283
3284
3285
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3283

def changes
  @changes
end

#event_timeString

The time at which the event was generated. If you want to order the notification messages you receive you should rely on this field not on the order of receiving the notifications. Corresponds to the JSON property eventTime

Returns:

  • (String)


3290
3291
3292
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3290

def event_time
  @event_time
end

#expiration_timeString

Optional. The product expiration time. This field will not be set if the notification is sent for a product deletion event. Corresponds to the JSON property expirationTime

Returns:

  • (String)


3296
3297
3298
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3296

def expiration_time
  @expiration_time
end

#managing_accountString

The account that manages the merchant's account. can be the same as merchant id if it is standalone account. Format : accounts/service_provider_id` Corresponds to the JSON propertymanagingAccount`

Returns:

  • (String)


3302
3303
3304
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3302

def 
  @managing_account
end

#resourceString

The product name. Format: accounts/account/products/product` Corresponds to the JSON propertyresource`

Returns:

  • (String)


3307
3308
3309
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3307

def resource
  @resource
end

#resource_idString

The product id. Corresponds to the JSON property resourceId

Returns:

  • (String)


3312
3313
3314
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3312

def resource_id
  @resource_id
end

#resource_typeString

The resource that changed, in this case it will always be Product. Corresponds to the JSON property resourceType

Returns:

  • (String)


3317
3318
3319
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3317

def resource_type
  @resource_type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 3324

def update!(**args)
  @account = args[:account] if args.key?(:account)
  @attribute = args[:attribute] if args.key?(:attribute)
  @changes = args[:changes] if args.key?(:changes)
  @event_time = args[:event_time] if args.key?(:event_time)
  @expiration_time = args[:expiration_time] if args.key?(:expiration_time)
  @managing_account = args[:managing_account] if args.key?(:managing_account)
  @resource = args[:resource] if args.key?(:resource)
  @resource_id = args[:resource_id] if args.key?(:resource_id)
  @resource_type = args[:resource_type] if args.key?(:resource_type)
end