masterchd

图书信息获取API

返回格式:JSON

https 访问方式,后期会拒绝来自浏览器的直接访问,但是可以通过程序后台调用。

https://explorercloud.cn/api/szme?isbn=9787536023918

  

传的参数是isbn,也就是书籍的识别码

微信小程序的请求方式

wx.request({
      url: 'https://explorercloud.cn/api/szme',
      data:{
        isbn:'9787536023918',
        ssh_code:''//暂时免费使用,ssh_code 可以不填
      },
      method:'POST',
      header: {
        //'content-type': 'application/json' // 默认值
        'Content-Type': 'application/x-www-form-urlencoded'
      },
      success:function(res){
        console.log(res)
      }
    })

  查询结果是

可能会出现的问题:

1.带宽不足,导致访问超时,获取不到数据。

2. 服务器到期,:或者是程序开启验证模式,需要校验ssh_code

 

   出现这种情况可以在下方留言,或者联系QQ:1025584691

相关文章: