1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "items": [
12 "https://firebasestorage.googleapis.com/v0/b/kongo-ln.appspot.com/o/girl%20sexy%20hot%20sun%20sea%20beach.jpg?alt=media&token=7ec36226-6a7a-4241-99a3-5bde4bbde2c6",
13 "https://firebasestorage.googleapis.com/v0/b/kongo-ln.appspot.com/o/emma%20watson%20in%20bikini%20on%20the%20beach.jpg?alt=media&token=73af0ea9-c80e-4aa8-be7c-7e79917e6559",
14 "https://firebasestorage.googleapis.com/v0/b/kongo-ln.appspot.com/o/chris%20evans%20as%20peaky%20blinders%20higly%20detailed.jpg?alt=media&token=e8167234-c864-4df3-9590-2a932edb0a4a"
15 ],
16 "datasets": [
17 {
18 "id": "serTsUnXrLOVXjPtd",
19 "fields": [
20 "value"
21 ]
22 }
23 ]
24};
25
26
27const run = await client.actor("datastorm/nsfw-scraper").call(input);
28
29
30console.log('Results from dataset');
31console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
32const { items } = await client.dataset(run.defaultDatasetId).listItems();
33items.forEach((item) => {
34 console.dir(item);
35});
36
37