Package google.shopping.merchant.inventories.v1beta

索引

LocalInventoryService

用于管理商品本地商品目录的服务

DeleteLocalInventory

rpc DeleteLocalInventory(DeleteLocalInventoryRequest) returns (Empty)

从商家账号中的指定商品中删除指定的 LocalInventory。系统最长可能需要 1 小时才能从特定商品中删除 LocalInventory。收到成功删除响应后,请等待该时段过后,然后再尝试再次删除。

授权范围

需要以下 OAuth 范围:

  • https://www.googleapis.com/auth/content

如需了解详情,请参阅 OAuth 2.0 Overview

InsertLocalInventory

rpc InsertLocalInventory(InsertLocalInventoryRequest) returns (LocalInventory)

LocalInventory 资源插入到商家账号中的商品中。

如果商品已存在具有相同 storeCode 的条目,则会替换完整的 LocalInventory 资源。

新建或更新后的 LocalInventory 资源最长可能需要 30 分钟才能显示在商品中。

授权范围

需要以下 OAuth 范围:

  • https://www.googleapis.com/auth/content

如需了解详情,请参阅 OAuth 2.0 Overview

ListLocalInventories

rpc ListLocalInventories(ListLocalInventoriesRequest) returns (ListLocalInventoriesResponse)

列出商家账号中指定商品的 LocalInventory 资源。响应中包含的项目数量可能少于 pageSize 指定的数量。如果上一个请求中返回了 pageToken,则可以使用它来获取更多结果。

系统会按给定账号中的每种产品列出 LocalInventory 资源。

授权范围

需要以下 OAuth 范围:

  • https://www.googleapis.com/auth/content

如需了解详情,请参阅 OAuth 2.0 Overview

RegionalInventoryService

用于管理商品地区性商品目录的服务。此外,还有单独的 regions 资源和 API 用于管理地区定义。

DeleteRegionalInventory

rpc DeleteRegionalInventory(DeleteRegionalInventoryRequest) returns (Empty)

从商家账号中的指定商品中删除指定的 RegionalInventory 资源。系统最长可能需要 1 小时才能从特定商品中删除 RegionalInventory。收到成功删除响应后,请等待该时段过后,然后再尝试再次删除。

授权范围

需要以下 OAuth 范围:

  • https://www.googleapis.com/auth/content

如需了解详情,请参阅 OAuth 2.0 Overview

InsertRegionalInventory

rpc InsertRegionalInventory(InsertRegionalInventoryRequest) returns (RegionalInventory)

在您的商家账号中为指定商品插入 RegionalInventory

如果商品已存在具有相同 region 的条目,则会替换完整的 RegionalInventory 资源。

新建或更新后的 RegionalInventory 资源最长可能需要 30 分钟才能显示在商品中。

授权范围

需要以下 OAuth 范围:

  • https://www.googleapis.com/auth/content

如需了解详情,请参阅 OAuth 2.0 Overview

ListRegionalInventories

rpc ListRegionalInventories(ListRegionalInventoriesRequest) returns (ListRegionalInventoriesResponse)

列出商家账号中指定商品的 RegionalInventory 资源。响应中包含的项目数量可能少于 pageSize 指定的数量。如果上一个请求中返回了 pageToken,则可以使用它来获取更多结果。

系统会按给定账号中的每种产品列出 RegionalInventory 资源。

授权范围

需要以下 OAuth 范围:

  • https://www.googleapis.com/auth/content

如需了解详情,请参阅 OAuth 2.0 Overview

DeleteLocalInventoryRequest

DeleteLocalInventory 方法的请求消息。

字段
name

string

必需。要删除的给定商品的本地商品目录的名称。格式:accounts/{account}/products/{product}/localInventories/{store_code}

DeleteRegionalInventoryRequest

DeleteRegionalInventory 方法的请求消息。

字段
name

string

必需。要删除的 RegionalInventory 资源的名称。格式:accounts/{account}/products/{product}/regionalInventories/{region}

InsertLocalInventoryRequest

InsertLocalInventory 方法的请求消息。

字段
parent

string

必需。要插入此商品目录的账号和产品。格式:accounts/{account}/products/{product}

local_inventory

LocalInventory

必需。商品的本地商品目录信息。如果商品已有针对同一 storeCodeLocalInventory 资源,系统会完全替换 LocalInventory 资源。

InsertRegionalInventoryRequest

InsertRegionalInventory 方法的请求消息。

字段
parent

string

必需。要插入此商品目录的账号和产品。格式:accounts/{account}/products/{product}

regional_inventory

RegionalInventory

必需。要添加到商品中的地区性商品目录信息。如果商品已有针对同一 regionRegionalInventory 资源,系统会完全替换 RegionalInventory 资源。

ListLocalInventoriesRequest

ListLocalInventories 方法的请求消息。

字段
parent

string

必需。要为其列出本地商品目录的父级商品的 name。格式:accounts/{account}/products/{product}

page_size

int32

要返回的指定商品的 LocalInventory 资源的数量上限。如果指定商品的商品目录数量少于 pageSize,则该服务返回的数量会少于此值。默认值为 25,000。最大值为 25, 000;如果指定的值高于上限,则 pageSize 将默认为上限

page_token

string

从之前的 ListLocalInventories 调用接收的页面令牌。提供页面令牌以检索后续页面。

进行分页时,提供给 ListLocalInventories 的所有其他参数必须与提供页面令牌的调用相一致。在对上一个请求的响应中作为 nextPageToken 返回的令牌。

ListLocalInventoriesResponse

ListLocalInventories 方法的响应消息。

字段
local_inventories[]

LocalInventory

指定账号中指定商品的 LocalInventory 资源。

next_page_token

string

可作为 pageToken 发送并用于检索下一页的令牌。如果省略此字段,则不存在后续页面。

ListRegionalInventoriesRequest

ListRegionalInventories 方法的请求消息。

字段
parent

string

必需。要为其列出 RegionalInventory 资源的父级商品的 name。格式:accounts/{account}/products/{product}

page_size

int32

要返回的指定商品的 RegionalInventory 资源的数量上限。如果指定商品的商品目录数量少于 pageSize,则该服务返回的数量会少于此值。默认值为 25,000。最大值为 100000;如果指定的值高于上限,则 pageSize 将默认为上限。

page_token

string

从之前的 ListRegionalInventories 调用接收的页面令牌。提供页面令牌以检索后续页面。

进行分页时,提供给 ListRegionalInventories 的所有其他参数必须与提供页面令牌的调用相一致。在对上一个请求的响应中作为 nextPageToken 返回的令牌。

ListRegionalInventoriesResponse

ListRegionalInventories 方法的响应消息。

字段
regional_inventories[]

RegionalInventory

指定账号中指定商品的 RegionalInventory 资源。

next_page_token

string

可作为 pageToken 发送并用于检索下一页的令牌。如果省略此字段,则不存在后续页面。

LocalInventory

商品的本地商品目录信息。表示 storeCode 指定的商店中特定商品的实体店信息。如需查看所有接受的属性值的列表,请参阅本地商品目录数据规范

字段
name

string

仅限输出。LocalInventory 资源的名称。格式:accounts/{account}/products/{product}/localInventories/{store_code}

account

int64

仅限输出。产品所属的账号。如果由客户端设置,系统会忽略此字段。

store_code

string

必需。不可变。销售相应商品的实体店的商店代码(商家资料中的商店 ID)。如需了解详情,请参阅本地商品目录数据规范

price

Price

商品在此商店中的价格。

sale_price

Price

商品在此商店中的促销价。如果定义了 salePriceEffectiveDate,则必须提供。

sale_price_effective_date

Interval

此商店的促销活动的 TimePeriod

custom_attributes[]

CustomAttribute

自定义(商家提供)属性的列表。您还可以使用 CustomAttribute 以通用形式提交数据规范的任何属性。

availability

string

此商店的商品库存状况。如需了解接受的属性值,请参阅本地商品目录数据规范

quantity

int64

此商店中提供的商品数量。必须大于或等于零。

pickup_method

string

此商品支持的自提方法。除非值为 "not supported",否则必须将此字段与 pickupSla 一起提交。如需了解接受的属性值,请参阅本地商品目录数据规范

pickup_sla

string

从此商品在该商店的订单下单之日到可自提的相对时间段。必须使用 pickupMethod 提交。如需了解接受的属性值,请参阅本地商品目录数据规范

instore_product_location

string

商品在商店内的具体位置。长度上限为 20 个字节。

RegionalInventory

商品的地区性商品目录信息。表示特定 region 中指定商品的价格和库存状况等具体信息。如需查看所有接受的属性值的列表,请参阅地区商品目录数据规范

字段
name

string

仅限输出。RegionalInventory 资源的名称。格式:{regional_inventory.name=accounts/{account}/products/{product}/regionalInventories/{region}

account

int64

仅限输出。产品所属的账号。如果由客户端设置,系统会忽略此字段。

region

string

必需。不可变。此 RegionalInventory 资源的区域 ID。如需了解详情,请参阅地区性库存状况和价格

price

Price

商品在此地区的价格。

sale_price

Price

商品在此地区的促销价。如果定义了 salePriceEffectiveDate,则必须提供。

sale_price_effective_date

Interval

此地区促销价的 TimePeriod

custom_attributes[]

CustomAttribute

自定义(商家提供)属性的列表。您还可以使用 CustomAttribute 以通用形式提交数据规范的任何属性。

availability

string

商品在此地区的供应情况。如需了解可接受的属性值,请参阅地区商品目录数据规范