Apify Discord Mirror

Updated 3 weeks ago

Set country for datacenter proxies

Is it possible to set a country for datacenter proxies? I currently have 30 Apify datacenter IPs which I think are from the US.

I'm specifically looking to use EU proxies, country doesn't matter. Is there a way to specify multiple country codes?

Example of how I do it with residential proxies.

Plain Text
const proxyConfiguration = await Actor.createProxyConfiguration({
    groups: ['RESIDENTIAL'],
    countryCode: 'FR',
});
Attachment
image.png
M
L
2 comments
Datacenter proxies are selected by default when you are using Apify proxies, so if you omit groups, you will be using them, and you will be able to select a country for the proxies. They support this, as stated here: https://docs.apify.com/platform/proxy/datacenter-proxy.
Unfortunately, you can select only one country at a time with the countryCode parameter.
Nevertheless, you could try using the groups array: since the datacenter proxies correspond to the auto group, and you can suffix the country you want, you could try doing:
Plain Text
const proxyConfiguration = await Actor.createProxyConfiguration({
    groups: ['auto-FR', 'auto-DE', 'auto-IT', ...],
});
I always thought that I used my 30 IPs when using data center proxies, but I guess they use a bigger pool? Or I can switch which 30 are being used?
Add a reply
Sign up and join the conversation on Discord