1. 参数说明

    • 通用参数说明

      • version:API版本
      • key:调用key,测试key:test_api_key
      • api_name:API类型[item_get,item_search]
      • cache:[yes,no]默认yes,将调用缓存的数据,速度比较快
      • result_type:[json,xml,serialize,var_export]返回数据格式,默认为json
      • lang:[cn,en,ru] 翻译语言,默认cn简体中文
    • API:item_get 参数说明: num_iid:宝贝ID

    • 其他接口请参考测试界面参数

  2. 此API目前支持以下基本接口:

    • item_get 获得1688商品详情
    • item_search 按关键字搜索商品
    • item_search_img 按图搜索1688商品(拍立淘)
    • item_search_suggest 获得搜索词推荐
    • item_fee 获得商品快递费用
    • seller_info 获得店铺详情
    • item_search_shop 获得店铺的所有商品
    • item_password 获得淘口令真实url
    • upload_img 上传图片到1688
    • item_search_seller 搜索店铺列表
    • img2text 图片识别商品接口
    • item_get_app 获取1688app上原数据
    • buyer_order_list 获取购买到的商品订单列表
    • cat_get 获得1688商品分类

item_search_img-按图搜索1688商品(拍立淘)

1688.item_search_img

公共参数

名称 类型 必须 描述
key String 调用key(必须以GET方式拼接在URL中)
secret String 调用密钥
api_name String API接口名称(包括在请求地址中)[item_search,item_get,item_search_shop等]
cache String [yes,no]默认yes,将调用缓存的数据,速度比较快
result_type String [json,jsonu,xml,serialize,var_export]返回数据格式,默认为json,jsonu输出的内容中文可以直接阅读
lang String [cn,en,ru]翻译语言,默认cn简体中文
version String API版本

请求参数

请求参数:imgid=http://g-search3.alicdn.com/img/bao/uploaded/i4/O1CN01IDpcD81zHbpHs1YgT_!!2200811456689.jpg

参数说明:imgid:图片地址(使用淘宝upload_img接口上传图片,返回图片地址)
如:https://img.alicdn.com/imgextra/i3/15353738/TB2HDHAqN9YBuNjy0FfXXXIsVXa_!!15353738-0-beehive-scenes.jpg

响应参数

Version: Date:

名称 类型 必须 示例值 描述

items

items[] 0 按图搜索1688商品

请求示例

Curl

-- 请求示例 url 默认请求参数已经URL编码处理
curl -i "https://api-gw.onebound.cn/1688/item_get/?key=<您自己的apiKey>&secret=<您自己的apiSecret>&num_iid=610947572360"

PHP

<?php// 请求示例 url 默认请求参数已经URL编码处理
// 本示例代码未加密secret参数明文传输,若要加密请参考:https://open.onebound.cn/help/demo/sdk/demo-sign.php
$method = "GET";
$url = "https://api-gw.onebound.cn/1688/item_get/?key=<您自己的apiKey>&secret=<您自己的apiSecret>&num_iid=610947572360";
$curl = curl_init();
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST,FALSE);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER,FALSE);
curl_setopt($curl, CURLOPT_FAILONERROR, false);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_HEADER, true);
curl_setopt($curl, CURLOPT_ENCODING, "gzip");
var_dump(curl_exec($curl));
?>

PHPsdk

<?php
//定义缓存目录和引入文件
define("DIR_RUNTIME","runtime/");
define("DIR_ERROR","runtime/");
define("SECACHE_SIZE","0");
//SDK下载地址 https://open.onebound.cn/help/demo/sdk/onebound-api-sdk.zip
include ("ObApiClient.php");$obapi = new otao\ObApiClient();
$obapi->api_url = "http://api-gw.onebound.cn/";
$obapi->api_urls = array("http://api-gw.onebound.cn/","http://api-1.onebound.cn/");//备用API服务器
$obapi->api_urls_on = true;//当网络错误时,是否启用备用API服务器
$obapi->api_key = "<您自己的apiKey>";
$obapi->api_secret = "<您自己的apiSecret>";
$obapi->api_version ="";
$obapi->secache_path ="runtime/";
$obapi->secache_time ="86400";
$obapi->cache = true;$api_data = $obapi->exec(array("api_type" =>"1688","api_name" =>"item_get","api_params"=>array ('num_iid' => '610947572360',
)));var_dump($api_data);
?>

JAVA

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.Reader;
import java.net.URL;
import java.nio.charset.Charset;
import org.json.JSONException;
import org.json.JSONObject;
import java.io.PrintWriter;
import java.net.URLConnection;public class Example {private static String readAll(Reader rd) throws IOException {StringBuilder sb = new StringBuilder();int cp;while ((cp = rd.read()) != -1) {sb.append((char) cp);}return  sb.toString();}public static JSONObject postRequestFromUrl(String url, String body) throws IOException, JSONException {URL realUrl = new URL(url);URLConnection conn = realUrl.openConnection();conn.setDoOutput(true);conn.setDoInput(true);PrintWriter out = new PrintWriter(conn.getOutputStream());out.print(body);out.flush();InputStream instream = conn.getInputStream();try {BufferedReader rd = new BufferedReader(new InputStreamReader(instream, Charset.forName("UTF-8")));String jsonText = readAll(rd);JSONObject json = new JSONObject(jsonText);return json;} finally {instream.close();}}public static JSONObject getRequestFromUrl(String url) throws IOException, JSONException {URL realUrl = new URL(url);URLConnection conn = realUrl.openConnection();InputStream instream = conn.getInputStream();try {BufferedReader rd = new BufferedReader(new InputStreamReader(instream, Charset.forName("UTF-8")));String jsonText = readAll(rd);JSONObject json = new JSONObject(jsonText);return json;} finally {instream.close();}}public static void main(String[] args) throws IOException, JSONException {// 请求示例 url 默认请求参数已经URL编码处理String url = "https://api-gw.onebound.cn/1688/item_get/?key=<您自己的apiKey>&secret=<您自己的apiSecret>&num_iid=610947572360";JSONObject json = getRequestFromUrl(url);System.out.println(json.toString());}}

item_search_img-按图搜索1688商品(拍立淘)接口的接入参数说明相关推荐

  1. 按图搜索1688商品接口(item_search_img-按图搜索1688商品(拍立淘接口)代码对接教程

    图片上传搜索,按图搜索1688商品接口(item_search_img-按图搜索1688商品(拍立淘接口)代码对接教程: 1.公共参数 名称 类型 必须 描述(代码教程wx19970108018) k ...

  2. 1688以图搜货接口,1688图片搜索接口,拍立淘接口,以图搜商品接口,图片上传搜索商品接口,按图搜索接口代码对接参数说明

    一.接口说明: 有两种方式可以通过图片url地址请求获取到图片上的相似商品列表,然后再次拿到商品详情. 点击获取key和secret 方式一:可以用淘宝/1688平台外的图片进行先上传然后再搜索商品的 ...

  3. 1688.item_search_img按图搜索1688商品(拍立淘)API的调用参数和实例

    item_search_img-按图搜索1688商品(拍立淘) 1688.item_search_img 公共参数 请求地址: 申请调用地址 名称 类型 必须 描述 key String 是 调用ke ...

  4. 电商API按图搜索产品(拍立淘),app产品详情原数据,sku详细信息,分类详情,产品详情页面详情

    一.电商API主要功能: 1.API可输出JSON.XML等格式,能够供PHP.JSP等编程语言调用 ;实现如开放平台:taobao.items.get 和taobao.items.search等功能 ...

  5. 1688API item_search_img - 按图搜索1688商品(拍立淘)

    联系客服测试 Result Object: { "items": { "url": "https://s.onebound.cc/youyuan/in ...

  6. 1688API接口:item_search_img - 按图搜索1688商品(拍立淘

    提供封装好的1688数据接口,通过手机自动化实时采集,接口稳定. 更多API调用展示以及获取Key和secret请移步 Result Object: ------------------------- ...

  7. 按图搜索淘宝商品(拍立淘)接口调用展示

    更多API调用示例展示及获取Key和secret请移步以下内容查看 登录 - 跨境电商平台接口提供商 数据采集公司 数据接口定制服务 企业级数据服务商 {     "items": ...

  8. 淘宝图片上传,拍立淘接口

    以下是淘宝获得图片上传 API 返回值说明.简单调用示例. 需要更多了解和测试调用请移步 http://console.open.onebound.cn/console/?i=Turbo 请求示例: ...

  9. 1688API接口,获取商品详情,按关键词搜索,拍立淘,商品评论商品类目,店铺接口等

    接口所示 item_get获得1688商品详情 item_search按关键字搜索商品 item_search_img按图搜索1688商品(拍 立淘) item_search_shop获得店铺的所有商 ...

最新文章

  1. 时间同步服务器(默认)chrony和ntp
  2. SQLAlchemy按降序排列?
  3. spring3.x企业应用开发实战 pdf_吃透Spring全家桶:Spring源码+SpringBoot+SpringCloud实战...
  4. 手写一个简单的WinForm程序(2)
  5. idea 使用 maven 整合 ssm 框架 实现简单的增、删、改 和 分页查询功能
  6. 怎么保存在界面输入的内容_还在担心忘记密码?使用这款软件轻松找回浏览器中保存的密码...
  7. idea git 注意事项
  8. 项目缺少包如何和服务器,解决缺少服务器依赖包问题
  9. vertical-align属性
  10. 修改计算机设备管理器信息,电脑硬件信息更改器(牛B硬件信息修改大师)
  11. 模拟器xposed框架安装7.1-64教程
  12. 游戏3C之二——镜头
  13. 电子元器件工厂的金蝶ERP与赛意WMS系统数据集成平台进行对接
  14. [Andoid][踩坑]CTS 11_r3开始出现的testBootClassPathAndSystemServerClasspath_nonDuplicateClasses FAIL问题分析
  15. 操作系统——(11)多媒体操作系统
  16. iOS 7最佳实践:一个天气App案例
  17. python 循环实现延时_Python延时操作实现方法示例
  18. python反转一个整数、123变成321,python反转一个三位整数的多种实现方案
  19. linux 系统日志 oom,Linux进程被杀掉(OOM killer),查看系统日志
  20. 实现一个简单的待办事项

热门文章

  1. 计算机软件著作权侵权行为的认定,计算机软件著作权侵权行为认定方法探讨.doc...
  2. 每日总结(第一天)(2020/3/27/22:11)(1/90)
  3. python统计列表中元素个数_python中计算一个列表中连续相同的元素个数方法
  4. GAN生成对抗网络合集(三):InfoGAN和ACGAN-指定类别生成模拟样本的GAN(附代码)
  5. 原生JS,运动的小人
  6. 今天发布视频博主同事制作北极视频第二集-无人机和北极熊
  7. 大疆文档(8)-Android教程-模拟器App
  8. js 获取上下文后面的路径_通过在数据后面显示上下文来可视化公众意见
  9. 环形缓冲区ringbuffer c++类模版实现
  10. 传奇如何读取服务器信息,传奇服务器修改之命令服务脚本详细使用方法介绍