1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "task": "export_products",
10 "shopifyStore": "my-store.myshopify.com",
11 "format": "json",
12 "dateRange": {
13 "from": "2024-01-01",
14 "to": "2024-12-31",
15 },
16 "orderStatus": "all",
17 "limit": 0,
18 "bulkUpdateData": {
19 "action": "update_prices",
20 "filter": { "tags": ["sale"] },
21 "updates": { "price_adjustment": "-10%" },
22 },
23 "inventorySyncConfig": {
24 "source": "external_csv",
25 "updateMethod": "set",
26 "notifyOnLowStock": True,
27 "lowStockThreshold": 5,
28 },
29 "outputDestination": "dataset",
30}
31
32
33run = client.actor("waxlike_polecat/shopify-automation-toolkit").call(run_input=run_input)
34
35
36print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
37for item in client.dataset(run["defaultDatasetId"]).iterate_items():
38 print(item)
39
40