ProposedOrder

<ph type="x-smartling-placeholder">
</ph> <ph type="x-smartling-placeholder">
</ph>

调用方请求用户确认的顺序。

JSON 表示法
{
  "id": string,
  "cart": {
    object(Cart)
  },
  "otherItems": [
    {
      object(LineItem)
    }
  ],
  "image": {
    object(Image)
  },
  "termsOfServiceUrl": string,
  "totalPrice": {
    object(Price)
  },
  "extension": {
    "@type": string,
    field1: ...,
    ...
  }
}
字段
id

string

此 ProposedOrder 的可选 ID。包含在确认时退还给集成商的 ProposedOrder。

cart

object(Cart)

用户的内容。

otherItems[]

object(LineItem)

费用、调整项、小计等

image

object(Image)

与建议订单相关联的图片。

termsOfServiceUrl

string

指向适用于此提议订单的服务条款的链接。

totalPrice

object(Price)

提议的订单的总价格。如果类型为 ACTUAL,则这是调用方在用户确认建议的订单时收取的金额。

extension

object

根据订单类型对建议的订单的扩展。例如,如果订单包含营业地点,则此附加信息将包含 OrderLocation 值。

此对象可以包含任意类型的字段。附加字段 "@type" 包含用于标示相应类型的 URI。示例:{ "id": 1234, "@type": "types.example.com/standard/id" }

购物车

用户所需商品的购物车。

JSON 表示法
{
  "id": string,
  "merchant": {
    object(Merchant)
  },
  "lineItems": [
    {
      object(LineItem)
    }
  ],
  "otherItems": [
    {
      object(LineItem)
    }
  ],
  "notes": string,
  "promotions": [
    {
      object(Promotion)
    }
  ],
  "extension": {
    "@type": string,
    field1: ...,
    ...
  }
}
字段
id

string

此购物车的可选 ID。包含在确认时退还给集成商的购物车的一部分。

merchant

object(Merchant)

购物车的商家(如果与调用方不同)。

lineItems[]

object(LineItem)

用户订购的商品或服务。必须至少有一个订单项。

otherItems[]

object(LineItem)

用户输入的调整项,例如小费。

notes

string

关于此购物车的备注。

promotions[]

object(Promotion)

可选。促销优惠券已添加到购物车。符合条件的促销将以折扣专列项的形式在建议的订单中发回。

extension

object

基于订单类型的购物车附加信息。

此对象可以包含任意类型的字段。附加字段 "@type" 包含用于标示相应类型的 URI。示例:{ "id": 1234, "@type": "types.example.com/standard/id" }

商家

购物车对应的商家。

JSON 表示法
{
  "id": string,
  "name": string
}
字段
id

string

商家的 ID。

name

string

向用户显示的商家名称。必填。

LineItem

订单中的订单项。

JSON 表示法
{
  "id": string,
  "name": string,
  "type": enum(LineItemType),
  "quantity": number,
  "description": string,
  "image": {
    object(Image)
  },
  "price": {
    object(Price)
  },
  "subLines": [
    {
      object(SubLine)
    }
  ],
  "offerId": string,
  "extension": {
    "@type": string,
    field1: ...,
    ...
  }
}
字段
id

string

购物车/订单中订单项的唯一 ID。必填。

name

string

收据中显示的订单项名称。必填。

type

enum(LineItemType)

订单项的类型。

quantity

number

包含的内容数量。

description

string

商品的说明。

image

object(Image)

与此内容相关的小图片。

price

object(Price)

每个订单项都应该有一个价格,即使价格为 0 也是如此。必需。这是该行收据上显示的总价(即单价 * 数量)。

subLines[]

object(SubLine)

子订单项。仅当类型为 REGULAR 时才有效。

offerId

string

此商品的可选商品或优惠 ID。

extension

object

根据订单项的类型为其附加信息。

此对象可以包含任意类型的字段。附加字段 "@type" 包含用于标示相应类型的 URI。示例:{ "id": 1234, "@type": "types.example.com/standard/id" }

SubLine

与订单中的订单项相关联的子订单项。

JSON 表示法
{

  // Union field subline can be only one of the following:
  "lineItem": {
    object(LineItem)
  },
  "note": string
  // End of list of possible types for union field subline.
}
字段
联合字段 subline。子订单项。subline 只能是下列其中一项:
lineItem

object(LineItem)

常规订单项(例如插件)。

note

string

与订单项关联的备注。

促销

促销活动已添加到购物车。

JSON 表示法
{
  "coupon": string
}
字段
coupon

string

必需。第三方可以理解的优惠券代码。例如:GOOGLE10。