API文档中心

热门接口:产品ID找同款全量维权查询万能转链字符串ID转换 (有API需求可联系本站)

批量检测商品是否下架,是否为营销库产品,批量查询商品信息

调用权限:核心接口会员卡调用
接口使用场景等说明:

本接口功能:

1、批量查询商品信息

2、批量检测是否为淘客商品或下架。

3、批量检测产品是否为营销库产品(返回值字段material_lib_type=1时为营销库产品),当您要用到会员运营ID时,会使用到。

调用说明

本接口需要您在会员中心授权(如果多用户可传入sessionkey参数)

接口请求地址

环境 http 地址 https 地址
正式环境 http://api.veapi.cn/tbk/tkiteminfo 暂无

请求方式:GETPOST

请求参数

参数名称 参数类型 必填 示例值 描述
vekey String V123M56 公共参数,接口秘钥,请在会员中心获取
ids String Wnr7tQPxtQCg-BVORbxsrv3jZY 你要检测的批量商品ID列表,用英文逗号相连。一次最大40个ID。ID必须是A-B全段字符型ID入参。如:
5mmRxkntxt0G74DC0OWHYCV-krVR92U8kAGPDqvT5,4DDqWdyigtYWnr7tQPxtQCg-BVORbxsrv3jZYn2HD6

请求示例

  • HTTP
  • PHP
  • JAVA
  • PYTHON
GET/POST  http://api.veapi.cn/tbk/getitems?vekey=xxx&ids=qkOxQw5u2t4v6QV42bU3zqhWt0-WJ3M2bIQKDokWK5UdG,OqMrXY9Tzt6kwn2GyKuVKbiMtJ-KkyBKPijnB2qRnBiny 

使用curl函数,curl不是php原生库,需要安装才能使用

$api="http://api.veapi.cn/tbk/getitems?vekey=xxx&ids=qkOxQw5u2t4v6QV42bU3zqhWt0-WJ3M2bIQKDokWK5UdG,OqMrXY9Tzt6kwn2GyKuVKbiMtJ-KkyBKPijnB2qRnBiny";

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $api);
//curl_setopt($ch, CURLOPT_POST, true);  //POST方式时启用
//curl_setopt($ch, CURLOPT_POSTFIELDS, $postData );  //POST方式时传参

curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);  //如果使用https请启用
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);  //如果使用https请启用
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true );   //返回数据流,不直接输出
curl_setopt($ch, CURLOPT_ENCODING, 'gzip'); //使用gzip压缩传输让访问更快
curl_setopt($ch, CURLOPT_TIMEOUT, 6);  //允许执行的最长秒数。这里设定6S
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 5);

$result = curl_exec($ch);
$info = curl_getinfo($ch);
curl_close($ch);

echo $result; //返回值
使用okhttp3/httpclient/jsoup/hutool,以hutool为例:

import cn.hutool.http.HttpResponse;
import cn.hutool.http.HttpRequest;

public class testGetParam {

    public static void main(String[] args) {
        // API网址
        String url = "http://api.veapi.cn/tbk/getitems?vekey=xxx&ids=qkOxQw5u2t4v6QV42bU3zqhWt0-WJ3M2bIQKDokWK5UdG,OqMrXY9Tzt6kwn2GyKuVKbiMtJ-KkyBKPijnB2qRnBiny";
        // JDK 8u111版本后,若目标页面为HTTPS协议,请启用proxy用户密码鉴权
        //System.setProperty("jdk.http.auth.tunneling.disabledSchemes", "");

        // 发送请求
        String result = HttpRequest.get(url)
                .timeout(10000)//设置超时,毫秒
                .execute().body();
        System.out.println(result);
    }
}
推荐使用 requests,支持访问http,https网页:

import requests
		
# 要访问的API网页
target_url = "http://api.veapi.cn/tbk/getitems?vekey=xxx&ids=qkOxQw5u2t4v6QV42bU3zqhWt0-WJ3M2bIQKDokWK5UdG,OqMrXY9Tzt6kwn2GyKuVKbiMtJ-KkyBKPijnB2qRnBiny"

# 发送请求
response = requests.get(target_url)

# 获取页面内容
if response.status_code == 200:
	print response.text

返回值(JSON)

参数名称 参数类型 示例值 描述
cat_name String 女装 一级类目名称
num_iid String 123 商品ID
title String 连衣裙 商品标题
pict_url String http://gi4.md....jpg 商品主图
small_images String[] http://gi4....jpg 商品小图列表
reserve_price String 102.00 商品一口价格
zk_final_price String 88.00 折扣价(元)若属于预售商品,付定金时间内,折扣价=预售价
user_type Number 1 卖家类型,0表示集市,1表示商城,3表示特价版
provcity String 杭州 商品所在地
item_url String http://detail..id=xxx 商品链接
seller_id Number 123 卖家id
volume Number 1 30天销量
nick String xx旗舰店 店铺名称
cat_leaf_name String 情趣内衣 叶子类目名称
is_prepay Boolean true 是否加入消费者保障
shop_dsr Number 23 店铺dsr 评分
ratesum Number 13 卖家等级
i_rfd_rate Boolean true 退款率是否低于行业均值
h_good_rate Boolean true 好评率是否高于行业均值
h_pay_rate30 Boolean true 成交转化是否高于行业均值
free_shipment Boolean true 是否包邮
material_lib_type String 1 商品库类型,支持多库类型输出,以英文逗号分隔“,”分隔,1:营销商品主推库,如果值为空则不属于1这种商品类型
presale_discount_fee_text String 付定金立减20元 预售商品-商品优惠信息
presale_tail_end_time Number 1937297392332 预售商品-付定金结束时间(毫秒)
presale_tail_start_time Number 1937297392332 预售商品-付尾款开始时间(毫秒)
presale_end_time Number 1937297392332 预售商品-付定金结束时间(毫秒)
presale_start_time Number 1937297392332 预售商品-付定金开始时间(毫秒)
presale_deposit String 100 预售商品-定金(元)
ju_play_end_time Number 1937297392332 聚划算满减 -结束时间(毫秒)
ju_play_start_time Number 1937297392332 聚划算满减-开始时间(毫秒)
play_info String 玩法 1聚划算满减:满N件减X元,满N件X折,满N件X元) 2天猫限时抢:前N分钟每件X元,前N分钟满N件每件X元,前N件每件X元)
tmall_play_activity_end_time Number 1937297392332 天猫限时抢可售 -结束时间(毫秒)
tmall_play_activity_start_time Number 1937297392332 天猫限时抢可售 -开始时间(毫秒)
ju_online_start_time String 1581868800000 聚划算信息-聚淘开始时间(毫秒)
ju_online_end_time String 1582300799000 聚划算信息-聚淘结束时间(毫秒)
ju_pre_show_start_time String 1581868800000 聚划算信息-商品预热开始时间(毫秒)
ju_pre_show_end_time String 1582300799000 聚划算信息-商品预热结束时间(毫秒)
sale_price String 168 活动价
kuadian_promotion_info String ["每100减20","每200减50"] 跨店满减信息
superior_brand String 1 是否品牌精选,0不是,1是
hot_flag String 1 是否是热门商品,0不是,1是
input_num_iid String sdfqere-123dfqweq 入参的(新)商品ID

返回示例

【提示】推广链接通常有时效性,示例中的链接为创建文档时生成,仅用于展示返回结果使用,有可能已失效。
{ "error": "0", "msg": "查询成功!", "id_count": 1, "success": 1, "fail": 0, "fail_ids": "", "data": [ { "input_item_iid": "djNkzqhZt3OPPBJMPTDVRtet3-bpYkRdsBoBkzmqNtK", "item_basic_info": { "brand_name": "swisse", "category_name": "鱼油/深海鱼油", "free_shipment": "false", "is_prepay": "true", "item_url": "https://uland.taobao.com/item/edetail?id=G0j6MdqS8tYQ5bWd4QfvbdTgUJ-bpYkRdsBoBkzmqNtK", "level_one_category_name": "保健食品/膳食营养补充食品", "material_lib_type": "1", "pict_url": "https://img.alicdn.com/bao/uploaded/i2/2549841410/O1CN016mN0J51MHpOYucgCA_!!2549841410-0-tmg_sticker_hand.jpg", "provcity": "浙江 杭州", "seller_id": "4692892268749674138", "shop_title": "天猫国际自营全球超级店", "short_title": "Swisse斯维诗高浓度深海鱼油", "small_images": [ "https://img.alicdn.com/i3/2549841410/O1CN01IYQqRF1MHpMSXrjnG_!!2549841410.jpg", "https://img.alicdn.com/i2/2215338820950/O1CN01yQhHRL1It98PNrGqL_!!2215338820950-0-scmitem1000.jpg", "https://img.alicdn.com/i1/2215338820950/O1CN01MfZcJn1It98Jh4Juv_!!2215338820950-0-scmitem1000.jpg", "https://img.alicdn.com/i2/2215338820950/O1CN01Skp8I71It98MTJ04N_!!2215338820950-0-scmitem1000.jpg" ], "superior_brand": "0", "title": "【自营】Swisse斯维诗高浓度深海鱼油omega3软胶囊DHA/EPA400粒", "user_type": "1", "volume": "10000", "white_image": "https://img.alicdn.com/bao/uploaded/O1CN01ClJuvq1ozcTT4YBOV_!!6000000005296-0-yinhe.jpg" }, "item_id": "G0j6MdqS8tYQ5bWd4QfvbdTgUJ-bpYkRdsBoBkzmqNtK", "presale_info": { "presale_deposit": "", "presale_discount_fee_text": "" }, "price_promotion_info": { "final_promotion_path_list": { "final_promotion_path_map_data": [ { "promotion_desc": "每件直降160元", "promotion_end_time": "1711900799000", "promotion_fee": "160", "promotion_start_time": "1711641600000", "promotion_title": "单品直降" }, { "promotion_desc": "满300减30", "promotion_end_time": "1711900799000", "promotion_fee": "30", "promotion_start_time": "1711641600000", "promotion_title": "购物券" } ] }, "final_promotion_price": "149", "more_promotion_list": { "more_promotion_map_data": [ { "promotion_desc": "满600减70", "promotion_end_time": "1711900799000", "promotion_start_time": "1711641600000", "promotion_title": "购物券" }, { "promotion_desc": "满1000减120", "promotion_end_time": "1711900799000", "promotion_start_time": "1711641600000", "promotion_title": "购物券" } ] }, "predict_rounding_up_price": "132.49", "predict_rounding_up_price_desc": "需凑单", "promotion_tag_list": { "promotion_tag_map_data": [ { "tag_name": "88VIP95折" }, { "tag_name": "低于去年促销价" } ] }, "reserve_price": "499.00", "zk_final_price": "339" }, "publish_info": { "income_rate": "0.45" } } ], "request_id": "unbieGi" }

错误码

如果error不为0时,请点此查看错误码表格

在线
客服

会员请加QQ群交流:

微信
咨询

加微信咨询
顶部