google_api_content v0.31.0 GoogleApi.Content.V21.Model.OrderPromotion View Source

Attributes

  • applicableItems (type: list(GoogleApi.Content.V21.Model.OrderPromotionItem.t), default: nil) - Items which this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity.

  • appliedItems (type: list(GoogleApi.Content.V21.Model.OrderPromotionItem.t), default: nil) - Items which this promotion have been applied to. Do not provide for orders.createtestorder.

  • endTime (type: String.t, default: nil) - Promotion end time in ISO 8601 format. Date, time, and offset required, e.g., "2020-01-02T09:00:00+01:00" or "2020-01-02T09:00:00Z".

  • funder (type: String.t, default: nil) - Required. The party funding the promotion. Only merchant is supported for orders.createtestorder.

    Acceptable values are:

    • "google"
    • "merchant"
  • merchantPromotionId (type: String.t, default: nil) - Required. This field is used to identify promotions within merchants' own systems.

  • priceValue (type: GoogleApi.Content.V21.Model.Price.t, default: nil) - Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order.

  • shortTitle (type: String.t, default: nil) - A short title of the promotion to be shown on the checkout page. Do not provide for orders.createtestorder.

  • startTime (type: String.t, default: nil) - Promotion start time in ISO 8601 format. Date, time, and offset required, e.g., "2020-01-02T09:00:00+01:00" or "2020-01-02T09:00:00Z".

  • subtype (type: String.t, default: nil) - Required. The category of the promotion. Only moneyOff is supported for orders.createtestorder.

    Acceptable values are:

    • "buyMGetMoneyOff"
    • "buyMGetNMoneyOff"
    • "buyMGetNPercentOff"
    • "buyMGetPercentOff"
    • "freeGift"
    • "freeGiftWithItemId"
    • "freeGiftWithValue"
    • "freeShippingOvernight"
    • "freeShippingStandard"
    • "freeShippingTwoDay"
    • "moneyOff"
    • "percentOff"
    • "rewardPoints"
    • "salePrice"
  • taxValue (type: GoogleApi.Content.V21.Model.Price.t, default: nil) - Estimated discount applied to tax (if allowed by law). Do not provide for orders.createtestorder.

  • title (type: String.t, default: nil) - Required. The title of the promotion.

  • type (type: String.t, default: nil) - Required. The scope of the promotion. Only product is supported for orders.createtestorder.

    Acceptable values are:

    • "product"
    • "shipping"

Link to this section Summary

Functions

Unwrap a decoded JSON object into its complex fields.

Link to this section Types

Link to this type

t()

View Source
t() :: %GoogleApi.Content.V21.Model.OrderPromotion{
  applicableItems: [GoogleApi.Content.V21.Model.OrderPromotionItem.t()],
  appliedItems: [GoogleApi.Content.V21.Model.OrderPromotionItem.t()],
  endTime: String.t(),
  funder: String.t(),
  merchantPromotionId: String.t(),
  priceValue: GoogleApi.Content.V21.Model.Price.t(),
  shortTitle: String.t(),
  startTime: String.t(),
  subtype: String.t(),
  taxValue: GoogleApi.Content.V21.Model.Price.t(),
  title: String.t(),
  type: String.t()
}

Link to this section Functions

Link to this function

decode(value, options)

View Source
decode(struct(), keyword()) :: struct()

Unwrap a decoded JSON object into its complex fields.