1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "screenPolicy": {
12 "platform": "Amazon US",
13 "category": "consumer electronics accessories",
14 "own_brands": [
15 "Your Brand"
16 ],
17 "watchlist": {
18 "brands": [
19 "Apple",
20 "AirPods",
21 "Anker",
22 "Bose",
23 "Sony",
24 "Samsung",
25 "Nike",
26 "Dyson",
27 "Stanley"
28 ],
29 "franchises": [
30 "Disney",
31 "Mickey Mouse",
32 "Marvel",
33 "Pokemon",
34 "Hello Kitty",
35 "Star Wars"
36 ],
37 "prohibited_terms": [
38 "FDA approved",
39 "cures",
40 "treats",
41 "medical grade",
42 "100% safe",
43 "best seller",
44 "#1 on Amazon",
45 "military grade"
46 ]
47 },
48 "restricted_categories": [
49 "lithium batteries",
50 "supplements",
51 "cosmetics",
52 "medical devices",
53 "children's toys under 3"
54 ]
55 },
56 "listings": [
57 {
58 "id": "1",
59 "title": "Your Brand silicone case for AirPods Pro",
60 "brand": "Your Brand",
61 "bullets": [
62 "Compatible with AirPods Pro",
63 "Soft-touch finish"
64 ],
65 "description": "A Your Brand case. Fits AirPods Pro. Not made by Apple."
66 }
67 ]
68};
69
70
71const run = await client.actor("jev-tools/listing-risk-screen").call(input);
72
73
74console.log('Results from dataset');
75console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
76const { items } = await client.dataset(run.defaultDatasetId).listItems();
77items.forEach((item) => {
78 console.dir(item);
79});
80
81