# Startpage Video Scraper (`searchapi/startpage-video-scraper`) Actor

Scrapes Startpage Videos for any query. Extracts the full canonical video-vertical schema: title, URL, platform, channel, duration, views, likes, dates, thumbnail, dimensions, language, region, category, tags, anonymous-view URL, and more.

- **URL**: https://apify.com/searchapi/startpage-video-scraper.md
- **Developed by:** [Search API](https://apify.com/searchapi) (community)
- **Categories:** Videos, Developer tools, Other
- **Stats:** 2 total users, 1 monthly users, 96.7% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.99 / 1,000 search results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Startpage Video Scraper

Collect dedicated Startpage Video results as rich, normalized records. The Actor supports one search or a fair batch of up to 20 searches, native session-preserving pagination, duration/view/date/channel/domain filters, Safe Search, sorting, and bounded browser controls.

Startpage's embedded `video-*` structured groups are the primary source. Validated first-party JSON responses and a semantic DOM fallback are retained for compatible page changes. Ads, ordinary web results, challenge pages, signed proxy links, and raw responses are never stored.

### Example input

```json
{
  "queries": ["machine learning tutorial", "javascript tutorial"],
  "maxItems": 50,
  "maxPages": 5,
  "sortBy": "views",
  "durationFilter": "medium",
  "minViews": 1000,
  "requireThumbnail": true,
  "safeSearch": "moderate",
  "language": "english",
  "maxConcurrency": 3,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": ["RESIDENTIAL"],
    "apifyProxyCountry": "US"
  }
}
```

`durationFilter` supports `any`, `short` (under 4 minutes), `medium` (4–20 minutes), and `long` (over 20 minutes). Output sorting supports Startpage relevance, newest, most viewed, shortest, and longest. Optional `publishedAfter` and `publishedBefore` values use `YYYY-MM-DD`.

Use `includeDomains`, `excludeDomains`, `includeChannels`, and `excludeChannels` for source filters. `region` is an explicit output provenance label; select a proxy country for network geolocation.

`GOOGLE_SERP` is intentionally unsupported because it is an HTTP proxy for supported Google Search/Shopping requests, while this Actor visits Startpage through an HTTPS Firefox session. Use Apify Residential or custom proxies when direct access is unreliable.

### Output

The 34-field contract can include stable and platform video IDs, positions/pages, title, canonical and embed URLs, domain, platform, channel, description, text and numeric duration, text and numeric views, ISO and source publication dates, direct thumbnail, source/extraction provenance, matched queries, requested filters, locale, and scrape time.

Unavailable optional descriptions or channel labels are omitted. The Actor never emits `null`, blank strings, empty arrays, fabricated fields, or signed anonymous-view URLs.

### Reliability

Startpage Video pagination uses a page-generated POST form containing session state and a page token. The Actor validates and submits that native form instead of reconstructing fragile `page=` URLs. All requested pages and queries are buffered, normalized, filtered, deduplicated, fairly selected, and written atomically. A failed later page cannot leave a misleading partial-success dataset.

Sessions, persistent cookies, coherent Crawlee Firefox fingerprints, bounded retries, memory-aware concurrency, and optional Residential/custom proxies improve ordinary compatibility. CAPTCHA pages are detected and rejected; the Actor does not solve or bypass CAPTCHAs.

### Local development

```bash
npm ci
npx playwright install firefox
npm test
apify run --purge --input-file qa-inputs/local-pagination.json
node validate-datasets.js
```

The QA fixtures cover single, fair batch, native pagination, filtered/sorted, clean-empty, low-concurrency, invalid-input, incompatible-proxy, and cloud Residential cases.

# Actor input Schema

## `query` (type: `string`):

One phrase to enter in Startpage Videos.

## `queries` (type: `array`):

Up to 20 searches with fair output allocation.

## `maxItems` (type: `integer`):

Overall output limit across all searches.

## `maxPages` (type: `integer`):

Maximum native video pages inspected per search.

## `sortBy` (type: `string`):

Order each query bucket before fair selection.

## `durationFilter` (type: `string`):

Any, under 4 minutes, 4–20 minutes, or over 20 minutes.

## `minViews` (type: `integer`):

Keep videos with at least this many parsed views.

## `publishedAfter` (type: `string`):

Optional inclusive YYYY-MM-DD publication filter.

## `publishedBefore` (type: `string`):

Optional inclusive YYYY-MM-DD publication filter.

## `includeDomains` (type: `array`):

Optional video-domain allowlist.

## `excludeDomains` (type: `array`):

Optional video-domain blocklist.

## `includeChannels` (type: `array`):

Keep channel names containing one of these values.

## `excludeChannels` (type: `array`):

Remove channel names containing one of these values.

## `requireThumbnail` (type: `boolean`):

Keep only videos with a source-provided direct thumbnail.

## `safeSearch` (type: `string`):

Startpage Safe Search level.

## `language` (type: `string`):

Startpage language value such as english or deutsch.

## `region` (type: `string`):

Optional country provenance label; proxy country controls network geolocation.

## `maxConcurrency` (type: `integer`):

Maximum searches processed in parallel, memory-capped.

## `maxRequestRetries` (type: `integer`):

Bounded retries for temporary failures.

## `navigationTimeoutSecs` (type: `integer`):

Maximum seconds per browser navigation.

## `requestHandlerTimeoutSecs` (type: `integer`):

Maximum seconds for one query including pagination.

## `proxyConfiguration` (type: `object`):

Optional Residential or custom proxy. GOOGLE\_SERP is incompatible with Startpage HTTPS.

## `debug` (type: `boolean`):

Log field names and counts only, never raw bodies.

## Actor input object example

```json
{
  "query": "machine learning tutorial",
  "queries": [],
  "maxItems": 50,
  "maxPages": 5,
  "sortBy": "relevance",
  "durationFilter": "any",
  "minViews": 0,
  "includeDomains": [],
  "excludeDomains": [],
  "includeChannels": [],
  "excludeChannels": [],
  "requireThumbnail": false,
  "safeSearch": "moderate",
  "language": "english",
  "region": "",
  "maxConcurrency": 3,
  "maxRequestRetries": 2,
  "navigationTimeoutSecs": 45,
  "requestHandlerTimeoutSecs": 180,
  "debug": false
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "query": "machine learning tutorial"
};

// Run the Actor and wait for it to finish
const run = await client.actor("searchapi/startpage-video-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "query": "machine learning tutorial" }

# Run the Actor and wait for it to finish
run = client.actor("searchapi/startpage-video-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "query": "machine learning tutorial"
}' |
apify call searchapi/startpage-video-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,searchapi/startpage-video-scraper"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/GkrGGuiQkt0rWwb7N/builds/9t0Z8uyxezgpu9t2r/openapi.json
