# Sora AI Video Scraper - OpenAI Text-to-Video (`payai/sora-video-scraper`) Actor

Extract AI-generated videos from Sora by OpenAI. Collect video URLs, thumbnails, prompts, and metadata. Perfect for AI researchers and content creators.

- **URL**: https://apify.com/payai/sora-video-scraper.md
- **Developed by:** [PayAI](https://apify.com/payai) (community)
- **Categories:** Travel
- **Features:** Full permissions
- **Stats:** 242 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: 1.00 out of 5 stars

## Pricing

$20.00 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Sora AI Video Scraper - OpenAI Video Generator

🎬 **Extract AI-generated videos from Sora by OpenAI!** This powerful Apify actor collects videos, thumbnails, prompts, and metadata from OpenAI's revolutionary text-to-video AI model.

### 🚀 Key Features

#### What Gets Extracted

- 🎥 **Video URLs**: Direct links to AI-generated videos
- 🖼️ **Thumbnails**: Preview images for each video
- 📝 **Prompts**: The text prompts used to generate videos
- ⏱️ **Duration**: Video length information
- 📊 **Metadata**: Views, likes, resolution, creator info
- 🏷️ **Categories**: Video types and classifications
- 📅 **Timestamps**: Creation and scraping dates

#### Technical Features

- ⚡ **Fast Extraction**: Optimized Playwright crawler
- 📜 **Infinite Scroll**: Automatically loads more content
- 🔄 **Smart Retry**: Handles network issues gracefully
- 💾 **Multiple Formats**: Export as JSON, CSV, or Excel
- 🔌 **API Ready**: Direct integration with your apps
- 🛡️ **Reliable**: Built-in error handling and recovery

### 📋 Complete Data Schema

| Field | Type | Description | Example |
|-------|------|-------------|---------|
| `title` | String | Video title | "Aerial drone footage of Big Sur coastline" |
| `videoUrl` | String | Direct video URL | "https://..." |
| `thumbnailUrl` | String | Thumbnail image | "https://..." |
| `prompt` | String | Generation prompt | "A stylish woman walks down a Tokyo street..." |
| `duration` | String | Video duration | "0:30" |
| `resolution` | String | Video resolution | "1920x1080" |
| `category` | String | Video category | "Nature" |
| `creator` | String | Creator name | "Sora AI" |
| `views` | Number | View count | 15420 |
| `likes` | Number | Like count | 342 |
| `createdAt` | String | Creation date | "2025-08-20T10:30:00Z" |
| `source` | String | Data source | "Sora by OpenAI" |
| `pageUrl` | String | Source page | "https://sora.chatgpt.com/explore/videos" |
| `scrapedAt` | String | Extraction time | "2025-08-21T03:00:00Z" |

### 💡 Use Cases

#### For AI Researchers

- 📚 **Dataset Creation**: Build training datasets for video AI
- 🔬 **Prompt Analysis**: Study effective prompt engineering
- 📈 **Trend Analysis**: Track AI video generation trends
- 🎯 **Quality Assessment**: Evaluate AI video capabilities

#### For Content Creators

- 🎨 **Inspiration Gallery**: Discover creative prompts
- 🎬 **Video References**: Find AI video examples
- 💡 **Idea Generation**: Explore different styles
- 📱 **Social Media Content**: Source unique videos

#### For Developers

- 🔧 **API Integration**: Build apps with AI videos
- 🗄️ **Database Population**: Fill video databases
- 🤖 **Bot Creation**: Automated video collection
- 📊 **Analytics Tools**: Video performance tracking

### 🚀 Quick Start

#### Option 1: Run on Apify Platform

1. Go to the [Actor page](https://apify.com/store)
2. Click "Try for free"
3. Configure your parameters
4. Click "Start" to run

#### Option 2: API Integration

```javascript
const response = await fetch('https://api.apify.com/v2/acts/YOUR_USERNAME~sora-video-scraper/runs', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': 'Bearer YOUR_API_TOKEN'
  },
  body: JSON.stringify({
    maxVideos: 50,
    includePrompts: true,
    includeMetadata: true,
    sortBy: 'newest'
  })
});
```

#### Option 3: Node.js SDK

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

const client = new ApifyClient({ token: 'YOUR_API_TOKEN' });
const run = await client.actor('YOUR_USERNAME/sora-video-scraper').call({
  maxVideos: 50,
  includePrompts: true
});

const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);
```

### ⚙️ Input Parameters

```json
{
  "maxVideos": 50,
  "includePrompts": true,
  "includeMetadata": true,
  "downloadVideos": false,
  "categories": ["all"],
  "sortBy": "newest",
  "debug": false
}
```

#### Parameters Explained

- **maxVideos** (1-500): Number of videos to extract
- **includePrompts**: Extract generation prompts
- **includeMetadata**: Include views, likes, duration
- **downloadVideos**: Download actual video files
- **categories**: Filter by video type
- **sortBy**: Order results (newest/oldest/popular)
- **debug**: Enable detailed logging

### 📊 Output Example

```json
{
  "title": "Aerial drone footage of Big Sur coastline",
  "videoUrl": "https://sora-video.openai.com/video-12345.mp4",
  "thumbnailUrl": "https://sora-video.openai.com/thumb-12345.jpg",
  "prompt": "Aerial drone shot of dramatic cliffs along Big Sur coastline at sunset, waves crashing against rocks, cinematic style",
  "duration": "0:30",
  "resolution": "1920x1080",
  "category": "Nature",
  "creator": "Sora AI",
  "views": 15420,
  "likes": 342,
  "createdAt": "2025-08-19T14:30:00.000Z",
  "source": "Sora by OpenAI",
  "pageUrl": "https://sora.chatgpt.com/explore/videos",
  "scrapedAt": "2025-08-21T03:00:00.000Z"
}
```

### 🔌 Integration Examples

#### Save to Database

```javascript
// MongoDB Example
const videos = await getScraperResults();
await db.collection('sora_videos').insertMany(videos);

// PostgreSQL Example
for (const video of videos) {
  await db.query(
    'INSERT INTO sora_videos (title, video_url, prompt) VALUES ($1, $2, $3)',
    [video.title, video.videoUrl, video.prompt]
  );
}
```

#### Webhook Integration

```javascript
{
  "webhook": {
    "url": "https://your-api.com/webhook",
    "method": "POST",
    "headers": {
      "Authorization": "Bearer YOUR_TOKEN"
    }
  }
}
```

### 📈 Performance

| Metric | Value |
|--------|-------|
| Average runtime | 30-60 seconds |
| Videos per minute | ~20-50 |
| Memory usage | 256-512 MB |
| Success rate | 95%+ |
| Max videos per run | 500 |

### 💰 Pricing

- **Free Tier**: $5 credits (~100 videos)
- **Paid Usage**: ~$0.10 per 100 videos
- **Subscription**: From $49/month unlimited

### 🛡️ Reliability Features

- ✅ Automatic retry on failures
- ✅ Multiple fallback selectors
- ✅ Graceful error handling
- ✅ Request timeout protection
- ✅ Memory optimization
- ✅ Rate limit compliance

### 🤝 Support

- 📧 **Email**: support@apify.com
- 💬 **Discord**: [Join Community](https://discord.com/invite/apify)
- 📚 **Docs**: [docs.apify.com](https://docs.apify.com)
- 🐛 **Issues**: Report on GitHub

### 📝 Legal & Ethics

This scraper is designed for:

- Research and educational purposes
- Content discovery and inspiration
- Building AI video databases
- Analyzing AI capabilities

Please respect:

- OpenAI's terms of service
- Content attribution requirements
- Fair use guidelines
- Rate limiting best practices

### 🔄 Updates

#### Version 1.0 (Current)

- Initial release
- Basic video extraction
- Prompt collection
- Metadata extraction

#### Roadmap

- \[ ] Video download support
- \[ ] Advanced filtering
- \[ ] Batch processing
- \[ ] Real-time monitoring
- \[ ] API webhooks

### ⭐ Reviews

If this actor helps you, please:

1. ⭐ Star on Apify Store
2. 📝 Leave a review
3. 🔗 Share with others
4. 💡 Suggest features

### 📄 License

MIT License - Free for any use

***

**Built with ❤️ for the AI community**

*Disclaimer: This is an unofficial scraper. Sora and OpenAI are trademarks of OpenAI, Inc.*

# Actor input Schema

## `maxVideos` (type: `integer`):

Maximum number of AI videos to extract

## `includePrompts` (type: `boolean`):

Extract the text prompts used to generate each video

## `includeMetadata` (type: `boolean`):

Extract additional metadata like views, likes, duration, resolution

## `downloadVideos` (type: `boolean`):

Download actual video files (increases runtime and storage)

## `category` (type: `string`):

Filter by video category

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

How to sort the extracted videos

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

Enable verbose logging for troubleshooting

## Actor input object example

```json
{
  "maxVideos": 50,
  "includePrompts": true,
  "includeMetadata": true,
  "downloadVideos": false,
  "category": "all",
  "sortBy": "newest",
  "debug": false
}
```

# 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 = {
    "maxVideos": 50,
    "category": "all"
};

// Run the Actor and wait for it to finish
const run = await client.actor("payai/sora-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 = {
    "maxVideos": 50,
    "category": "all",
}

# Run the Actor and wait for it to finish
run = client.actor("payai/sora-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 '{
  "maxVideos": 50,
  "category": "all"
}' |
apify call payai/sora-video-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,payai/sora-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/OL626sNKMJGiKgOcp/builds/VUtNjKvrBaD5DdmGt/openapi.json
