crawl_config.json 8.93 KB
{
  "project": "interactive-video-selector",
  "taskId": "T-mnwku1ux",
  "ethical_policy": {
    "respect_robots_txt": true,
    "minimum_request_interval_seconds": 2,
    "max_retries": 3,
    "retry_backoff_seconds": 5,
    "user_agent_rotation": true,
    "proxy_rotation": false,
    "rate_limit_per_domain": {
      "apis.tianapi.com": 1,
      "api.bilibili.com": 2,
      "app.bilibili.com": 2,
      "api.tikhub.io": 2,
      "api.itapi.cn": 2,
      "api.suyanw.cn": 2,
      "www.dataeye.com": 5,
      "fishc.com.cn": 3,
      "github.com": 2,
      "default": 2
    }
  },
  "sources": [
    {
      "id": "tianapi-douyinhot",
      "name": "天聚数行-抖音热搜榜",
      "type": "api",
      "auth_required": true,
      "endpoint": "https://apis.tianapi.com/douyinhot/index",
      "method": "GET",
      "headers": {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
        "Accept": "application/json",
        "Accept-Encoding": "gzip, deflate",
        "Connection": "keep-alive"
      },
      "params": {
        "key": "${TIANAPI_KEY}"
      },
      "parser": {
        "root_path": "result.list",
        "fields": {
          "word": "word",
          "label": "label",
          "hotindex": "hotindex"
        }
      },
      "tags": ["抖音", "热搜", "趋势", "短剧选题"],
      "notes": "返回抖音App热门搜索榜单,50条热点视频话题及热度排名。建议每小时调用1次。"
    },
    {
      "id": "tianapi-networkhot",
      "name": "天聚数行-全网热搜榜",
      "type": "api",
      "auth_required": true,
      "endpoint": "https://apis.tianapi.com/networkhot/index",
      "method": "GET",
      "headers": {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36",
        "Accept": "application/json"
      },
      "params": {
        "key": "${TIANAPI_KEY}"
      },
      "parser": {
        "root_path": "result.list",
        "fields": {
          "title": "title",
          "digest": "digest",
          "hotnum": "hotnum"
        }
      },
      "tags": ["全网", "聚合", "微博", "抖音", "百度", "知乎", "选题热点"],
      "notes": "聚合微博、抖音、百度、知乎等平台热点,返回全网实时热搜事件榜单。"
    },
    {
      "id": "bilibili-web-search-square",
      "name": "B站-Web端热搜列表",
      "type": "api",
      "auth_required": false,
      "endpoint": "https://api.bilibili.com/x/web-interface/search/square",
      "method": "GET",
      "headers": {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
        "Referer": "https://search.bilibili.com/",
        "Accept": "application/json, text/plain, */*"
      },
      "params": {
        "limit": 20
      },
      "parser": {
        "root_path": "data.trending.list",
        "fields": {
          "keyword": "keyword",
          "show_name": "show_name",
          "icon": "icon",
          "uri": "uri"
        }
      },
      "tags": ["B站", "热搜", "ACG", "二创", "知识", "互动视频"],
      "notes": "新版接口可能需要Wbi签名。如失败可降级到 app.bilibili.com 手机端接口。请求间隔≥2秒。"
    },
    {
      "id": "bilibili-app-trending",
      "name": "B站-手机端热搜列表",
      "type": "api",
      "auth_required": false,
      "endpoint": "https://app.bilibili.com/x/v2/search/trending/ranking",
      "method": "GET",
      "headers": {
        "User-Agent": "Mozilla/5.0 (Linux; Android 10; SM-G973F) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Mobile Safari/537.36",
        "Accept": "application/json"
      },
      "params": {
        "limit": 20
      },
      "parser": {
        "root_path": "data.list",
        "fields": {
          "position": "position",
          "keyword": "keyword",
          "show_name": "show_name",
          "hot_id": "hot_id"
        }
      },
      "tags": ["B站", "热搜", "移动端", "互动短剧", "弹幕文化"],
      "notes": "备用接口,默认返回20条,最大100条。"
    },
    {
      "id": "tikhub-bilibili-hotsearch",
      "name": "TikHub-B站Web热门搜索",
      "type": "api",
      "auth_required": true,
      "endpoint": "https://api.tikhub.io/api/v1/bilibili/web/fetch_hot_search",
      "method": "GET",
      "headers": {
        "Authorization": "Bearer ${TIKHUB_API_KEY}",
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36",
        "Accept": "application/json"
      },
      "params": {
        "limit": 20
      },
      "parser": {
        "root_path": "data",
        "fields": {
          "keyword": "keyword",
          "show_name": "show_name",
          "hot_id": "hot_id"
        }
      },
      "tags": ["B站", "第三方API", "热搜", "结构化数据"],
      "notes": "TikHub为商业API,需付费。可作为B站官方接口不稳定时的热备方案。"
    },
    {
      "id": "tikhub-kuaishou-hotlist",
      "name": "TikHub-快手热榜",
      "type": "api",
      "auth_required": true,
      "endpoint": "https://api.tikhub.io/api/v1/kuaishou/web/fetch_kuaishou_hot_list_v2",
      "method": "GET",
      "headers": {
        "Authorization": "Bearer ${TIKHUB_API_KEY}",
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36",
        "Accept": "application/json"
      },
      "params": {
        "limit": 20
      },
      "parser": {
        "root_path": "data",
        "fields": {
          "title": "title",
          "hot_value": "hot_value",
          "rank": "rank"
        }
      },
      "tags": ["快手", "热榜", "老铁文化", "下沉市场", "互动短剧"],
      "notes": "商业API,用于补充快手端热点。"
    },
    {
      "id": "itapi-kuaishou",
      "name": "顺为数据-快手热榜",
      "type": "api",
      "auth_required": true,
      "endpoint": "https://api.itapi.cn/api/hotnews/kuaishou",
      "method": "GET",
      "headers": {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36",
        "Accept": "application/json"
      },
      "params": {
        "key": "${ITAPI_KEY}"
      },
      "parser": {
        "root_path": "data.list",
        "fields": {
          "title": "title",
          "hot": "hot",
          "url": "url"
        }
      },
      "tags": ["快手", "热榜", "备选API"],
      "notes": "国内第三方数据接口,价格通常低于TikHub,可用于快手热榜补充。"
    },
    {
      "id": "dataeye-report-pdf",
      "name": "DataEye-微短剧行业报告",
      "type": "static",
      "auth_required": false,
      "endpoint": "https://www.dataeye.com/report/",
      "method": "GET",
      "headers": {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36",
        "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"
      },
      "parser": {
        "type": "html",
        "selector": "a[href$='.pdf']",
        "attribute": "href",
        "post_process": [
          "absolute_url",
          "dedup"
        ]
      },
      "tags": ["行业报告", "DataEye", "热力榜", "投流", "用户画像"],
      "notes": "DataEye公开报告页面,可提取PDF链接。无需高频爬取,每月检查一次是否有新报告即可。"
    },
    {
      "id": "github-bilibili-api-collect",
      "name": "GitHub-bilibili-API-collect",
      "type": "static",
      "auth_required": false,
      "endpoint": "https://github.com/pskdje/bilibili-API-collect/blob/main/docs/search/hot.md",
      "method": "GET",
      "headers": {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36",
        "Accept": "text/html"
      },
      "parser": {
        "type": "html",
        "selector": "article",
        "extract": "text"
      },
      "tags": ["B站", "API文档", "技术参考", "热搜接口"],
      "notes": "社区维护的B站API文档。可作为技术实现参考。"
    },
    {
      "id": "businessofapps-short-drama-report",
      "name": "Business of Apps-2025 Short Drama Report",
      "type": "static",
      "auth_required": false,
      "endpoint": "https://www.businessofapps.com/insights/the-2025-short-drama-report/",
      "method": "GET",
      "headers": {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36",
        "Accept": "text/html"
      },
      "parser": {
        "type": "html",
        "selector": "article, .entry-content, main",
        "extract": "text"
      },
      "tags": ["出海", "海外短剧", "ReelShort", "全球市场", "YouTube Shorts"],
      "notes": "海外市场与用户付费数据的重要参考源。"
    }
  ],
  "output_schema": {
    "required_fields": [
      "source_url",
      "crawl_time"
    ],
    "recommended_fields": [
      "title",
      "platform",
      "tags",
      "heat_value",
      "heat_label",
      "record_type",
      "snapshot"
    ]
  }
}