This commit is contained in:
aka paul
2026-03-09 16:25:36 +01:00
parent 2a3817f04f
commit c477fb7bb0
165 changed files with 0 additions and 0 deletions
+148
View File
@@ -0,0 +1,148 @@
async function searchResults(keyword) {
const results = [];
try {
const urls = [
'https://wearechecking.wtf/streams-pages/motorsports',
'https://wearechecking.wtf/streams-pages/football',
'https://wearechecking.wtf/streams-pages/others'
];
const responses = await Promise.all(
urls.map(url => fetchv2(url).then(res => res.text()))
);
for (const html of responses) {
const wrapperRegex = /<div class="stream-wrapper[^"]*"[^>]*>([\s\S]*?)<\/div>\s*<!--.*?stream close -->/gi;
let wrapperMatch;
while ((wrapperMatch = wrapperRegex.exec(html)) !== null) {
const wrapperContent = wrapperMatch[1];
const imgRegex = /<img class="stream-thumb" src="([^"]+)"/i;
const imgMatch = imgRegex.exec(wrapperContent);
const imageUrl = imgMatch ? imgMatch[1].replace('..', 'https://wearechecking.wtf').replace(/\\/g, '/') : '';
const seriesTitleRegex = /<img src="[^"]*[\/\\]([^\/\\]+)\.svg"/i;
const seriesMatch = seriesTitleRegex.exec(wrapperContent);
const sport = seriesMatch ? seriesMatch[1].toUpperCase() : 'UNKNOWN';
const streamLinkRegex = /<div class="stream-feed[^"]*"[^>]*onclick="location\.href='([^']+)'[^>]*>\s*<p><span class="unix-timestamp">\d+<\/span>([^<]+)<\/p>/gi;
let linkMatch;
while ((linkMatch = streamLinkRegex.exec(wrapperContent)) !== null) {
const streamUrl = 'https://wearechecking.wtf' + linkMatch[1];
const eventName = linkMatch[2].trim();
const title = `[${sport}] ${eventName}`;
results.push({
title: title,
image: imageUrl,
href: streamUrl
});
}
}
}
return JSON.stringify(results);
} catch (err) {
return JSON.stringify([{
title: "Error",
image: "Error",
href: "Error"
}]);
}
}
async function extractDetails(url) {
try {
return JSON.stringify([{
description: "",
aliases: "",
airdate: ""
}]);
} catch (err) {
return JSON.stringify([{
description: "Error",
aliases: "Error",
airdate: "Error"
}]);
}
}
async function extractEpisodes(url) {
const results = [];
try {
results.push({
href: url,
number: 1
});
return JSON.stringify(results);
} catch (err) {
return JSON.stringify([{
href: "Error",
number: "Error"
}]);
}
}
async function extractStreamUrl(pageUrl) {
try {
const response = await fetchv2(pageUrl);
const html = await response.text();
const iframeRegex = /(?:document\.getElementById\('feed-iframe'\)\.src|src)\s*=\s*['"]https:\/\/ihatestreams\.xyz\/embed\/([a-f0-9\-]+)['"]/i;
const match = iframeRegex.exec(html);
if (!match) return JSON.stringify({ streams: [], subtitle: null });
const streamId = match[1];
const streamResponse = await fetchv2(`https://ihatestreams.xyz/get-stream?id=${streamId}`);
const streamData = await streamResponse.json();
let streamUrl = streamData.pointer;
let headers = {};
if (!streamUrl.startsWith("http")) {
const baseUrl = `https://gg.revoltedpeanuts.com/${streamUrl}/`;
headers = {
"Referer": "https://ihatestreams.xyz/",
"Origin": "https://ihatestreams.xyz"
};
const manifestResponse = await fetchv2(baseUrl + "index.m3u8", headers);
const manifestText = await manifestResponse.text();
const lines = manifestText.split("\n").map(l => l.trim());
const relativePath = lines.find(l => l && !l.startsWith("#")) || "index.m3u8";
streamUrl = baseUrl + relativePath;
}
return JSON.stringify({
streams: [
{
title: streamData.title || "Unknown",
streamUrl,
headers
}
],
subtitle: streamData.subtitle || null
});
} catch (err) {
return JSON.stringify({
streams: [
{
title: "Error",
streamUrl: "https://error.org/",
headers: {}
}
],
subtitle: null
});
}
}
+21
View File
@@ -0,0 +1,21 @@
{
"sourceName": "WeAreChecking",
"iconUrl": "https://files.catbox.moe/lpsbf8.png",
"author": {
"name": "50/50",
"icon": "https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQ3122kQwublLkZ6rf1fEpUP79BxZOFmH9BSA&s"
},
"version": "1.0.0",
"language": "English",
"streamType": "HLS",
"quality": "1080p",
"baseUrl": "https://wearechecking.wtf/",
"searchBaseUrl": "https://wearechecking.wtf/",
"scriptUrl": "https://git.luna-app.eu/50n50/sources/raw/branch/main/wearechecking/wearechecking.js",
"type": "shows",
"asyncJS": true,
"softsub": true,
"downloadSupport": false,
"supportsSora": true,
"supportsLuna": true
}