1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "action": "scrapeData",
10 "url": "https://wordpress.org/plugins/?plugin_business_model=commercial",
11 "columnMappings": [
12 {
13 "key": "name",
14 "value": "2",
15 },
16 {
17 "key": "link",
18 "value": "0",
19 },
20 {
21 "key": "ratings",
22 "value": "4",
23 },
24 {
25 "key": "authorName",
26 "value": "8",
27 },
28 {
29 "key": "usersCount",
30 "value": "9",
31 },
32 {
33 "key": "description",
34 "value": "6",
35 },
36 {
37 "key": "lastUpdated",
38 "value": "11",
39 },
40 {
41 "key": "pluginLogo",
42 "value": "1",
43 },
44 ],
45 "tableNumber": 1,
46 "nextPageSelector": ".next.page-numbers",
47 "count": 100,
48 "minDelay": 2,
49 "maxDelay": 2,
50}
51
52
53run = client.actor("curious_coder/instant-web-scraper").call(run_input=run_input)
54
55
56print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
57for item in client.dataset(run["defaultDatasetId"]).iterate_items():
58 print(item)
59
60