OpenClaw Scrapefun
Purpose
Use this skill only for scrapefun operational APIs.
Default rule:
- - Prefer INLINECODE1
- Prefer INLINECODE2
- Do not silently fall back to
/api/metadata, /api/metadata/stats, /api/settings/webdav/search, or INLINECODE6 - If an expected
/api/openclaw/* endpoint returns 404, 403, or validation failure, report the exact blocker instead of switching to an old path unless the fallback is explicitly allowed below
This skill does not perform OpenClaw-side resource discovery.
Auth
Preferred auth:
Fallback auth:
- - INLINECODE11
- Reuse INLINECODE12
Rules:
- - Prefer
OPENCLAW_ACCESS_KEY or the saved skill api key - Never use INLINECODE14
- State the required OpenClaw permissions before calling INLINECODE15
- If a permission is missing, stop and report it
Primary Endpoints
Use these endpoints as the default interface surface:
Required permission:
library_query
Use for listing media entries in a library
Required permission:
library_query
Use for existing files, existing episodes, and missing episodes
Required permission:
download_target_query
Use for target path, season path, storage, and next missing episode
Required permission:
download_dedupe
Use before every download submission
Minimum payload:
{} or
{"seasonNumber":<n>,"episodeNumber":<n>}
Optional fields:
candidateName,
candidateSize, INLINECODE28
Required permission:
download_submit
Use for offline download submission
Minimum payload:
{"metadataId":"<metadataId>","magnet":"<magnet>"} or
{"metadataId":"<metadataId>","urls":["<url>"]}
Optional fields:
preferredPath,
seasonNumber,
episodeNumber, INLINECODE36
Required permission:
download_confirm
Use to verify landed files after submission
Minimum payload:
{"metadataId":"<metadataId>"}
Optional fields:
expectedPath,
seasonNumber,
episodeNumber,
waitMs, INLINECODE44
Required permission:
import_finalize
Use for post-download scan, organize, and verification
Minimum payload:
{"downloadPath":"<webdav path>"}
Optional fields:
seasonNumber,
episodeNumber,
matchMode,
forceScan, INLINECODE52
Required permission:
download_status or one of
download_submit,
download_confirm,
import_finalize
Use for compact workflow status
Required permission:
library_scan
Use only for explicit rescan or forced refresh
Default Operation Order
Use these sequences.
1. List a library
- 1. INLINECODE60
Do not use:
- - INLINECODE61
- INLINECODE62
2. Read a show's current state
- 1. Resolve
metadataId from INLINECODE64 - INLINECODE65
Do not use:
3. Prepare a download
- 1. INLINECODE67
- INLINECODE68
Do not manually combine:
- - INLINECODE69
- INLINECODE70
- INLINECODE71
unless the fallback rules below explicitly allow it
4. Submit a download
- 1. INLINECODE72
Do not call:
directly from this skill
5. Continue after submission
- 1. INLINECODE74
- INLINECODE75
- INLINECODE76
Do not manually combine:
- - INLINECODE77
- INLINECODE78
- INLINECODE79
as the default path
Endpoint Availability Checks
Before relying on a path in your answer, treat these failures distinctly:
- -
404: endpoint not available on this server version - INLINECODE81 : missing OpenClaw permission
- INLINECODE82 : required parameters missing or invalid
Rules:
- - If
catalog, state, download-target, download-check, downloads/submit, confirm-landed, or finalize-import returns 404, say the server does not expose that OpenClaw endpoint - If
GET /api/openclaw/downloads/:downloadId returns 404, report Download workflow not found; do not describe it as route absence - If one of them returns
403, report the exact missing permission and stop - Do not describe a legacy fallback as if it were equivalent
- If
POST /api/openclaw/libraries/scan returns partial: true, report the failed library root paths explicitly
Strict Fallback Rules
Fallback is allowed only in these cases.
Allowed fallback
Use only when the user explicitly asks for raw library config fields such as
path,
scraper,
sourceMode, or INLINECODE101
Use only when the user explicitly asks for raw scraper candidates
Use only when the user explicitly asks for directory-level file enumeration detail that the OpenClaw endpoints do not return
Use only when the user explicitly wants a scan or when
finalize-import is unavailable and the user still wants a best-effort refresh
Disallowed fallback
- - Do not fall back to
GET /api/metadata for library listing - Do not fall back to
GET /api/metadata for missing episode detection - Do not fall back to
GET /api/metadata/stats for media browsing - Do not fall back to
POST /api/settings/webdav/add_offline_download for normal download submission - Do not fall back to
GET /api/settings/webdav/search for normal landed-file checks
Prohibited Endpoints
Do not use:
- - INLINECODE111
- INLINECODE112
- INLINECODE113
- INLINECODE114
- INLINECODE115
- INLINECODE116 remote delegation flow
Response Rules
Keep responses functional only.
Always state:
- - auth method
- endpoint
- required permission
- payload shape
- returned result or blocker
Do not add product commentary or discovery-side explanation unless it is required to explain a blocker.
Examples
View Anime entries
User request:
INLINECODE117
Execution:
- 1. INLINECODE118
Check episodes
User request:
INLINECODE119
Execution:
- 1. Find
metadataId from INLINECODE121 - INLINECODE122
Submit magnet
User request:
INLINECODE123
Execution:
- 1. INLINECODE124
- INLINECODE125
- INLINECODE126 with
metadataId and magnet or INLINECODE129
Continue after download
User request:
INLINECODE130
Execution:
- 1.
POST /api/openclaw/downloads/:downloadId/confirm-landed with INLINECODE132 - INLINECODE133 with INLINECODE134
- INLINECODE135
Raw library config
User request:
INLINECODE136
Execution:
- 1. INLINECODE137
- Return only the matched library's
path, type, sourceMode, scraper, and INLINECODE142
OpenClaw Scrapefun
目的
仅将此技能用于 scrapefun 操作 API。
默认规则:
- - 优先使用 X-OpenClaw-Key
- 优先使用 /api/openclaw/
- 不要静默回退到 /api/metadata、/api/metadata/stats、/api/settings/webdav/search 或 /api/settings/webdav/addofflinedownload
- 如果预期的 /api/openclaw/ 端点返回 404、403 或验证失败,请报告确切阻塞原因,除非下方明确允许回退,否则不要切换到旧路径
此技能不执行 OpenClaw 侧的资源发现。
认证
首选认证方式:
- - 请求头:X-OpenClaw-Key: <访问密钥>
备用认证方式:
- - POST /api/auth/login
- 复用 Authorization: Bearer <令牌>
规则:
- - 优先使用 OPENCLAWACCESSKEY 或已保存的技能 API 密钥
- 切勿使用 OPENCLAWSCRAPEFUNAPI_KEY
- 在调用 /api/openclaw/* 前声明所需的 OpenClaw 权限
- 如果缺少权限,停止并报告
主要端点
使用以下端点作为默认接口:
- - GET /api/openclaw/libraries/catalog
所需权限:library_query
用于列出媒体库中的媒体条目
- - GET /api/openclaw/media/:metadataId/state
所需权限:library_query
用于检查现有文件、现有剧集和缺失剧集
- - GET /api/openclaw/media/:metadataId/download-target
所需权限:download
targetquery
用于获取目标路径、季路径、存储空间和下一个缺失剧集
- - POST /api/openclaw/media/:metadataId/download-check
所需权限:download_dedupe
用于每次提交下载前检查
最小载荷:{} 或 {seasonNumber:
,episodeNumber:}
可选字段:candidateName、candidateSize、strictEpisodeMatch
- - POST /api/openclaw/downloads/submit
所需权限:download_submit
用于离线下载提交
最小载荷:{metadataId:,magnet:<磁力链接>} 或 {metadataId:,urls:[]}
可选字段:preferredPath、seasonNumber、episodeNumber、candidateMeta
- - POST /api/openclaw/downloads/:downloadId/confirm-landed
所需权限:download_confirm
用于提交后验证已落地的文件
最小载荷:{metadataId:}
可选字段:expectedPath、seasonNumber、episodeNumber、waitMs、forceRefresh
- - POST /api/openclaw/media/:metadataId/finalize-import
所需权限:import_finalize
用于下载后的扫描、整理和验证
最小载荷:{downloadPath:}
可选字段:seasonNumber、episodeNumber、matchMode、forceScan、downloadId
- - GET /api/openclaw/downloads/:downloadId
所需权限:downloadstatus 或 downloadsubmit、downloadconfirm、importfinalize 之一
用于获取紧凑的工作流状态
- - POST /api/openclaw/libraries/scan
所需权限:library_scan
仅用于显式重新扫描或强制刷新
默认操作顺序
使用以下序列。
1. 列出媒体库
- 1. GET /api/openclaw/libraries/catalog?libraryName=<名称>
不要使用:
- - GET /api/metadata
- GET /api/metadata/stats
2. 读取剧集的当前状态
- 1. 从 catalog 解析 metadataId
- GET /api/openclaw/media/:metadataId/state
不要使用:
3. 准备下载
- 1. GET /api/openclaw/media/:metadataId/download-target
- POST /api/openclaw/media/:metadataId/download-check
不要手动组合:
- - /api/libraries
- /api/settings/webdav/storage/resolve
- /api/settings/webdav/search
除非下方回退规则明确允许
4. 提交下载
- 1. POST /api/openclaw/downloads/submit
不要从此技能直接调用:
- - POST /api/settings/webdav/addofflinedownload
5. 提交后继续
- 1. POST /api/openclaw/downloads/:downloadId/confirm-landed
- POST /api/openclaw/media/:metadataId/finalize-import
- GET /api/openclaw/downloads/:downloadId
不要手动组合:
- - GET /api/scrape/webdav/list
- POST /api/scrape/webdav/scan
- POST /api/scrape/match
作为默认路径
端点可用性检查
在依赖某个路径之前,请明确区分以下失败情况:
- - 404:此服务器版本上端点不可用
- 403:缺少 OpenClaw 权限
- 400:缺少必需参数或参数无效
规则:
- - 如果 catalog、state、download-target、download-check、downloads/submit、confirm-landed 或 finalize-import 返回 404,说明该服务器未暴露该 OpenClaw 端点
- 如果 GET /api/openclaw/downloads/:downloadId 返回 404,报告 未找到下载工作流;不要将其描述为路由缺失
- 如果其中一个返回 403,报告确切缺失的权限并停止
- 不要将旧版回退描述为等效
- 如果 POST /api/openclaw/libraries/scan 返回 partial: true,显式报告失败的媒体库根路径
严格回退规则
仅允许在以下情况下回退。
允许的回退
仅当用户明确询问原始媒体库配置字段(如 path、scraper、sourceMode 或 sourcePreferencesJson)时使用
仅当用户明确询问原始刮削候选项时使用
- - GET /api/scrape/webdav/list
仅当用户明确询问 OpenClaw 端点未返回的目录级文件枚举详情时使用
- - POST /api/openclaw/libraries/scan
仅当用户明确想要扫描,或 finalize-import 不可用且用户仍希望尽力刷新时使用
不允许的回退
- - 不要回退到 GET /api/metadata 进行媒体库列表
- 不要回退到 GET /api/metadata 进行缺失剧集检测
- 不要回退到 GET /api/metadata/stats 进行媒体浏览
- 不要回退到 POST /api/settings/webdav/addofflinedownload 进行常规下载提交
- 不要回退到 GET /api/settings/webdav/search 进行常规落地文件检查
禁止使用的端点
不要使用:
- - /api/openclaw/bootstrap/status
- /api/openclaw/connect/context
- /api/openclaw/jobs/
- /api/openclaw/sites/
- /api/openclaw/tasks/*
- OPENCLAW_URL 远程委托流程
响应规则
仅保持响应的功能性。
始终声明:
- - 认证方式
- 端点
- 所需权限
- 载荷结构
- 返回结果或阻塞原因
除非需要解释阻塞原因,否则不要添加产品评论或发现侧的解释。
示例
查看动漫条目
用户请求:
把 Anime 里的媒体条目发给我看看
执行:
- 1. GET /api/openclaw/libraries/catalog?libraryName=Anime
检查剧集
用户请求:
芙莉莲现在有哪些集,缺哪些集
执行:
- 1. 从 catalog 查找 metadataId
- GET /api/openclaw/media/:metadataId/state
提交磁力链接
用户请求:
这个 magnet 下载到对应番剧目录
执行:
- 1. GET /api/openclaw/media/:metadataId/download-target
- POST /api/openclaw/media/:metadataId/download-check
- POST /api/openclaw/downloads/submit 附带 metadataId 和 magnet 或 urls
下载后继续
用户请求:
下载完成后继续