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.



1969
1970
1971
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1969

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)


1934
1935
1936
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1934

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)


1940
1941
1942
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1940

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



1945
1946
1947
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1945

def changes
  @changes
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)


1951
1952
1953
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1951

def 
  @managing_account
end

#resourceString

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

Returns:

  • (String)


1957
1958
1959
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1957

def resource
  @resource
end

#resource_idString

The product id. Corresponds to the JSON property resourceId

Returns:

  • (String)


1962
1963
1964
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1962

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)


1967
1968
1969
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1967

def resource_type
  @resource_type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1974
1975
1976
1977
1978
1979
1980
1981
1982
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 1974

def update!(**args)
  @account = args[:account] if args.key?(:account)
  @attribute = args[:attribute] if args.key?(:attribute)
  @changes = args[:changes] if args.key?(:changes)
  @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