Extract HLS streaming URLs from VidSrc using pure HTTP requests.
npm install @definisi/vidsrc-scraperimport { scrapeVidsrc } from '@definisi/vidsrc-scraper';
// Scrape a movie by TMDB ID
const result = await scrapeVidsrc('27205', 'movie');
if (result.success) {
console.log('HLS URL:', result.hlsUrl);
console.log('Subtitles:', result.subtitles);
}
// Scrape a TV episode
const tvResult = await scrapeVidsrc('1399', 'tv', '1', '1');| Option | Type | Default | Description |
|---|---|---|---|
| timeout | number | 30000 | Request timeout in milliseconds |
| cacheTtl | number | 900 | Cache time-to-live in seconds |
const result = await scrapeVidsrc('27205', 'movie', null, null, {
timeout: 60000,
cacheTtl: 1800,
});interface ScrapeResult {
tmdbId: string;
type: 'movie' | 'tv';
season: string | null;
episode: string | null;
hlsUrl: string | null;
subtitles: string[];
success: boolean;
timestamp: string;
}The HLS URLs require proper headers. Example with VLC:
vlc "HLS_URL" \
--http-user-agent="Mozilla/5.0" \
--http-referrer="https://cloudnestra.com/"- Fetches embed page from
vidsrc-embed.ru - Extracts RCP iframe URL from cloudnestra.com
- Extracts prorcp hash from RCP page
- Fetches M3U8 URL from prorcp endpoint
- Resolves domain placeholders (
{v1}-{v5}->cloudnestra.com)
- Node.js 18+
MIT