# 获取指定的捆绑包 获取指定的捆绑包。 注:此端点无需授权即可访问,返回通用数据。但是授权后可以通过用户详细信息来丰富响应,获得个性化结果,例如适用的用户限制和促销活动等。 Endpoint: GET /v2/project/{project_id}/items/bundle/sku/{sku} Version: 2.0.0 Security: XsollaLoginUserJWT ## Path parameters: - `project_id` (integer, required) 项目ID。您可以在您的发布商帐户项目名称旁边找到。 Example: 44056 - `sku` (string, required) 捆绑包SKU。 Example: "kg_1" ## Query parameters: - `promo_code` (string) 区分大小写的唯一券码。包含字母和数字。 Example: "WINTER2021" - `show_inactive_time_limited_items` (integer) 显示用户不可用的时效性商品。此类商品的有效期尚未开始或已过期。 Example: 1 - `additional_fields[]` (array) 附加字段列表。如果在请求中发送这些字段,则它们将包含在响应中。 Enum: "media_list", "order", "long_description", "custom_attributes", "item_order_in_group" ## Response 200 fields (application/json): - `attributes` (array) 与商品对应的属性及其值的列表。可用于目录筛选。 Example: {"value":{"external_id":"genre","name":"Жанр","values":[{"external_id":"genre_e3364991f92e751689a68b96598a5a5a84010b85","value":"Casual"},{"external_id":"genre_eba07bfd0f982940773cba3744d97264dd58acd7","value":"Strategy"},{"external_id":"genre_b8d0c6d8f0524c2b2d79ebb93aa3cd0e8b5199a8","value":"Mobile"}]}} - `attributes.external_id` (string) 唯一属性ID。 external_id只能包含大小写英文字母和数字字符、破折号和下划线。 Example: "attribute_1" - `attributes.name` (string) 属性名称。 Example: "Genre" - `attributes.values` (array) - `attributes.values.external_id` (string) 属性的唯一值ID。 external_id只能包含小写英文字母和数字字符、破折号和下划线。 Example: "attribute_value" - `attributes.values.value` (string) 属性值。 Example: "Strategy" - `bundle_type` (string) 捆绑包类型。使用standard创建包含商品的捆绑包,并指定捆绑包中所含商品的SKU。 使用partner_side_content创建一个空的捆绑包,并使用[Webhook](https://developers.xsolla.com/zh/zh/webhooks/operation/personalized-partner-catalog/)在己侧添加商品。此类型仅用于[合作伙伴侧的目录个性化](https://developers.xsolla.com/zh/doc/shop-builder/features/personalization/#guides_personalization_on_partner_side)。 Enum: "standard", "partner_side_content" - `can_be_bought` (boolean) 如为true,则用户可以购买商品。 Example: true - `content` (array) 捆绑包套餐内容。 Example: [{"attributes":[],"description":"Big Rocket - short description.","groups":[],"image_url":"https://popmedia.blob.core.windows.net/popyourself/male/outfit/male_armor_white_a-01.png","is_free":false,"name":"Big Rocket","price":{"amount":"10.99","amount_without_discount":"10.99","currency":"USD"},"quantity":100,"sku":"com.xsolla.big_rocket_1","type":"virtual_currency"}] - `content.description` (string) 商品描述。 Example: "Big Rocket - description" - `content.groups` (array) 商品所属分组。 Example: [{"external_id":"horror","name":{"en":"Horror"}}] - `content.groups.external_id` (string) Example: "horror" - `content.groups.name` (object) 商品名称。应包含键/值对, 其中键是"^[a-z]{2}"格式的区域设置,值是字符串。 Example: {"de":"Horror","en":"Horror"} - `content.image_url` (string) 图像URL。 Example: "https://popmedia.blob.core.windows.net/popyourself/male/outfit/male_armor_white_a-01.png" - `content.is_free` (boolean) 如果为true,则该商品为免费。 - `content.limits` (object,null) 商品限制。 - `content.limits.per_item` (object,null) 商品的购买限制。 - `content.limits.per_item.available` (integer) 所有用户可购买的剩余商品数量。 Example: 3 - `content.limits.per_item.total` (integer) 所有用户可购买的最大商品数量。 Example: 5 - `content.limits.per_user` (object,null) 用户的购买限制。 - `content.limits.per_user.available` (integer) 当前用户可购买的剩余商品数量。 Example: 3 - `content.limits.per_user.limit_exceeded_visibility` (string) 设定商品在达到购买限制后、下次限制重置前在目录中的可见性。 适用于在recurrent_schedule数组中配置了周期性重置数量限制的商品。 若未配置数量限制重置,则商品在达到购买限制后将不会出现在目录中,无论limit_exceeded_visibility值为何。 Enum: "show", "hide" - `content.limits.per_user.recurrent_schedule` (object) 用户的商品限制循环刷新周期。 - `content.limits.per_user.recurrent_schedule.interval_type` (string) 循环刷新周期类型。 Enum: "daily", "weekly", "monthly", "hourly" - `content.limits.per_user.recurrent_schedule.reset_next_date` (integer) 重置限制次数的日期和时间(Unix时间戳)。 Example: 1677553200 - `content.limits.per_user.total` (integer) 单个用户可购买的最大商品数量。 Example: 5 - `content.name` (string) 商品名称。 Example: "Big Rocket" - `content.price` (object,null) 商品价格。 - `content.price.amount` (string) 折扣后的商品价格。 Example: "100.99" - `content.price.amount_without_discount` (string) 商品价格。 Example: "100.99" - `content.price.currency` (string) 商品价格货币。每[ISO 4217](https://en.wikipedia.org/wiki/ISO_4217)。请查看文档以获取有关[Xsolla 支持的货币](https://developers.xsolla.com/zh/doc/pay-station/references/supported-currencies/)。 Example: "USD" - `content.quantity` (integer) 套餐中的商品数量。 Example: 250 - `content.sku` (string) 唯一商品ID。 SKU只能包含大小写英文字母和数字字符、破折号和下划线。 Example: "com.xsolla.big_rocket_1" - `content.type` (string) 商品类型:virtual_good/virtual_currency/bundle。 Example: "virtual_currency" - `content.virtual_item_type` (string) 虚拟物品的类型。 Enum: "consumable", "non_consumable", "non_renewing_subscription" - `content.virtual_prices` (array) 虚拟价格。 - `content.virtual_prices.amount` (integer) 以虚拟货币表示的折扣后商品价格。 Example: 100 - `content.virtual_prices.description` (string) 虚拟货币说明。 Example: "Big Rocket - description" - `content.virtual_prices.image_url` (string) 虚拟货币图像。 Example: "http://image.png" - `content.virtual_prices.is_default` (boolean) 价格是否为商品的默认价格。 Example: true - `content.virtual_prices.name` (string) 虚拟货币名称。 Example: "SHOTGUN FOR TRUE RAIDERS" - `content.virtual_prices.sku` (string) 虚拟货币物品SKU。 Example: "vc_test" - `content.virtual_prices.type` (string) 虚拟货币类型。 Example: "virtual_currency" - `custom_attributes` (object) 包含商品属性和值的JSON对象。 - `item_id` (integer) 内部唯一物品ID。 Example: 1 - `long_description` (object,null) 包含商品详细本地化描述的对象。值接受以下两种格式之一:两个小写字母的语言代码(例如,en)或五个字符的区域设置代码(例如,en-US)。虽然两种格式都可作为输入接受,但响应会返回两个小写字母的语言代码。当为同一种语言提供了两种输入时(例如:en和en-US),将存储最后提供的值。您可以在[文档](/zh/doc/shop-builder/references/supported-languages/)中找到支持语言的完整列表。 - `media_list` (array) 捆绑包的附加资源。 Example: [{"type":"image","url":"https://cdn3.xsolla.com/img/misc/images/71ab1e12126f2103e1868076f0acb21a.jpg"}] - `media_list.type` (string) 媒体类型:image/video。 Enum: "image", "video" - `media_list.url` (string) 资源文件。 Example: "https://cdn3.xsolla.com/img/misc/images/71ab1e12126f2103e1868076f0acb21a.jpg" - `order` (integer) 列表中的捆绑包顺序优先级。 Example: 1 - `periods` (array,null) 商品促销时间段。 - `periods.date_from` (string) 指定商品促销开始的日期。 Example: "2020-08-11T10:00:00+03:00" - `periods.date_until` (string,null) 指定商品停止促销的日期。可以为null。 Example: "2020-08-11T20:00:00+03:00" - `promotions` (array) 应用于购物车中指定商品的促销活动。仅在以下情况下返回该数组: * 为某商品配置了折扣促销活动。 * 应用了对所选商品提供折扣设置的促销码。 如果未应用任何商品级促销活动,则返回空数组。 - `promotions.bonus` (array) - `promotions.bonus.bundle_type` (string) 奖励捆绑包商品类型。仅适用于bundle奖励品类型。 Enum: "standard", "virtual_currency_package" - `promotions.bonus.image_url` (string) 奖励商品图片URL。不适用于physical_good奖励品类型。 - `promotions.bonus.name` (string) 奖励品名称。不适用于physical_good奖励品类型。 - `promotions.bonus.quantity` (integer) - `promotions.bonus.sku` (string) - `promotions.bonus.type` (string) 奖励品类型。 Enum: "virtual_good", "virtual_currency", "bundle", "physical_good", "game_key", "nft" - `promotions.date_end` (string,null) - `promotions.date_start` (string,null) - `promotions.discount` (object,null) - `promotions.discount.percent` (string,null) - `promotions.discount.value` (string,null) - `promotions.limits` (object) - `promotions.limits.per_user` (object) - `promotions.limits.per_user.available` (integer) - `promotions.limits.per_user.total` (integer) - `promotions.name` (string) - `sku` (string) 唯一商品ID。 SKU只能包含大小写英文字母和数字字符、句点、破折号和下划线。 Example: "bundle_1" - `total_content_price` (object,null) 捆绑包内容价格总和。 - `total_content_price.amount` (string) 折扣后的捆绑包内容价格总和。 Example: "100.99" - `total_content_price.amount_without_discount` (string) 捆绑包内容价格总和。 Example: "100.99" - `total_content_price.currency` (string) 商品价格货币。每[ISO 4217](https://en.wikipedia.org/wiki/ISO_4217)。 Example: "USD" - `type` (string) 商品类型。 Example: "bundle" - `vp_rewards` (array) 奖励积分商品奖励。 - `vp_rewards.amount` (integer) 奖励积分的数量。 - `vp_rewards.is_clan` (boolean) 该奖励积分是否用于公会奖励链。 Example: true - `vp_rewards.name` (string) 奖励积分名称。 - `vp_rewards.sku` (string) 唯一奖励积分ID。