Class: Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserEvent

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

Overview

UserEvent captures all metadata information recommendation engine needs to know about how end users interact with customers' website.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRecommendationengineV1beta1UserEvent

Returns a new instance of GoogleCloudRecommendationengineV1beta1UserEvent.



1674
1675
1676
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1674

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

Instance Attribute Details

#event_detailGoogle::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1EventDetail

User event details shared by all recommendation types. Corresponds to the JSON property eventDetail



1635
1636
1637
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1635

def event_detail
  @event_detail
end

#event_sourceString

Optional. This field should not be set when using JavaScript pixel or the Recommendations AI Tag. Defaults to EVENT_SOURCE_UNSPECIFIED. Corresponds to the JSON property eventSource

Returns:

  • (String)


1641
1642
1643
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1641

def event_source
  @event_source
end

#event_timeString

Optional. Only required for ImportUserEvents method. Timestamp of user event created. Corresponds to the JSON property eventTime

Returns:

  • (String)


1647
1648
1649
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1647

def event_time
  @event_time
end

#event_typeString

Required. User event type. Allowed values are: * add-to-cart Products being added to cart. * add-to-list Items being added to a list (shopping list, favorites etc). * category-page-view Special pages such as sale or promotion pages viewed. * checkout-start User starting a checkout process. * detail- page-view Products detail page viewed. * home-page-view Homepage viewed. * page-visit Generic page visits not included in the event types above. * purchase-complete User finishing a purchase. * refund Purchased items being refunded or returned. * remove-from-cart Products being removed from cart. * remove-from-list Items being removed from a list. * search Product search.

  • shopping-cart-page-view User viewing a shopping cart. * impression List of items displayed. Used by Google Tag Manager. Corresponds to the JSON property eventType

Returns:

  • (String)


1662
1663
1664
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1662

def event_type
  @event_type
end

#product_event_detailGoogle::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ProductEventDetail

ProductEventDetail captures user event information specific to retail products. Corresponds to the JSON property productEventDetail



1667
1668
1669
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1667

def product_event_detail
  @product_event_detail
end

#user_infoGoogle::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserInfo

Information of end users. Corresponds to the JSON property userInfo



1672
1673
1674
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1672

def 
  @user_info
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1679
1680
1681
1682
1683
1684
1685
1686
# File 'lib/google/apis/recommendationengine_v1beta1/classes.rb', line 1679

def update!(**args)
  @event_detail = args[:event_detail] if args.key?(:event_detail)
  @event_source = args[:event_source] if args.key?(:event_source)
  @event_time = args[:event_time] if args.key?(:event_time)
  @event_type = args[:event_type] if args.key?(:event_type)
  @product_event_detail = args[:product_event_detail] if args.key?(:product_event_detail)
  @user_info = args[:user_info] if args.key?(:user_info)
end