1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "mode": "browse",
12 "queries": [
13 "horror"
14 ],
15 "creators": [
16 "gbpatch"
17 ],
18 "jams": [
19 "gmtk-2024"
20 ],
21 "urls": [
22 "https://itch.io/games/top-rated/genre-puzzle",
23 "https://itch.io/games/genre-puzzle?page=2",
24 "https://itch.io/games/tag-horror",
25 "https://itch.io/games/genre-puzzle/tag-pixel-art",
26 "https://itch.io/games/free",
27 "https://itch.io/games/platform-web",
28 "https://itch.io/games/in-jam",
29 "https://itch.io/games/new-and-popular",
30 "https://itch.io/games/newest/genre-puzzle",
31 "https://itch.io/search?q=horror",
32 "https://gbpatch.itch.io/our-life",
33 "https://gbpatch.itch.io/our-life/comments",
34 "https://gbpatch.itch.io/our-life/devlog",
35 "https://gbpatch.itch.io/",
36 "https://itch.io/profile/gbpatch",
37 "https://itch.io/jam/gmtk-2024",
38 "https://itch.io/jam/gmtk-2024/results",
39 "https://itch.io/jam/gmtk-2024/entries",
40 "https://itch.io/jams",
41 "https://itch.io/jams/past"
42 ],
43 "proxy": {
44 "useApifyProxy": true
45 },
46 "incrementalMode": false,
47 "emitUnchanged": false,
48 "emitExpired": false,
49 "ignoreFieldsForChanges": []
50};
51
52
53const run = await client.actor("abotapi/itch-io-scraper").call(input);
54
55
56console.log('Results from dataset');
57console.log(`πΎ Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
58const { items } = await client.dataset(run.defaultDatasetId).listItems();
59items.forEach((item) => {
60 console.dir(item);
61});
62
63