API接口文档

详情

创建于 2021-09-29 / 最近更新于 2021-09-29 / 366

简要描述

商品详情

接口版本

版本号 制定人 制定日期 修订日期
1.0.0 Devil 2020-09-29

请求URL

goods/detail

请求方式

POST

公共参数

参数名 是否必须 类型 默认值 描述
application string web 请求应用、参考公共中详解
application_client_type string pc 请求客户端、参考公共中详解
token string token

请求参数

{
    "goods_id": "12"
}
参数名 是否必须 类型 默认值 描述
goods_id int 商品id

返回示例

正确时返回

{
    "msg": "success",
    "code": 0,
    "data": {
        "goods": {
            "id": "12",
            "shop_id": "0",
            "shop_user_id": "0",
            "shop_category_id": "0",
            "shop_settle_price": "0.00",
            "shop_settle_rate": "0.00",
            "brand_id": "2",
            "site_type": "4",
            "title": "ZK星星绣花雪纺连衣裙中长款sukol裙少女心温柔超仙女chic裙子夏",
            "title_color": "",
            "simple_desc": "轻奢醋酸面料,高标准的生产要求,品质保证",
            "model": "hello",
            "place_origin": "2",
            "inventory": "3540",
            "inventory_unit": "箱",
            "images": "https://d1.shopxo.vip/static/upload/images/goods/2019/01/14/1547455890402147.jpg",
            "original_price": "0.10-235.00",
            "min_original_price": "2.00",
            "max_original_price": "673.00",
            "price": "0.08-188.00",
            "min_price": "0.08",
            "max_price": "188.00",
            "give_integral": "100",
            "buy_min_number": "1",
            "buy_max_number": "0",
            "is_deduction_inventory": "1",
            "is_shelves": "1",
            "content_web": "


112233445566
qwerty
asdfgh
zxcvbn


\"d-1.jpg\"/

\"d-2.jpg\"/

", "photo_count": "3", "sales_count": "25", "access_count": "3143", "video": "https://d1.shopxo.vip/static/upload/video/goods/2019/01/14/1547458876723311.mp4", "is_exist_many_spec": "1", "spec_base": "", "plugins_membershiplevelvip_price_extends": "", "seo_title": "ZK爆款连衣裙", "seo_keywords": "连衣裙,裙子", "seo_desc": "夏季连衣裙,瘦身裙子", "is_delete_time": "0", "add_time": "2019-01-14 16:57:10", "upd_time": "2021-09-28 15:45:52", "price_container": { "price": "0.10-235.00", "min_price": "0.10", "max_price": "235.00", "original_price": "2.00-673.00", "min_original_price": "2.00", "max_original_price": "673.00" }, "goods_url": "https://d1.shopxo.vip/goods/index/id/12.html", "photo": [ { "id": "899", "goods_id": "12", "images": "https://d1.shopxo.vip/static/upload/images/goods/2019/01/14/1547455890402147.jpg", "is_show": "1", "sort": "0", "add_time": "1632815152", "images_old": "/static/upload/images/goods/2019/01/14/1547455890402147.jpg" }, { "id": "900", "goods_id": "12", "images": "https://d1.shopxo.vip/static/upload/images/goods/2019/01/14/1547455907256518.jpg", "is_show": "1", "sort": "1", "add_time": "1632815152", "images_old": "/static/upload/images/goods/2019/01/14/1547455907256518.jpg" }, { "id": "901", "goods_id": "12", "images": "https://d1.shopxo.vip/static/upload/images/goods/2019/01/14/1547455907486857.jpg", "is_show": "1", "sort": "2", "add_time": "1632815152", "images_old": "/static/upload/images/goods/2019/01/14/1547455907486857.jpg" } ], "images_old": "/static/upload/images/goods/2019/01/14/1547455890402147.jpg", "video_old": "/static/upload/video/goods/2019/01/14/1547458876723311.mp4", "place_origin_name": "天津市", "brand_name": "佳洁士", "specifications": { "choose": [ { "id": "508", "goods_id": "12", "value": [ { "name": "粉色", "images": "" }, { "name": "白色", "images": "" } ], "name": "颜色", "add_time": "2021-09-29 17:57:56" }, { "id": "509", "goods_id": "12", "value": [ { "name": "S+S", "images": "" }, { "name": "M+M", "images": "" } ], "name": "尺码", "add_time": "2021-09-29 17:57:56" } ] }, "parameters": { "base": [ { "name": "流行元素/工艺", "value": "树脂固色" }, { "name": "款式", "value": "长款连衣裙" }, { "name": "适用年龄", "value": "30-34周岁" }, { "name": "款式类别", "value": "图案花纹" } ], "detail": [ { "name": "流行元素/工艺", "value": "树脂固色" }, { "name": "图案", "value": "纯色" }, { "name": "袖长", "value": "短袖" }, { "name": "风格", "value": "复古风" }, { "name": "衣门襟", "value": "套头" }, { "name": "裙型", "value": "大摆型" }, { "name": "组合形式", "value": "单件" }, { "name": "款式类别", "value": "图案花纹" } ] }, "show_field_original_price_text": "原价", "show_field_price_text": "秒杀价", "plugins_view_panel_data": [ "该商品支持积分全额兑换、仅需1积分" ], "plugins_view_icon_data": [ { "name": "积分兑换", "br_color": "#fb7364", "color": "#fb7364" } ], "is_favor": 1, "comments_count": 5, "comments_score": { "avg": "3.6", "rate": 72, "rating": [ { "rating": 1, "name": "1分", "count": "1", "portion": 20 }, { "rating": 2, "name": "2分", "count": 0, "portion": 0 }, { "rating": 3, "name": "3分", "count": "1", "portion": 20 }, { "rating": 4, "name": "4分", "count": "1", "portion": 20 }, { "rating": 5, "name": "5分", "count": "2", "portion": 40 } ] }, "comments_data": [ { "id": "5", "user_id": "1", "order_id": "161", "business_type": "order", "content": "购物很不愉快,,,", "reply": "亲,我这边让客服联系您处理,为您带来不便、请见谅!", "is_reply": "1", "rating": "1", "images": "", "is_anonymous": "0", "reply_time": "1632844129", "add_time": "1632843954", "user": { "avatar": "https://d1.shopxo.vip/static/index/default/images/default-user-avatar.jpg", "user_name_view": "q***q" }, "business_type_text": "订单", "msg": null, "rating_text": "1分", "rating_badge": "danger", "is_reply_text": "是", "is_anonymous_text": "否", "reply_time_time": "2021-09-28 23:48:49", "reply_time_date": "09-28 23:48", "add_time_hour": "23:45:54", "add_time_time": "2021-09-28 23:45:54", "add_time_date": "09-28 23:45" }, { "id": "4", "user_id": "1", "order_id": "162", "business_type": "order", "content": "值得购买,推荐大家都来买,这家衣服穿着很舒服,客服服务很好", "reply": "感谢支持,欢迎再次光临", "is_reply": "1", "rating": "5", "images": "", "is_anonymous": "1", "reply_time": "1632844143", "add_time": "1632843929", "user": { "avatar": "https://d1.shopxo.vip/static/index/default/images/default-user-avatar.jpg", "user_name_view": "匿名" }, "business_type_text": "订单", "msg": null, "rating_text": "5分", "rating_badge": "success", "is_reply_text": "是", "is_anonymous_text": "是", "reply_time_time": "2021-09-28 23:49:03", "reply_time_date": "09-28 23:49", "add_time_hour": "23:45:29", "add_time_time": "2021-09-28 23:45:29", "add_time_date": "09-28 23:45" }, { "id": "3", "user_id": "1", "order_id": "163", "business_type": "order", "content": "无色差,就是物流慢了一些,半个多月才送过来", "reply": "", "is_reply": "0", "rating": "3", "images": [ "https://d1.shopxo.vip/static/upload/images/order_comments/1/163/2021/09/28/1632843880374726.png" ], "is_anonymous": "0", "reply_time": "0", "add_time": "1632843884", "user": { "avatar": "https://d1.shopxo.vip/static/index/default/images/default-user-avatar.jpg", "user_name_view": "q***q" }, "business_type_text": "订单", "msg": null, "rating_text": "3分", "rating_badge": "secondary", "is_reply_text": "否", "is_anonymous_text": "否", "reply_time_time": null, "reply_time_date": null, "add_time_hour": "23:44:44", "add_time_time": "2021-09-28 23:44:44", "add_time_date": "09-28 23:44" } ], "category_names": [ "运动健康", "羽毛球", "乒乓球" ] }, "common_cart_total": 6, "buy_button": { "count": 2, "data": [ { "color": "main", "type": "buy", "title": "点此按钮到下一步确认购买信息", "name": "立即购买", "class": "", "icon": "" }, { "color": "second", "type": "cart", "title": "加入购物车", "name": "加入购物车", "class": "", "icon": "am-icon-opencart" } ], "error": "" }, "middle_tabs_nav": [ { "name": "商品", "ent": ".page" }, { "name": "评价", "ent": ".goods-comment" }, { "name": "详情", "ent": ".goods-detail" } ], "plugins_limitedtimediscount_data": { "time": { "hours": 259, "minutes": "07", "seconds": 50, "status": 1, "msg": "进行中" }, "icon": "https://d1.shopxo.vip/static/plugins/images/limitedtimediscount/icon.png", "title": "限时秒杀", "desc": "距离结束还有", "is_valid": 1, "bg_img": "https://d1.shopxo.vip/static/plugins/images/limitedtimediscount/bg-img.png", "field": "value" }, "plugins_salerecords_data": { "base": { "order_random_max_number": "", "home_bottom_number": "14", "home_bottom_title": "", "home_bottom_desc": "看看大家都买了那些", "goods_detail_number": "", "goods_detail_time_pause": "", "goods_detail_time_interval": "", "goods_detail_tips": "刚刚,1分钟前,3分钟前,2分钟前,30秒前,5分钟前,10分钟前,8分钟前,20秒前", "goods_detail_tips_location": "bottom-center", "is_home_bottom": "1", "is_goods_detail": "1", "order_status": [], "order_status_text": "", "goods_detail_tips_location_text": "下中" }, "data": [ { "user_id": "9", "order_id": "1", "goods_id": "12", "title": "ZK星星绣花雪纺连衣裙中长款sukol裙少女心温柔超仙女chic裙子夏", "images": "https://d1.shopxo.vip/static/upload/images/goods/2019/01/14/1547455890402147.jpg", "buy_number": "1", "add_time": "07-29 18:09", "goods_url": "https://d1.shopxo.vip/goods/index/id/12.html", "user": { "username": "", "nickname": "gongfuxiang", "mobile": "", "email": "", "avatar": "https://sf3-cdn-tos.toutiaostatic.com/img/mosaic-legacy/3792/5112637127~300x300.image", "province": "", "city": "", "id": "9", "mobile_security": "", "email_security": "", "user_name_view": "g***g" }, "unit": "箱", "tips": "g***g2分钟前购买了1箱!" } ] }, "plugins_coupon_data": { "base": { "application_name": "领劵中心", "banner_images": "https://d1.shopxo.vip/static/upload/images/plugins_coupon/2019/08/11/1565509481242251.jpg", "banner_bg_color": "", "banner_url": "", "banner_is_window_open": "1", "banner_images_old": "/static/upload/images/plugins_coupon/2019/08/11/1565509481242251.jpg" }, "data": [ { "id": "1", "name": "满100减5元", "desc": "满100减5元", "bg_color": "0", "type": "0", "discount_value": "5", "expire_type": "0", "expire_hour": "2232", "fixed_time_start": "", "fixed_time_end": "", "where_order_price": "100.00", "use_limit_type": "0", "use_value_ids": "", "limit_send_count": "0", "already_send_count": "1704", "sort": "0", "is_enable": "1", "is_user_receive": "1", "is_regster_send": "0", "add_time": "1580631944", "upd_time": "1580632280", "is_operable": 0, "is_operable_name": "已领取", "type_name": "满减劵", "type_unit": "元", "bg_color_name": "红色", "bg_color_value": "#D2364C", "expire_type_name": "领取生效", "use_limit_type_name": "全场适用", "use_value_ids_all": [], "use_value_ids_str": "", "is_enable_name": "是", "is_user_receive_name": "是", "is_regster_send_name": "否", "add_time_time": "2020-02-02 16:25:44", "upd_time_time": "2020-02-02 16:31:20" } ] } } }

错误时返回

{
    "msg": "error",
    "code": -1,
    "data": []
}

返回参数说明 -> data

参数名 是否必须 类型 描述
goods object 商品数据
common_cart_total int 购物车总数
buy_button array 购买操作按钮列表
middle_tabs_nav array 顶部导航
plugins_limitedtimediscount_data array 限时秒杀 - 插件
plugins_salerecords_data array 购买记录 - 插件
plugins_coupon_data array 优惠券 - 插件

备注

更多返回错误代码请看首页的错误代码描述

0 人点赞过