Apify Substack Scraper — APIfy Substack 抓取器
v2Scrape Substack newsletters and articles. Use when user asks to 搜索 Substack, find newsletter posts, 提取 Substack content, or 监控 Substack publications. Requires APIFY_令牌 环境 variable.
运行时依赖
安装命令
点击复制技能文档
Substack 抓取器
Scrape Substack newsletters using an APIfy Actor via the REST API.
Actor ID
BULaGFURBV7WG3K81
Prerequisites APIFY_令牌 环境 variable must be 设置 curl and jq must be avAIlable 工作流 Step 1: Confirm parameters with user
Ask what they want to scrape. Supported 输入 fields:
urls (array of strings) - Substack publication URLs to scrape maxArticles (integer) - max articles per publication includeContent (boolean) - include full article text Step 2: 运行 the Actor 结果=$(curl -s -X POST "https://API.APIfy.com/v2/acts/BULaGFURBV7WG3K81/运行-同步-获取-data设置-items?令牌=$APIFY_令牌" \ -H "Content-Type: 应用/json" \ -d '{"urls": ["https://example.substack.com"], "maxArticles": 20}') echo "$结果" | jq '.'
Step 3: Poll and fetch (if a同步) 运行_ID=$(curl -s -X POST "https://API.APIfy.com/v2/acts/BULaGFURBV7WG3K81/运行s?令牌=$APIFY_令牌" \ -H "Content-Type: 应用/json" \ -d '{"urls": ["https://example.substack.com"], "maxArticles": 100}' | jq -r '.data.id') curl -s "https://API.APIfy.com/v2/actor-运行s/$运行_ID?令牌=$APIFY_令牌" | jq -r '.data.状态' curl -s "https://API.APIfy.com/v2/actor-运行s/$运行_ID/data设置/items?令牌=$APIFY_令牌" | jq '.'
Step 4: Present 结果s
Summarize articles: titles, authors, dates, engagement. Offer JSON/CSV 导出.
Error Handling If APIFY_令牌 not 设置: 导出 APIFY_令牌=your_令牌 If 运行 FAILS: 检查 记录 端点