# PornTrex Downloader (`maximedupre/porntrex-downloader`) Actor

Download public PornTrex video data from watch-page URLs. Get direct MP4 links, quality variants, titles, durations, thumbnails, and source URLs.

- **URL**: https://apify.com/maximedupre/porntrex-downloader.md
- **Developed by:** [Maxime Dupré](https://apify.com/maximedupre) (community)
- **Categories:** Social media, Developer tools, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$2.65 / 1,000 resolved videos

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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

### 📥 PornTrex downloader for public video URLs

PornTrex Downloader extracts direct media links and source metadata from public [PornTrex](https://www.porntrex.com/) watch-page URLs. Paste one or more PornTrex video links and get a clean Apify dataset with source URLs, video IDs, titles, durations, thumbnails, and all source-exposed MP4 or HLS media variants.

Use this PornTrex downloader when you already have public video URLs and need repeatable exports for content review, cataloging, research, media operations, archiving workflows, or an API pipeline. The Actor works with public, reachable PornTrex video pages only. You do not need PornTrex cookies, a PornTrex account, a browser extension, local playback, or a source API key.

For a small first run, keep the prefilled sample URL and start the Actor. Once the output shape fits your workflow, paste your own list of public PornTrex watch-page URLs, run a larger batch, schedule the Actor, or call it through the Apify API.

### ✅ What this Actor does

- Accepts public PornTrex watch-page URLs.
- Saves one dataset row per successfully resolved public video.
- Returns direct source-hosted MP4 links when PornTrex exposes them.
- Keeps all detected media variants in `mediaVariants`, including source quality labels and dimensions when available.
- Adds video ID, source URL, title, duration, and thumbnail URL when the source page exposes them.
- Parses signed media URL expiry timestamps when they are present.
- Skips invalid, unsupported, private, removed, blocked, account-only, or no-media targets without saving failure rows.

This Actor is focused on known public PornTrex videos. It does not search PornTrex, crawl categories, unlock private content, download files into Apify storage, create ZIP archives, transcode media, or install a browser extension.

### 📦 Data you can export

Each output row represents one public PornTrex video where at least one source-hosted media link was found. Core fields include:

- `videoId` - PornTrex video identifier, when available.
- `sourceUrl` - source-confirmed PornTrex watch URL.
- `title` - source video title, when available.
- `durationSeconds` - video duration in seconds, when available.
- `thumbnailUrl` - source thumbnail or poster image URL, when available.
- `mediaVariants` - direct media links with `quality`, `width`, `height`, `contentType`, `mediaUrl`, and `expiresAt`.

Direct media links can be signed and time-limited. Use `mediaVariants[].expiresAt` to decide when to refresh results. The Actor does not invent missing dimensions, titles, or durations; nullable fields stay empty when PornTrex does not expose that value.

You can open the dataset in Apify, export it as JSON, CSV, Excel, XML, RSS, or HTML, call it through the Apify API, schedule recurring runs, or connect results to webhooks and integrations.

### 🚀 How to run

1. Add one or more public PornTrex video URLs in **PornTrex video URLs**.
2. Start the Actor.
3. Open the dataset when the run finishes.
4. Use `mediaVariants[].mediaUrl` for the direct source-hosted media links.

For batch runs, add one URL per row. Duplicate URLs are processed once per normalized source URL.

### 🔎 Input

The public input has one field:

- **PornTrex video URLs** - a list of public PornTrex watch-page URLs, such as `https://www.porntrex.com/video/3241716/alexya-makes-the-world-a-beautiful-place`.

The Actor does not expose proxy, browser, retry, quality, cookie, account, storage, ZIP, or download-file settings. Those are not needed for the approved public-video workflow.

### 📤 Output example

```json
{
	"videoId": "123456",
	"sourceUrl": "https://www.porntrex.com/video/123456/example-video",
	"title": "Example video title",
	"durationSeconds": 742,
	"thumbnailUrl": "https://cdn.porntrex.example/thumbs/123456.jpg",
	"mediaVariants": [
		{
			"quality": "720p",
			"width": 1280,
			"height": 720,
			"contentType": "video/mp4",
			"mediaUrl": "https://cdn.porntrex.example/videos/123456-720p.mp4",
			"expiresAt": null
		}
	]
}
````

Rows are success-only. If a submitted URL cannot be resolved into at least one direct source-hosted media link, the Actor logs the outcome and does not create a placeholder row.

### 💳 Pricing

This Actor charges one `Resolved video` event for each public PornTrex video that is successfully saved to the dataset. Invalid URLs, unsupported pages, blocked pages, private videos, no-media targets, and empty outputs are not charged as resolved videos.

### ⚠️ Limits and caveats

- The Actor returns fresh source-hosted media URLs; it does not store PornTrex videos in Apify storage.
- Some media URLs may expire. Rerun the Actor to refresh them.
- Public source pages can expose different metadata by video, region, or run time.
- Use the Actor only for public videos you are authorized to access and process.

### ❓ FAQ

#### 🔐 Do I need a PornTrex account or cookies?

No. The Actor is built for public PornTrex watch pages and does not ask for PornTrex credentials, cookies, local browser state, or extension data.

#### 📁 Does this Actor download MP4 files into Apify storage?

No. It returns direct source-hosted media links in the dataset. It does not mirror, transcode, zip, or rehost video files.

#### 🎚️ Can I choose a preferred quality?

The Actor returns all source-exposed variants it can validate, including quality labels such as `480p`, `720p`, or `1080p` when PornTrex exposes them. Choose the variant you want from the dataset.

#### 🔎 Why did a URL produce no row?

The Actor saves rows only when it finds at least one direct source-hosted media link. Removed, private, account-only, blocked, unsupported, or no-media pages are reported in logs instead of being saved as failed rows.

### 📝 Changelog

- 0.1: Initial release.

### 🆘 Support

For issues, questions, or feature requests, [file a ticket](https://console.apify.com/actors/maximedupre~porntrex-downloader/issues) and I'll fix or implement it in less than 24h 🫡

### 🔗 Other actors

- [XVideos Downloader ↗](https://apify.com/maximedupre/xvideos-downloader) - Extract direct MP4/HLS links and metadata from public XVideos URLs.
- [RedGifs Bulk Downloader ↗](https://apify.com/maximedupre/redgifs-bulk-downloader) - Resolve public RedGifs videos from URLs, IDs, or search.
- [Facebook Media Downloader ↗](https://apify.com/maximedupre/facebook-media-downloader) - Export direct media links from public Facebook videos and reels.
- [TikTok Video Downloader ↗](https://apify.com/maximedupre/tiktok-video-downloader) - Get direct video or audio links from public TikTok video URLs.
- [SoundCloud MP3 Downloader ↗](https://apify.com/maximedupre/soundcloud-mp3-downloader) - Resolve playable media links from public SoundCloud tracks, profiles, playlists, and searches.

**Made with ❤️ by Maxime Dupré**

# Actor input Schema

## `startUrls` (type: `array`):

Add one public PornTrex video page URL per row.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://www.porntrex.com/video/3241735/omg-stepdad-been-wanting-this-for-so-long"
    },
    {
      "url": "https://www.porntrex.com/video/3241697/hey-honey-who-you-fucking-can-i-join"
    },
    {
      "url": "https://www.porntrex.com/video/3241488/alsangels-nia-nacci-photoshoot"
    },
    {
      "url": "https://www.porntrex.com/video/3241742/i-convinced-my-ebony-gf-for-anal-fuck-outdoors-even-after-she-called-it-too-risky"
    },
    {
      "url": "https://www.porntrex.com/video/3241539/mila-fox-quarantine-sex-with-two-fans"
    }
  ]
}
```

# Actor output Schema

## `results` (type: `string`):

Open the dataset with one successful public PornTrex video per row.

# 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 = {
    "startUrls": [
        {
            "url": "https://www.porntrex.com/video/3241735/omg-stepdad-been-wanting-this-for-so-long"
        },
        {
            "url": "https://www.porntrex.com/video/3241697/hey-honey-who-you-fucking-can-i-join"
        },
        {
            "url": "https://www.porntrex.com/video/3241488/alsangels-nia-nacci-photoshoot"
        },
        {
            "url": "https://www.porntrex.com/video/3241742/i-convinced-my-ebony-gf-for-anal-fuck-outdoors-even-after-she-called-it-too-risky"
        },
        {
            "url": "https://www.porntrex.com/video/3241539/mila-fox-quarantine-sex-with-two-fans"
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("maximedupre/porntrex-downloader").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 = { "startUrls": [
        { "url": "https://www.porntrex.com/video/3241735/omg-stepdad-been-wanting-this-for-so-long" },
        { "url": "https://www.porntrex.com/video/3241697/hey-honey-who-you-fucking-can-i-join" },
        { "url": "https://www.porntrex.com/video/3241488/alsangels-nia-nacci-photoshoot" },
        { "url": "https://www.porntrex.com/video/3241742/i-convinced-my-ebony-gf-for-anal-fuck-outdoors-even-after-she-called-it-too-risky" },
        { "url": "https://www.porntrex.com/video/3241539/mila-fox-quarantine-sex-with-two-fans" },
    ] }

# Run the Actor and wait for it to finish
run = client.actor("maximedupre/porntrex-downloader").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "startUrls": [
    {
      "url": "https://www.porntrex.com/video/3241735/omg-stepdad-been-wanting-this-for-so-long"
    },
    {
      "url": "https://www.porntrex.com/video/3241697/hey-honey-who-you-fucking-can-i-join"
    },
    {
      "url": "https://www.porntrex.com/video/3241488/alsangels-nia-nacci-photoshoot"
    },
    {
      "url": "https://www.porntrex.com/video/3241742/i-convinced-my-ebony-gf-for-anal-fuck-outdoors-even-after-she-called-it-too-risky"
    },
    {
      "url": "https://www.porntrex.com/video/3241539/mila-fox-quarantine-sex-with-two-fans"
    }
  ]
}' |
apify call maximedupre/porntrex-downloader --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=maximedupre/porntrex-downloader",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "PornTrex Downloader",
        "description": "Download public PornTrex video data from watch-page URLs. Get direct MP4 links, quality variants, titles, durations, thumbnails, and source URLs.",
        "version": "0.1",
        "x-build-id": "82c2jjeZ6uJr0EGe4"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/maximedupre~porntrex-downloader/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-maximedupre-porntrex-downloader",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/maximedupre~porntrex-downloader/runs": {
            "post": {
                "operationId": "runs-sync-maximedupre-porntrex-downloader",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/maximedupre~porntrex-downloader/run-sync": {
            "post": {
                "operationId": "run-sync-maximedupre-porntrex-downloader",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "startUrls"
                ],
                "properties": {
                    "startUrls": {
                        "title": "PornTrex video URLs",
                        "minItems": 1,
                        "maxItems": 100,
                        "type": "array",
                        "description": "Add one public PornTrex video page URL per row.",
                        "items": {
                            "type": "object",
                            "required": [
                                "url"
                            ],
                            "properties": {
                                "url": {
                                    "type": "string",
                                    "title": "URL of a web page",
                                    "format": "uri"
                                }
                            }
                        }
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
