1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "maxItems": 10,
12 "mode": "lookup",
13 "slugs": `inception
14parasite-2019
15the-godfather
16the-dark-knight
17pulp-fiction
182001-a-space-odyssey
19there-will-be-blood
20the-godfather-part-ii
21spirited-away
22in-the-mood-for-love
23goodfellas
24fight-club
25the-shawshank-redemption
26the-empire-strikes-back
27blade-runner-2049
28oppenheimer
29the-lord-of-the-rings-the-fellowship-of-the-ring
30the-lord-of-the-rings-the-two-towers
31the-lord-of-the-rings-the-return-of-the-king`,
32 "query": "godfather"
33};
34
35
36const run = await client.actor("parseforge/letterboxd-films-scraper").call(input);
37
38
39console.log('Results from dataset');
40console.log(`πΎ Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
41const { items } = await client.dataset(run.defaultDatasetId).listItems();
42items.forEach((item) => {
43 console.dir(item);
44});
45
46