Class Promotion
Represents a promotion. See the following articles for more details.
Required promotion input attributes to pass data validation checks are primarily defined below:
After inserting, updating a promotion input, it may take several minutes before the final promotion can be retrieved.
Implements
Namespace: Google.Shopping.Merchant.Promotions.V1Beta
Assembly: Google.Shopping.Merchant.Promotions.V1Beta.dll
Syntax
public sealed class Promotion : IMessage<Promotion>, IEquatable<Promotion>, IDeepCloneable<Promotion>, IBufferMessage, IMessage
Constructors
Promotion()
Declaration
public Promotion()
Promotion(Promotion)
Declaration
public Promotion(Promotion other)
Parameters
Type | Name | Description |
---|---|---|
Promotion | other |
Properties
Attributes
Optional. A list of promotion attributes.
Declaration
public Attributes Attributes { get; set; }
Property Value
Type | Description |
---|---|
Attributes |
ContentLanguage
Required. The two-letter ISO 639-1 language code for the promotion.
Promotions is only for selected languages.
Declaration
public string ContentLanguage { get; set; }
Property Value
Type | Description |
---|---|
string |
CustomAttributes
Optional. A list of custom (merchant-provided) attributes. It can also be
used for submitting any attribute of the data specification in its generic
form (for example,
{ "name": "size type", "value": "regular" }
).
This is useful for submitting attributes not explicitly exposed by the
API.
Declaration
public RepeatedField<CustomAttribute> CustomAttributes { get; }
Property Value
Type | Description |
---|---|
RepeatedField<CustomAttribute> |
DataSource
Output only. The primary data source of the promotion.
Declaration
public string DataSource { get; set; }
Property Value
Type | Description |
---|---|
string |
HasVersionNumber
Gets whether the "version_number" field is set
Declaration
public bool HasVersionNumber { get; }
Property Value
Type | Description |
---|---|
bool |
Name
Identifier. The name of the promotion.
Format: accounts/{account}/promotions/{promotion}
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
string |
PromotionId
Required. The user provided promotion ID to uniquely identify the promotion. Follow minimum requirements to prevent promotion disapprovals.
Declaration
public string PromotionId { get; set; }
Property Value
Type | Description |
---|---|
string |
PromotionName
PromotionName-typed view over the Name resource name property.
Declaration
public PromotionName PromotionName { get; set; }
Property Value
Type | Description |
---|---|
PromotionName |
PromotionStatus
Output only. The status of a promotion, data validation issues, that is, information about a promotion computed asynchronously.
Declaration
public PromotionStatus PromotionStatus { get; set; }
Property Value
Type | Description |
---|---|
PromotionStatus |
RedemptionChannel
Required. Redemption channel for the promotion. At least one channel is required.
Declaration
public RepeatedField<RedemptionChannel> RedemptionChannel { get; }
Property Value
Type | Description |
---|---|
RepeatedField<RedemptionChannel> |
TargetCountry
Required. The target country used as part of the unique identifier. Represented as a CLDR territory code.
Promotions are only available in selected countries, Free Listings and Shopping ads Local Inventory ads
Declaration
public string TargetCountry { get; set; }
Property Value
Type | Description |
---|---|
string |
VersionNumber
Optional. Represents the existing version (freshness) of the promotion, which can be used to preserve the right order when multiple updates are done at the same time.
If set, the insertion is prevented when version number is lower than
the current version number of the existing promotion. Re-insertion (for
example, promotion refresh after 30 days) can be performed with the current
version_number
.
If the operation is prevented, the aborted exception will be thrown.
Declaration
public long VersionNumber { get; set; }
Property Value
Type | Description |
---|---|
long |