1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "sources": [
10 {
11 "url": "https://raw.githubusercontent.com/TheSpeedX/PROXY-List/master/http.txt",
12 "protocol": "http",
13 },
14 {
15 "url": "https://raw.githubusercontent.com/monosans/proxy-list/main/proxies/http.txt",
16 "protocol": "http",
17 },
18 {
19 "url": "https://raw.githubusercontent.com/TheSpeedX/PROXY-List/master/socks5.txt",
20 "protocol": "socks5",
21 },
22 {
23 "url": "https://raw.githubusercontent.com/hookzof/socks5_list/master/proxy.txt",
24 "protocol": "socks5",
25 },
26 ],
27 "proxies": [],
28 "maxProxies": 1000,
29 "targetWorking": 50,
30 "concurrency": 200,
31 "timeoutSecs": 8,
32 "onlyWorking": True,
33 "lookupCountry": True,
34}
35
36
37run = client.actor("proxy-solutions/free-proxy-scraper-checker").call(run_input=run_input)
38
39
40print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
41for item in client.dataset(run.default_dataset_id).iterate_items():
42 print(item)
43
44