1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "enableSearch": True,
10 "searchTasks": [
11 {
12 "keyword": "sushi",
13 "location": "New York, NY",
14 "maxItems": 10,
15 },
16 {
17 "keyword": "italian",
18 "location": "Chicago, IL",
19 "maxItems": 10,
20 },
21 ],
22 "maxDepthPerTask": 20,
23 "enrichContacts": False,
24 "maxItems": 1000,
25 "proxyConfiguration": {
26 "useApifyProxy": True,
27 "apifyProxyGroups": ["RESIDENTIAL"],
28 },
29}
30
31
32run = client.actor("b2b_leads/opentable-real-time-data").call(run_input=run_input)
33
34
35print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
36for item in client.dataset(run.default_dataset_id).iterate_items():
37 print(item)
38
39