Skip to content
On this page

4.3.1 获取商品详情接口

接口说明:

MethodURLContentType
GET/api/v1/product/{sku}/detailapplication/json

URL参数说明:

参数类型说明是否必须长度描述
skustring必须50商品编号

返回结果说明:

参数类型说明描述
skustring商品编号
namestring商品名称
mainImagestring商品主图
carouselImagesstring数组商品轮播图
saleUnitstring销售单位
categoryCodestring分类编码
categoryNamestring类别名称
brandNamestring品牌名称
stockint库存
pricedecimal协议价
mallPricedecimal商城价
marketPricedecimal市场价
minimumQuantityint最小购买数量
specstring规格
modelstring型号
attributesJSON数组商品属性
-- attrCodestring属性编码
-- attrNamestring属性名称
-- attrValuestring属性值
-- attrSeqstring属性排序值
-- attrGroupCodestring属性分组编码
-- attrGroupNamestring属性分组名称
introductionstring商品描述(图文, html)
extensionsJSON数组扩展信息

请求参数示例:

/api/v1/product/1049204/detail

返回数据示例:

json
{
    "success": true,
    "code": "000",
    "message": "成功",
    "data": {
        "sku": "4593174",
        "name": "得力 deli 脚踏耐用圆纸篓 959 5.5L (灰色)",
        "mainImage": "https://res-sh.clpcdn.com/pmspic/ItemPicture/20008/20069/20494/7537861/1649679255584/Original/4593174.jpg",
        "carouselImages": [
            "https://res-sh.clpcdn.com/pmspic/ItemPicture/20008/20069/20494/7537861/1649679255584/Original/4593174.jpg",
            "https://res-sh.clpcdn.com/pmspic/ItemPicture/20008/20069/20494/7537861/1649679255584/Original/1_4593174.jpg",
            "https://res-sh.clpcdn.com/pmspic/ItemPicture/20008/20069/20494/7537861/1649679255584/Original/2_4593174.jpg",
            "https://res-sh.clpcdn.com/pmspic/ItemPicture/20008/20069/20494/7537861/1649679255584/Original/3_4593174.jpg",
            "https://res-sh.clpcdn.com/pmspic/ItemPicture/20008/20069/20494/7537861/1649679255584/Original/4_4593174.jpg"
        ],
        "saleUnit": "",
        "categoryCode": "20170",
        "categoryName": "档案盒",
        "categoryCodes": [],
        "brandName": "得力",
        "state": 1,
        "stock": 9999,
        "price": 40.53,
        "mallPrice": 70.00,
        "marketPrice": 84.00,
        "minimumQuantity": null,
        "spec": "5.5L",
        "model": "959",
        "introduction": "<p class=\"detailsNewDiv-Title\"><img src=\"https://res-sh.clpcdn.com/Introduction/introduction.jpg\" /></p><div class=\"dndc2-info\"><ul></ul></div><div class=\"dndc-show\"><img src=\"https://res-sh.clpcdn.com/ProductDescribe/ProductDesc_Middle/4593174/1649681832125/4593174_01.jpg\" width=\"790\" /></div><div class=\"dndc-show\"><img src=\"https://res-sh.clpcdn.com/ProductDescribe/ProductDesc_Middle/4593174/1649681832125/4593174_02.jpg\" width=\"790\" /></div><div class=\"dndc-show\"><img src=\"https://res-sh.clpcdn.com/ProductDescribe/ProductDesc_Middle/4593174/1649681832125/4593174_03.jpg\" width=\"790\" /></div><div class=\"dndc-show\"><img src=\"https://res-sh.clpcdn.com/ProductDescribe/ProductDesc_Middle/4593174/1649681832125/4593174_04.jpg\" width=\"790\" /></div><div class=\"dndc-show\"><img src=\"https://res-sh.clpcdn.com/ProductDescribe/ProductDesc_Middle/4593174/1649681832125/4593174_05.jpg\" width=\"790\" /></div>",
        "attributes": [
            {
                "attrCode": "w1_7537861",
                "attrName": "品牌",
                "attrValue": "得力"
            },
            {
                "attrCode": "w2_7537861",
                "attrName": "型号",
                "attrValue": "959",
                "attrSeq": "1",
                "attrGroupCode": "0",
                "attrGroupName": "基本参数"
            },
            {
                "attrCode": "w3_7537861",
                "attrName": "颜色",
                "attrValue": "灰色",
                "attrSeq": "2",
                "attrGroupCode": "0",
                "attrGroupName": "基本参数"
            },
            {
                "attrCode": "w4_7537861",
                "attrName": "规格",
                "attrValue": "5.5L",
                "attrSeq": "3",
                "attrGroupCode": "0",
                "attrGroupName": "基本参数"
            },
            {
                "attrCode": "w5_7537861",
                "attrName": "内包装",
                "attrValue": "",
                "attrSeq": "4",
                "attrGroupCode": "0",
                "attrGroupName": "基本参数"
            }
        ],
        "extensions": null
    }
}