Class: Google::Apis::ContentV2_1::Recommendation
- Inherits:
-
Object
- Object
- Google::Apis::ContentV2_1::Recommendation
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/content_v2_1/classes.rb,
lib/google/apis/content_v2_1/representations.rb,
lib/google/apis/content_v2_1/representations.rb
Overview
Recommendations are suggested ways to improve your merchant account's performance. For example, to engage with a feature, or start using a new Google product.
Instance Attribute Summary collapse
-
#additional_call_to_action ⇒ Array<Google::Apis::ContentV2_1::RecommendationCallToAction>
Output only.
-
#additional_descriptions ⇒ Array<Google::Apis::ContentV2_1::RecommendationDescription>
Output only.
-
#creative ⇒ Array<Google::Apis::ContentV2_1::RecommendationCreative>
Output only.
-
#default_call_to_action ⇒ Google::Apis::ContentV2_1::RecommendationCallToAction
Call to action (CTA) that explains how a merchant can implement this recommendation Corresponds to the JSON property
defaultCallToAction. -
#default_description ⇒ String
Optional.
-
#numerical_impact ⇒ Fixnum
Optional.
-
#paid ⇒ Boolean
(also: #paid?)
Optional.
-
#recommendation_name ⇒ String
Optional.
-
#sub_type ⇒ String
Optional.
-
#title ⇒ String
Optional.
-
#type ⇒ String
Output only.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Recommendation
constructor
A new instance of Recommendation.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Recommendation
Returns a new instance of Recommendation.
11666 11667 11668 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11666 def initialize(**args) update!(**args) end |
Instance Attribute Details
#additional_call_to_action ⇒ Array<Google::Apis::ContentV2_1::RecommendationCallToAction>
Output only. CTAs of this recommendation. Repeated.
Corresponds to the JSON property additionalCallToAction
11596 11597 11598 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11596 def additional_call_to_action @additional_call_to_action end |
#additional_descriptions ⇒ Array<Google::Apis::ContentV2_1::RecommendationDescription>
Output only. List of additional localized descriptions for a recommendation.
Localication uses the languageCode field in GenerateRecommendations
requests. Not all description types are guaranteed to be present and we
recommend to rely on default description.
Corresponds to the JSON property additionalDescriptions
11604 11605 11606 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11604 def additional_descriptions @additional_descriptions end |
#creative ⇒ Array<Google::Apis::ContentV2_1::RecommendationCreative>
Output only. Any creatives attached to the recommendation. Repeated.
Corresponds to the JSON property creative
11609 11610 11611 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11609 def creative @creative end |
#default_call_to_action ⇒ Google::Apis::ContentV2_1::RecommendationCallToAction
Call to action (CTA) that explains how a merchant can implement this
recommendation
Corresponds to the JSON property defaultCallToAction
11615 11616 11617 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11615 def default_call_to_action @default_call_to_action end |
#default_description ⇒ String
Optional. Localized recommendation description. The localization the @link
GenerateRecommendationsRequest.language_codefield in `@link `
GenerateRecommendationsRequest requests.
Corresponds to the JSON property defaultDescription
11622 11623 11624 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11622 def default_description @default_description end |
#numerical_impact ⇒ Fixnum
Optional. A numerical score of the impact from the recommendation's
description. For example, a recommendation might suggest an upward trend in
sales for a certain product. Higher number means larger impact.
Corresponds to the JSON property numericalImpact
11629 11630 11631 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11629 def numerical_impact @numerical_impact end |
#paid ⇒ Boolean Also known as: paid?
Optional. Indicates whether a user needs to pay when they complete the user
journey suggested by the recommendation.
Corresponds to the JSON property paid
11635 11636 11637 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11635 def paid @paid end |
#recommendation_name ⇒ String
Optional. Localized recommendation name. The localization uses the @link
GenerateRecommendationsRequest.language_codefield in `@link `
GenerateRecommendationsRequest requests.
Corresponds to the JSON property recommendationName
11643 11644 11645 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11643 def recommendation_name @recommendation_name end |
#sub_type ⇒ String
Optional. Subtype of the recommendations. Only applicable when multiple
recommendations can be generated per type, and is used as an identifier of
recommendation under the same recommendation type.
Corresponds to the JSON property subType
11650 11651 11652 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11650 def sub_type @sub_type end |
#title ⇒ String
Optional. Localized Recommendation Title. Localization uses the @link
GenerateRecommendationsRequest.language_codefield in `@link `
GenerateRecommendationsRequest requests.
Corresponds to the JSON property title
11657 11658 11659 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11657 def title @title end |
#type ⇒ String
Output only. Type of the recommendation. List of currently available
recommendation types: - OPPORTUNITY_CREATE_NEW_COLLECTION -
OPPORTUNITY_CREATE_EMAIL_CAMPAIGN
Corresponds to the JSON property type
11664 11665 11666 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11664 def type @type end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
11671 11672 11673 11674 11675 11676 11677 11678 11679 11680 11681 11682 11683 |
# File 'lib/google/apis/content_v2_1/classes.rb', line 11671 def update!(**args) @additional_call_to_action = args[:additional_call_to_action] if args.key?(:additional_call_to_action) @additional_descriptions = args[:additional_descriptions] if args.key?(:additional_descriptions) @creative = args[:creative] if args.key?(:creative) @default_call_to_action = args[:default_call_to_action] if args.key?(:default_call_to_action) @default_description = args[:default_description] if args.key?(:default_description) @numerical_impact = args[:numerical_impact] if args.key?(:numerical_impact) @paid = args[:paid] if args.key?(:paid) @recommendation_name = args[:recommendation_name] if args.key?(:recommendation_name) @sub_type = args[:sub_type] if args.key?(:sub_type) @title = args[:title] if args.key?(:title) @type = args[:type] if args.key?(:type) end |