When to Use
- On-demand page content extraction: A form submission includes a URL that needs to be scraped for metadata (title, OG tags, description) without building a full crawler configuration — use
scrapeSingleUrl with cheerio for immediate results.
- JavaScript-rendered SPA pages: When a URL loads content dynamically via JavaScript frameworks (React, Vue, Angular), use
playwright crawler type to get fully-rendered HTML after all scripts execute.
- Link preview generation: Generate rich link previews in a content management workflow by scraping submitted URLs for title, image, and description metadata using fast
cheerio parsing.
- Availability monitoring: Periodically scrape a specific URL and compare the scraped content against a baseline snapshot to detect page changes, pricing updates, or content modifications.
- Rapid prototyping: During workflow development, use
scrapeSingleUrl to quickly test whether a URL is scrapable and what data structure the actor returns before investing in a full actor configuration.
Crawler type choice: cheerio uses a fast, lightweight HTML parser (like jQuery for Node.js). It does not execute JavaScript, making it ideal for static HTML pages and very fast (typically under 5 seconds). playwright launches a full Chromium browser, executes JavaScript, and waits for the DOM to settle — use it when the target URL loads content via API calls or client-side rendering. Playwright runs are slower (15–60 seconds) and cost more compute.
Configuration
Connection
| Field | Required | Description |
credentialId | Required | BizFirstAI credential ID holding the Apify API token. |
baseUrl | Optional | Apify API base URL. Defaults to https://api.apify.com. |
Operation
| Field (config key) | Required | Description |
resource | Required | Must be "actor". |
operation | Required | Must be "scrape-single-url". |
url | Required | The URL to scrape. Must be an absolute URL including protocol (e.g. https://example.com/page). Supports BizFirst expressions. |
crawlerType | Optional | The scraping engine to use. Accepted values: "cheerio" (default, fast HTML parsing, no JS execution) or "playwright" (full browser, executes JavaScript, handles SPAs). Defaults to "cheerio" if omitted or invalid. |
Sample Configuration
{
"resource": "actor",
"operation": "scrape-single-url",
"credentialId": "apify-prod-token",
"url": "https://techcrunch.com/2026/05/26/ai-startup-raises-funding/",
"crawlerType": "cheerio"
}
Validation Errors
| Error | Cause |
API token is required | credentialId / apiToken is missing or empty. |
URL is required | url is missing or empty. |
Invalid settings for actor/scrape-single-url | Internal type mismatch. Verify resource is "actor" and operation is "scrape-single-url". |
APIFY_ERROR (error port) | The URL is unreachable, returns a non-200 status, the Apify scraper actor fails, or the API token lacks permission. |
Output
Success Port
| Field | Type | Description |
url | string | The URL that was scraped, echoed from the input configuration. |
crawlerType | string | The crawler type used: "cheerio" or "playwright". |
runId | string | The Apify run ID. Use this with dataset/getItems (after fetching the run's defaultDatasetId via actor-run/get) to retrieve the scraped page content. |
Error Port
Routes here when the URL is invalid, the target page is unreachable (404, 403, timeout), the Apify scraper actor fails internally, or authentication fails. Output contains errorCode ("APIFY_ERROR") and message.
Retrieving scraped content: This operation returns a runId but not the scraped HTML or structured data directly. To read the scraped content, use actor-run/get with the runId to obtain the defaultDatasetId, then call dataset/getItems. For a fully self-contained scrape, prefer actor/runAndGetDatasetItems with a configured scraper actor instead.
Sample Output
{
"url": "https://techcrunch.com/2026/05/26/ai-startup-raises-funding/",
"crawlerType": "cheerio",
"runId": "run_s1c2r3a4p5e6"
}
Expression Reference
| Expression | Returns |
{{ $output.apify.runId }} | Run ID to pass to actor-run/get for status + dataset ID. |
{{ $output.apify.url }} | The scraped URL, echoed for use in downstream logging or display. |
{{ $output.apify.crawlerType }} | Crawler type used, for audit or conditional branching. |
Node Policies & GuardRails
| Policy | Recommendation | Severity |
| API token storage | Use credentialId; never embed raw tokens. | Critical |
| URL validation | Validate the url value is a well-formed absolute URL before it reaches this node. Malformed URLs cause Apify actor errors routed to the error port. | High |
| Crawler type selection | Default to cheerio for all static sites. Only escalate to playwright when you have confirmed the page requires JavaScript rendering — Playwright runs are 4–10x more expensive in compute units. | High |
| Downstream data retrieval | Always add a subsequent actor-run/get + dataset/getItems step to actually read the scraped content. The output of this node alone does not contain the page data. | High |
| Error handling for blocked pages | Many sites block scrapers (403 responses, CAPTCHAs). Handle the error port and implement retry logic or fallback to alternative data sources for mission-critical workflows. | Medium |
| Rate limiting | Avoid scraping the same domain at high frequency. Most sites enforce rate limiting; spread URL scraping across time or use Apify proxy configuration to avoid IP bans. | Medium |
Examples
News Article Metadata Extraction — Cheerio
{
"resource": "actor",
"operation": "scrape-single-url",
"credentialId": "apify-prod-token",
"url": "{{ $input.articleUrl }}",
"crawlerType": "cheerio"
}
Triggered when a user submits an article URL in a content curation form. The fast Cheerio parser extracts the page's HTML in under 5 seconds. The runId is stored in a variable; a subsequent actor-run/get node waits for SUCCEEDED status, then dataset/getItems retrieves the parsed content for display.
JavaScript SPA Scraping — Playwright
{
"resource": "actor",
"operation": "scrape-single-url",
"credentialId": "apify-playwright-token",
"url": "https://app.dashboard.example.com/public-stats",
"crawlerType": "playwright"
}
Scrapes a React-based public dashboard that loads data via client-side API calls. Playwright launches Chromium, waits for network idle, and captures the fully-rendered DOM. Use for pages that return empty or skeleton HTML without JavaScript execution.
Batch URL Scraping via Loop
{
"resource": "actor",
"operation": "scrape-single-url",
"credentialId": "apify-prod-token",
"url": "{{ $output.urlLoop.currentUrl }}",
"crawlerType": "cheerio"
}
Inside a Loop node iterating over an array of competitor product URLs. Each iteration fires a scrape job and collects the runId into an array variable. After the loop, a parallel batch of actor-run/get calls retrieves dataset IDs, and each dataset is fetched for price comparison analysis.