Canoziia
啦啦啦
技术生活 – Dnlab

关于一些api的使用

目前有几个api:

  • 搜索百度网盘番剧 https://sou.dnlab.net/age/api
    post方法提交 php示例:
$post_data = array(
    "secret" => "canoziia",
    "keyword" => $keyword_line,
    "order" => "0"(随机)|"1"(顺序),
    "page" => "1"|"2"...
);
function send_post($url, $post_data) {
    $postdata = http_build_query($post_data);
    $options = array(
        'http' => array(
        'method' => 'POST',
        'header' => 'Content-type:application/x-www-form-urlencoded',
        'content' => $postdata,
        'timeout' => 15       // 超时时间(单位:s)
        )
      );
    $context = stream_context_create($options);
    $result = file_get_contents($url, false, $context);
    return $result;
}
$data_recv = json_decode(send_post("https://sou.dnlab.net/age/api.php", $post_data),true);

其他语言自行摸索

  • 检测动漫图片信息 https://api.dnlab.net/anime-pic-analysis/api
    这个很准
    python示例:
import requests
url = "https://api.dnlab.net/anime-pic-analysis/api"
file = {"file": ("<file-name>", open("<file-path>", "rb"))}
response = requests.post(url, files=file)
  • 动漫图片评分 https://api.dnlab.net/anime-pic-rank/api
    这个不太精确,评分也很有主观性
    python示例:

发表回复

textsms
account_circle
email

技术生活 – Dnlab

关于一些api的使用
目前有几个api: 搜索百度网盘番剧 https://sou.dnlab.net/age/apipost方法提交 php示例: $post_data = array( "secret" => "canoziia", "keyword" => $keyword_lin…
扫描二维码继续阅读
2020-07-16