CrawlForge
监控高级3 credits

track_changes

通过基线捕获、智能对比以及带 webhook 告警的定时监控来追踪网页内容变更。非常适合监控竞争对手、法律政策和突发新闻。

使用场景

监控竞争对手的定价页面

当竞争对手调整价格、功能或产品方案时即时获得告警

追踪法律/政策文档变更

监控服务条款、隐私政策或合规性文档

监视新闻网站的更新

实时检测特定页面上的突发新闻或文章更新

检测网站宕机或页面被篡改

当出现重大结构性变化(表明发生错误或攻击)时获得告警

监控 API 文档的破坏性变更

追踪 API 参考页面,及早发现弃用和破坏性变更

Endpoint

POST/api/v1/tools/track_changes
Auth Required
2 req/s on Free plan
3 credits

Parameters

NameTypeRequiredDefaultDescription
url
stringRequired-
要监控变更的 URL
Example: https://competitor.com/pricing
operation
stringOptionalcompare
操作类型:"create_baseline" | "compare" | "monitor" | "get_history" | "get_stats"
Example: compare
trackingOptions
objectOptional-
用于设置追踪内容及方式的选项
Example: {"granularity": "high", "ignoreWhitespace": true}
monitoringOptions
objectOptional-
用于定时监控的选项
Example: {"enabled": true, "interval": "1h"}
storageOptions
objectOptional-
用于变更历史存储的选项
Example: {"retainHistory": true, "maxHistoryEntries": 100}

操作指南

适用于各种监控工作流的不同操作

create_baseline
捕获网页的初始状态。必须在对比之前首先运行。创建包含内容哈希、文本长度、链接数量和结构的快照。
compare
将当前网页状态与基线进行对比。返回变更分数、重要程度以及所有检测到的变更(文本、链接、结构)的详细列表。
monitor
启用/禁用带 webhook 通知的定时监控。按指定间隔自动检查变更,并在达到阈值时发送告警。
get_history
检索某个 URL 的变更历史。返回包含时间戳、变更分数和摘要的所有检测到的变更数组。
get_stats
获取监控统计信息,包括总检查次数、平均变更分数、上次检查时间和变更频率趋势。

Webhook 通知格式

当检测到的变更超过阈值时,会向您的 webhook 发送此载荷

webhook-payload.jsonJson
您的 webhook 端点必须在 10 秒内返回 200 OK。失败的 webhook 会以指数退避方式最多重试 3 次。

请求示例

terminalBash

响应示例

200 OK2,340ms
{
"success": true,
"data": {
"comparison": {
"changeScore": 0.35,
"significance": "medium",
"changes": [
{
"type": "text",
"description": "Pricing changed from $99/mo to $79/mo",
"location": "div.pricing-card > span.price",
"oldValue": "$99",
"newValue": "$79",
"impact": "high"
},
{
"type": "link",
"description": "New \"Enterprise\" link added",
"location": "nav.pricing-tiers",
"action": "added",
"url": "/pricing/enterprise",
"impact": "medium"
},
{
"type": "structure",
"description": "New section added: \"Compare Plans\"",
"location": "main > section:nth-child(3)",
"action": "added",
"impact": "low"
}
],
"summary": "3 changes detected: 1 high impact, 1 medium impact, 1 low impact",
"timestamp": "2025-10-15T14:30:00Z"
},
"baseline": {
"url": "https://competitor.com/pricing",
"captured_at": "2025-10-15T12:00:00Z",
"hash": "a1b2c3d4e5f6",
"metrics": {
"textLength": 4567,
"linkCount": 23,
"elementCount": 145
}
},
"history": {
"totalChecks": 48,
"changesDetected": 5,
"lastCheck": "2025-10-15T14:30:00Z",
"nextCheck": "2025-10-15T15:30:00Z"
}
},
"credits_used": 3,
"credits_remaining": 997,
"processing_time": 2340
}
Field Descriptions
data.comparison.changeScore整体变更分数(0-1,其中 1 表示完全不同)
data.comparison.significance根据 changeScore 划分为 low、medium 或 high
data.comparison.changes检测到的变更数组及其详情
data.baseline.hash用于对比的基线内容的唯一哈希值
data.history.nextCheck下次计划检查(如果已启用监控)
credits_used每次操作固定消耗 3 credits(基线、对比、监控等)
processing_time对比操作通常耗时 2-4 秒

错误处理

未找到基线(400 Bad Request)

必须先运行 create_baseline 操作再进行对比。每个 URL 都需要各自的基线。

无效的监控间隔(400 Bad Request)

间隔必须为以下之一:15m、30m、1h、6h、24h。更短的间隔需要更高级别的套餐。

URL 无法访问(400 Bad Request)

目标 URL 返回错误或被屏蔽。请检查 URL 的可访问性和身份验证。

Webhook 失败(500 Internal Server Error)

Webhook URL 返回错误或超时。请确保端点可访问并返回 200 OK。

专业提示: 对定价或法律文档等关键页面使用 high 粒度。对频繁发生细微更新的页面使用 medium/low 粒度,以减少误报。

Credit 费用

3 credits
每次操作 3 credits
每次操作(create_baseline、compare、monitor、get_history、get_stats)消耗 3 credits。定时监控检查按每次执行计费。

费用明细:

create_baseline:3 credits(每个 URL 一次性)

compare:每次检查 3 credits

monitor(设置):3 credits(一次性)

定时检查:每次执行 3 credits

get_history:每次检索 3 credits

get_stats:每次检索 3 credits

监控费用示例:

1 小时监控间隔: 24 次检查/天 × 3 credits = 72 credits/天/URL

6 小时监控间隔: 4 次检查/天 × 3 credits = 12 credits/天/URL

24 小时监控间隔: 1 次检查/天 × 3 credits = 3 credits/天/URL

套餐推荐:

Free 套餐: 1,000 个一次性试用 credits = 以 6h 间隔监控 5 个 URL 一个月

Hobby 套餐: 5,000 credits = 以 6h 间隔监控 25 个 URL($19/mo)

Professional 套餐: 50,000 credits = 以 6h 间隔监控 250 个 URL($99/mo)

相关工具

fetch_url
用于对比的基础 URL 抓取(1 credit)
extract_content
提取主要内容以进行聚焦监控(2 credits)
stealth_mode
在不被检测的情况下监控受保护页面(5 credits)
batch_scrape
并行监控多个 URL(每个 URL 1 credit)
准备好试用 track_changes 了吗?免费注册,获取 1,000 credits,开始监控您的第一批页面。