1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "mode": "channel_search",
12 "maxResults": 10,
13 "searchQueries": [
14 "linux"
15 ],
16 "instanceUrl": "https://tilvids.com",
17 "channelUrls": [
18 "https://tilvids.com/c/thelinuxexperiment_channel"
19 ],
20 "websiteUrls": [
21 "https://tilvids.com"
22 ],
23 "playlistUrls": [
24 "https://framatube.org/w/p/5b09770d-a919-4301-8050-e37caef31d00"
25 ],
26 "videoUrls": [
27 "https://tilvids.com/w/adb3102a-f329-44a8-86c7-50c7e52a5bd7"
28 ]
29};
30
31
32const run = await client.actor("scrapingmonkey/peertube-scraper").call(input);
33
34
35console.log('Results from dataset');
36console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
37const { items } = await client.dataset(run.defaultDatasetId).listItems();
38items.forEach((item) => {
39 console.dir(item);
40});
41
42