@rexxhayanasi/xhubscraper v1.0.3
✨ New Update: Now Supports Multiple Platforms!
We are excited to announce that @rexxhayanasi/xhubscraper is no longer limited to downloading just YouTube MP3/MP4. The latest update now supports a wide range of media platforms including:
- YouTube
YTMP3/4,StalkChannel,Transcript,Ytdlv2 - TikTok
tiktokvideo,tiktokimage - Stickersearch
- Githubstalk
- Videy
Krakenfiles
With this update, you can now easily scrape and download videos and audio from these popular platforms with just a few simple commands. Whether you're looking to grab content from YouTube, TikTok, Instagram posts, or Twitter tweets, this tool has you covered!
Stay tuned for more updates and features coming soon!👤 Developer
📞 Contact and Support
If you need help or have any questions, feel free to reach out via:
We're here to assist you and keep you updated on all the latest features!
📦 Installation
To get started, install the package via npm:
npm install @rexxhayanasi/xhubscraper⚡ Usage
Once installed, you can easily import and use the following functions:
const { search, ytmp3, ytmp4, ytdlv2, channel } = require('@rexxhayanasi/xhubscraper');🎧 Available Quality Options
You can choose from the following quality options for audio and video:
Audio Quality (MP3):
const audioQualities = [64, 96, 128, 192, 256, 320]; // kbpsVideo Quality (MP4):
const videoQualities = [360, 480, 720, 1080]; // p🎧 Download Audio (MP3)
To download audio in MP3 format, use the following example:
// Provide the YouTube URL
const url = 'https://www.youtube.com/watch?v=YOUR_VIDEO_ID';
// Choose the quality you want to download (from the available audio qualities)
const quality = "128"; // Example quality: 128 kbps
// Download the audio
ytmp3(url, quality)
.then(result => {
if (result.status) {
console.log('Download Link:', result.download); // Download URL
console.log('Metadata:', result.metadata); // Metadata of the track
} else {
console.error('Error:', result.result); // Handle errors
}
});📹 Download Video (MP4)
To download video in MP4 format, use the following example:
// Provide the YouTube URL
const url = 'https://www.youtube.com/watch?v=YOUR_VIDEO_ID';
// Choose the quality you want to download (from the available video qualities)
const quality = "360"; // Example quality: 360p
// Download the video
ytmp4(url, quality)
.then(result => {
if (result.status) {
console.log('Download Link:', result.download); // Download URL
console.log('Metadata:', result.metadata); // Metadata of the video
} else {
console.error('Error:', result.result); // Handle errors
}
});🤖 Download YTDLV2 (MP3 & MP4)
To download both MP3 and MP4 formats using the ytdlv2 function, you can use the following example:
// Provide the YouTube URL
const url = 'https://www.youtube.com/watch?v=YOUR_VIDEO_ID';
/*
* Choose the quality for download:
* You can select either audio or video quality from the available options:
* - Audio: [64, 96, 128, 192, 256, 320] (kbps)
* - Video: [360, 480, 720, 1080] (p)
*/
// Example for selecting video quality:
const quality = 360; // 360p video quality
// Example for selecting audio quality:
const quality = 128; // 128kbps audio quality
/*
* Alternatively, you can skip specifying the quality
* and let it default to the 128kbps audio and 360p video:
* Example: ytdlv2(url)
*/
ytdlv2(url, quality)
.then(result => {
if (result.status) {
console.log('Download Link:', result.download); // The download link
console.log('Metadata:', result.metadata); // The metadata of the file
} else {
console.error('Error:', result.result); // Handle errors
}
});Channel Stalker
Use the channel(query) function to fetch public details of a YouTube channel based on the username or channel name.
// Insert the YouTube channel username or name
const query = 'your channel username or name';
channel(query)
.then(result => {
if (result.status) {
console.log('Channel Results:', result.results); // Display fetched channel data
} else {
console.error('Error:', result.result); // Handle error
}
});requested with import/require examples and a clean approach:
# 🎵 TikTok Media Downloader
Support downloading **HD TikTok Videos** and **Photo Mode (multi-image)**
Built with `axios` and `cheerio@1.0.0-rc.12`.📦 Installation
npm install axios &
npm install cheerio@1.0.0-rc.12💫 [according to your wishes but sometimes the latest version of Cheerio does not necessarily support the functions here
📚 Features
- ✅ Download HD TikTok videos (via TikWM)
- ✅ Download images from TikTok Photo Mode (via DLPanda) Scrape HTML use cheerio
- ✅ Get video metadata like title, music, duration, and more
▶️ Example Usage
TikTok Video (HD via TikWM)
import { tiktokdl } from '@rexxhayanasi/xhubscraper';
(async () => {
const url = "https://www.tiktok.com/@username/video/1234567890123456789";
const result = await tiktokdl(url);
if (result.status) {
console.log("Video HD URL:", result.data.hdplay);
console.log("Music URL:", result.data.music);
console.log("Cover Image:", result.data.cover);
} else {
console.error("Error:", result.message);
}
})();TikTok Photo Mode (via DLPanda + Cheerio)
import { tiktokImage } from '@rexxhayanasi/xhubscraper';
(async () => {
const url = "https://www.tiktok.com/@username/photo/1234567890123456789";
const result = await tiktokImage(url);
if (result.status) {
console.log("Image URLs:", result.data);
} else {
console.error("Error:", result.message);
}
})();📤 Response Format
Video
{
"status": true,
"creator": "username",
"data": {
"title": "caption from TikTok",
"author": "@rexxhayanasi",
"music": "https://...",
"duration": "15s",
"cover": "https://...",
"play": "https://...",
"hdplay": "https://..."
}
}Photo Mode
{
"status": true,
"creator": "@RexxHayanasi",
"data": [
"https://photo1.jpg",
"https://photo2.jpg",
"https://photo3.jpg"
]
}⚠️ Notes
tiktokdluses the official TikWM API for video downloads.tiktokImageuses HTML scraping via DLPanda, so the structure may change anytime.- Cheerio is used to parse image elements from the TikTok Photo Mode HTML.
This version uses `import`/`require` in a clean manner and reflects the features of your project for TikTok video and photo downloads.
Instagram Downloader
Feature to download Instagram videos from the copy link method, not the share post method
import { instagramdl } from '@rexxhayanasi/xhubscraper';
// atau CommonJS
// const { instagramdl } = require('@rexxhayanasi/xhubscraper');
/**
* Mengambil link media dari sebuah URL Instagram.
* @param {string} url - URL postingan Instagram yang ingin didownload.
* @returns {Promise<string[]>} Array berisi link media yang bisa diunduh.
*/
async function instagramdl(url)
const url = 'https://www.instagram.com/***********';
instagramdl(url)
.then(links => {
console.log('Link media Instagram:', links);
})
.catch(err => {
console.error('Error saat download media:', err);
});Github Stalk
This feature helps you to view/stalk a GitHub account using its username to get information related to the account.
import { githubstalk } from '@rexxhayanasi/xhubscraper';
async function cekProfil(user) {
const res = await githubstalk(user);
if (res.status) {
console.log('Data Profil GitHub:', res.result);
} else {
console.error('Error:', res.message);
}
}
cekProfil('rexxzy'); // Ganti username GitHub sesuai kebutuhanthis is the JSON result
{
"status": true,
"creator": "@rexxhayanasi/xhubscraper",
"result": {
"username": "rexxzy",
"nickname": "Rexxzy",
"bio": "Owner XHUBSCRAPER",
"id": 12345678,
"nodeId": "***********",
"profile_pic": "https://avatars.githubusercontent.com/u/12345678?v=4",
"url": "https://github.com/RexxHayanasi",
"type": "User",
"admin": false,
"company": "Archave",
"blog": "https://archavecommunity.biz.id",
"location": "Indonesia",
"email": null,
"public_repo": 25,
"public_gists": 0,
"followers": 80,
"following": 10,
"created_at": "2021-01-01T00:00:00Z",
"updated_at": "2025-05-16T07:00:00Z"
}
}✨ Stickersearch
This feature is to help you search for stickers with the title search you want.
import { stickersearch } from '@rexxhayanasi/xhubscraper';
async function run() {
try {
const result = await stickersearch('GenshinImpact');
if (result.status) {
console.log('Judul:', result.title);
console.log('Author:', result.author);
console.log('Link Author:', result.author_link);
console.log('Daftar URL stiker:', result.sticker);
} else {
console.log('Sticker tidak ditemukan!');
}
} catch (error) {
console.error('Error:', error.message || error);
}
}
run();Videy
This feature is for downloading sources on the videy.co website directly.
import { videy } from '@rexxhayanasi/xhubscraper';
async function main() {
const url = 'https://videy.co/*******"**';
const videoUrl = await videy(url);
if (videoUrl) {
console.log('URL video MP4:', videoUrl);
} else {
console.log('Gagal mendapatkan URL video.');
}
}
main();🐙 Krakenfiles
This feature is for downloading files from the Krakenfiles website.
import { krakenfiles } from '@rexxhayanasi/xhubscraper';
// atau CommonJS
// const { krakenfiles } = require('@rexxhayanasi/xhubscraper')
/**
* Mengambil data file dari URL Krakenfiles.
* @param {string} url - Link halaman krakenfiles yang akan di-scrape.
* @returns {Promise<Object>} Objek detail file dan link unduhan.
*/
async function krakenfiles(url)
const url = 'https://krakenfiles.com/abc123xyz';
krakenfiles(url)
.then(data => {
console.log('Judul File:', data.title);
console.log('Views:', data.views);
console.log('Downloads:', data.downloads);
console.log('Link Download:', data.url);
})
.catch(err => {
console.error('Error:', err);
});