# 获取优惠链 获取指定优惠链以用于管理。 Endpoint: GET /v2/project/{project_id}/admin/offer_chain/id/{offer_chain_id} Version: 2.0.0 Security: basicAuth ## Path parameters: - `project_id` (integer, required) 项目ID。您可以在您的发布商帐户项目名称旁边找到。 Example: 44056 - `offer_chain_id` (integer, required) 优惠链ID。 Example: 101 ## Response 200 fields (application/json): - `attribute_conditions` (array) 用户属性验证条件。 根据用户属性是否满足所有指定条件来确定优惠链可用性。 - `date_end` (string,null) 优惠链结束日期。可为null,若date_end为null则无时间限制。 Example: "2020-04-15T18:16:00+05:00" - `date_start` (string) 优惠链开始日期。 Example: "2020-04-15T18:16:00+05:00" - `description` (object,null) 包含本地化商品描述的对象。值接受以下两种格式之一:两个小写字母的语言代码(例如,en)或五个字符的区域设置代码(例如,en-US)。虽然两种格式都可作为输入接受,但响应会返回两个小写字母的语言代码。当为同一种语言提供了两种输入时(例如:en和en-US),将存储最后提供的值。您可以在[文档](/zh/doc/shop-builder/references/supported-languages/)中找到支持语言的完整列表。 - `id` (integer) 优惠链唯一ID。 Example: 9 - `is_always_visible` (boolean) 优惠链是否对所有用户可见: * 如为true,则无论用户的认证状态或属性如何,优惠链始终显示。 * 如为false,则仅在未找到个性化优惠链时才显示该优惠链。例如,当用户未认证或其属性与任何个性化优惠链都不匹配时。 仅适用于存在个性化奖励链的前提,并在未传递attribute_conditions数组时使用。 Example: true - `is_enabled` (boolean) Example: true - `name` (object,null) 包含商品本地化名称的对象。值接受以下两种格式之一:两个小写字母的语言代码(例如,en)或五个字符的语言代码(例如,en-US)。虽然两种格式都可作为输入接受,但响应会返回两个小写字母的语言代码。当为同一种语言提供了两种输入时(例如:en和en-US),将存储最后提供的值。您可以在[文档](/zh/doc/shop-builder/references/supported-languages/)中找到支持语言的完整列表。 - `order` (integer) 定义排列顺序。 Example: 1 - `recurrent_schedule` (object,null) 重复性优惠链的重置周期。 - `steps` (array) - `steps.is_free` (boolean) 是否为免费步骤:如为true,需通过领取免费优惠链步骤调用来领取。如为false,需通过为付费优惠链步骤创建订单调用来购买。 - `steps.items` (array) - `steps.items.image_url` (string,null) 图像URL。 Example: "https://image.example.com" - `steps.items.is_free` (boolean) 如果为true,则该商品为免费。 - `steps.items.item_id` (integer) 内部唯一物品ID。 Example: 1 - `steps.items.quantity` (integer) 商品数量。 Example: 1 - `steps.items.sku` (string) 唯一商品ID。 SKU只能包含大小写英文字母和数字字符、句点、破折号和下划线。 Example: "booster_mega_1" - `steps.items.type` (string) 商品类型:virtual_good/virtual_currency/bundle/unit。 - `steps.step_id` (integer,null) 链步骤的唯一ID。 Example: 10 - `steps.step_number` (integer) 步骤编号。 Example: 2 - `steps.step_price` (object,null) - `steps.step_price.amount` (number, required) 步骤的真实货币价格。 Example: 99.99 - `steps.step_price.currency` (string, required) 商品价格货币。每[ISO 4217](https://en.wikipedia.org/wiki/ISO_4217)。 Example: "USD" ## Response 401 fields (application/json): - `errorCode` (integer) Example: 1020 - `errorMessage` (string) Example: "[0401-1020]: Error in Authentication method occurred" - `statusCode` (integer) Example: 401 ## Response 404 fields (application/json): - `errorCode` (integer) Example: 1102 - `errorMessage` (string) Example: "[0401-1102]: Unprocessable Entity. The property `property_name` is required" - `errorMessageExtended` (object,null) - `statusCode` (integer) Example: 422 - `transactionId` (string) Example: "x-x-x-x-transactionId-mock-x-x-x"