全部
淘宝客
在线测试

淘宝客-公用-淘口令生成


接口地址: http://api.vv-tool.com/tool/taobaoke/tklcreate


接口介绍: 提供淘口令生成接口。提交需要生成淘口令的内容、logo、url 等参数,生成淘口令,其中关键信息为 ¥ SADadW ¥,后续可基于淘口令进行文案包装组装用于传播。点击查看详情


必须用户授权 : 需要用户的授权,才能拿到被授权的数据


请求方式: POST


返回格式: JSON


接口收费: 联系运营


频率限制: 10 次/秒


请求头参数

参数 类型 必选 示例
Authorization string 授权 access_token Bearer 1798c6aadec33d1bc2f5b707f1049aefexxxx

请求参数

名称 类型 必须 示例值 描述
url String true https://s.click.taobao.com/YI3Uopu 联盟官方渠道获取的淘客推广链接,请注意,不要随意篡改官方生成的链接,否则可能无法生成淘口令
text String false noMeaningValue 兼容旧版本 API 参数,无实际作用
logo String false noMeaningValue 兼容旧版本 API 参数,无实际作用
ext String false noMeaningValue 兼容旧版本 API 参数,无实际作用
user_id String false noMeaningValue 兼容旧版本 API 参数,无实际作用
taobao_user_id String true 123 授权的用户 ID

请求示例

{
"url":"http://s.click.taobao.com/t?e=m%3D2%26s%3DMzGvqf5706wcQipKwQzePOeEDrYVVa64r4ll3HtqqoxyINtkUhsv0Mb5HE%2F1MzuAxSj%2FdG%2F%2BikJoa7aze8VfzILxoap%2B%2FYz8vcPqO1FKbghk9F7u1u5eifuzV7pzkENNSBaygToy7XnUr8WZJ6OtvrG5hBzwUurRSRc3PgFy2%2BWteK%2Fp%2BjtO4sCY0%2FrGuVtlIYULNg46oBA%3D&scm=null&pvid=100_11.229.159.208_165032_3031659686643031644&app_pvid=59590_33.3.211.241_864_1659686643027&ptl=floorId:2836;originalFloorId:2836;pvid:100_11.229.159.208_165032_3031659686643031644;app_pvid:59590_33.3.211.241_864_1659686643027&xId=1bk7N77dmBNmetQwCt0YSyZQKZmlrjHZMFD0y6YTwpZlg5fXjxhhHEiCvwIVeWARcqNNGrf3LV9iicATwvx1nmcEb6SU4cDigJNNH0tBMpGB&union_lens=lensId%3AMAPI%401659686643%402103d3f1_0c03_1826d0865e1_9ca4%4001",
"taobao_user_id":12345
}


请求代码示例

cURL请求代码示例
curl --location --request POST 'http://api.vv-tool.com/tool/taobaoke/tklcreate' \
--header 'Authorization: Bearer XXXXXXXXXXXXXXXXXX' \
--header 'Content-Type: application/json' \
--header 'Cookie: __yjs_duid=1_631b442499ed9f835d199def5892e4091628487614220; PHPSESSID=23cb193174e4095b141ccd6f6007733f; _csrf=2cd19402adae1c3113d9f645faab88a25cbaa984b70d96822c180b7eb5a081e2a%3A2%3A%7Bi%3A0%3Bs%3A5%3A%22_csrf%22%3Bi%3A1%3Bs%3A32%3A%22yN3ZzOyIK8RcBRyag4P7WS66SlTkGj-Q%22%3B%7D' \
--data-raw '{
    "url": "http://s.click.taobao.com/t?e=m%3D2%26s%3DMzGvqf5706wcQipKwQzePOeEDrYVVa64r4ll3HtqqoxyINtkUhsv0Mb5HE%2F1MzuAxSj%2FdG%2F%2BikJoa7aze8VfzILxoap%2B%2FYz8vcPqO1FKbghk9F7u1u5eifuzV7pzkENNSBaygToy7XnUr8WZJ6OtvrG5hBzwUurRSRc3PgFy2%2BWteK%2Fp%2BjtO4sCY0%2FrGuVtlIYULNg46oBA%3D&scm=null&pvid=100_11.229.159.208_165032_3031659686643031644&app_pvid=59590_33.3.211.241_864_1659686643027&ptl=floorId:2836;originalFloorId:2836;pvid:100_11.229.159.208_165032_3031659686643031644;app_pvid:59590_33.3.211.241_864_1659686643027&xId=1bk7N77dmBNmetQwCt0YSyZQKZmlrjHZMFD0y6YTwpZlg5fXjxhhHEiCvwIVeWARcqNNGrf3LV9iicATwvx1nmcEb6SU4cDigJNNH0tBMpGB&union_lens=lensId%3AMAPI%401659686643%402103d3f1_0c03_1826d0865e1_9ca4%4001",
    "taobao_user_id": 2208551696445
}'

PHP请求代码示例

<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'http://api.vv-tool.com/tool/taobaoke/tklcreate',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS =>'{
    "url": "http://s.click.taobao.com/t?e=m%3D2%26s%3DMzGvqf5706wcQipKwQzePOeEDrYVVa64r4ll3HtqqoxyINtkUhsv0Mb5HE%2F1MzuAxSj%2FdG%2F%2BikJoa7aze8VfzILxoap%2B%2FYz8vcPqO1FKbghk9F7u1u5eifuzV7pzkENNSBaygToy7XnUr8WZJ6OtvrG5hBzwUurRSRc3PgFy2%2BWteK%2Fp%2BjtO4sCY0%2FrGuVtlIYULNg46oBA%3D&scm=null&pvid=100_11.229.159.208_165032_3031659686643031644&app_pvid=59590_33.3.211.241_864_1659686643027&ptl=floorId:2836;originalFloorId:2836;pvid:100_11.229.159.208_165032_3031659686643031644;app_pvid:59590_33.3.211.241_864_1659686643027&xId=1bk7N77dmBNmetQwCt0YSyZQKZmlrjHZMFD0y6YTwpZlg5fXjxhhHEiCvwIVeWARcqNNGrf3LV9iicATwvx1nmcEb6SU4cDigJNNH0tBMpGB&union_lens=lensId%3AMAPI%401659686643%402103d3f1_0c03_1826d0865e1_9ca4%4001",
    "taobao_user_id": 2208551696445
}',
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer XXXXXXXXXXXXXXXXXX',
    'Content-Type: application/json',
    'Cookie: __yjs_duid=1_631b442499ed9f835d199def5892e4091628487614220; PHPSESSID=23cb193174e4095b141ccd6f6007733f; _csrf=2cd19402adae1c3113d9f645faab88a25cbaa984b70d96822c180b7eb5a081e2a%3A2%3A%7Bi%3A0%3Bs%3A5%3A%22_csrf%22%3Bi%3A1%3Bs%3A32%3A%22yN3ZzOyIK8RcBRyag4P7WS66SlTkGj-Q%22%3B%7D'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;

JAVA请求代码示例
OkHttpClient client = new OkHttpClient().newBuilder()
  .build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\r\n    \"url\": \"http://s.click.taobao.com/t?e=m%3D2%26s%3DMzGvqf5706wcQipKwQzePOeEDrYVVa64r4ll3HtqqoxyINtkUhsv0Mb5HE%2F1MzuAxSj%2FdG%2F%2BikJoa7aze8VfzILxoap%2B%2FYz8vcPqO1FKbghk9F7u1u5eifuzV7pzkENNSBaygToy7XnUr8WZJ6OtvrG5hBzwUurRSRc3PgFy2%2BWteK%2Fp%2BjtO4sCY0%2FrGuVtlIYULNg46oBA%3D&scm=null&pvid=100_11.229.159.208_165032_3031659686643031644&app_pvid=59590_33.3.211.241_864_1659686643027&ptl=floorId:2836;originalFloorId:2836;pvid:100_11.229.159.208_165032_3031659686643031644;app_pvid:59590_33.3.211.241_864_1659686643027&xId=1bk7N77dmBNmetQwCt0YSyZQKZmlrjHZMFD0y6YTwpZlg5fXjxhhHEiCvwIVeWARcqNNGrf3LV9iicATwvx1nmcEb6SU4cDigJNNH0tBMpGB&union_lens=lensId%3AMAPI%401659686643%402103d3f1_0c03_1826d0865e1_9ca4%4001\",\r\n    \"taobao_user_id\": 2208551696445\r\n}");
Request request = new Request.Builder()
  .url("http://api.vv-tool.com/tool/taobaoke/tklcreate")
  .method("POST", body)
  .addHeader("Authorization", "Bearer XXXXXXXXXXXXXXXXXX")
  .addHeader("Content-Type", "application/json")
  .addHeader("Cookie", "__yjs_duid=1_631b442499ed9f835d199def5892e4091628487614220; PHPSESSID=23cb193174e4095b141ccd6f6007733f; _csrf=2cd19402adae1c3113d9f645faab88a25cbaa984b70d96822c180b7eb5a081e2a%3A2%3A%7Bi%3A0%3Bs%3A5%3A%22_csrf%22%3Bi%3A1%3Bs%3A32%3A%22yN3ZzOyIK8RcBRyag4P7WS66SlTkGj-Q%22%3B%7D")
  .build();
Response response = client.newCall(request).execute();

响应参数

名称 类型 示例值 描述
data MapData 返回结果对象
password_simple String ¥ SIH6XbwRfyt ¥ 非苹果 ios14 以上版本的设备(即其他 iOS 版本、Android 系统等),可以用此淘口令正常在复制到手淘打开
model String 8 緮置内容 ¥ hxlgccEumBB ¥ 达开?τ ao 寶?或掂击炼接 https://m.tb.cn/h.VvkiWSm 至浏。览览。器【618 超级红包】 针对苹果 ios14 及以上版本的苹果设备,手淘将按照示例值信息格式读取淘口令(需包含:数字 + 羊角符 +url,识别规则可能根据 iOS 情况变更)。如需更改淘口令内文案、url 等内容,请务必先验证更改后的淘口令在手淘可被识别打开!
withholding_money INT 11 该接口扣费金额(点券)

返回数据

{
    "code": 0,
    "msg": "成功",
    "msec": 433,
    "time": 1659923129,
    "data": {
        "request_id": "15ro1n7xsqi9u",
        "Body": "",
        "data": {
            "password_simple": "¥4DBC2Hdq0dh¥",
            "model": "29¥4DBC2Hdq0dh¥ https://m.tb.cn/h.fBJoIsa  CZ0001 JHS可移动空调家用免安装一体机厨房宿舍迷你立式单冷小空调A019A"
        },
        "withholding_money": 0
    }
}

响应代码

代码 代码描述 解决方案
0 成功
100 请求参数错误 检查您的请求参数是否正确
101 请求超时,请重试 检查您的网络情况或者联系客服解决
103 旺旺账号不存在 检查您输入的旺旺号是否正确
200 系统错误,请联系客服 检查您的接口地址填写是否正确,其他问题联系客服解决
202 系统错误,请稍后再试 稍后重试,或者联系对接群
203 暂不支持当前接口
204 请求异常:无该接口权限,请前往官网开通正式接口。 前往官网开通该接口权限
204 请求异常:API 调用次数不足,请前往网站兑换次数。 前往官网充值该接口调用次数
302 未授权店铺 根据返回链接进行扫码授权
401 身份凭证无效 在请求头中添加 access_token,重新更新 token
404 请求路径或请求方式错误 请更换请求方式或者检查路径是否正确