What are the terms of use for cdn-cgi/trace?

Can someone point me to the CloudFlare terms of use for https://www.cloudflare.com/cdn-cgi/trace?
I want to use cdn-cgi/trace to redirect visitors to my website to other country specific websites.
How can I license the use of this service cdn-cgi/trace?
And where can I get the terms of use/license agreement etc. to make sure I am CCPA/GDPR compliant.

Update in response to @sdayman 's question:
My use-case is very different from the typical CloudFlare use-case - I am not looking to route my traffic through CloudFlare. I have several websites - a .com website and some country specific websites e.g. .co.uk. I want to redirect all traffic from outside the US that attempts to access the .com website via the website code.

I already have a simple way to map IP address to Country. However, I can’t get the website visitor’s Client IP Address because of that way my server infrastructure is setup but I found that I can embed cdn-cgi/trace in the webpage being displayed to visitor and use it to get the IP address. Once I have the IP address I can add a little client-side Javascript to my webpages to do the redirect for me.

I have done a PoC and it works fine. Now all I need is to work out the following:
1.) Am I legally allowed to do this? How can I purchase a license to use this.
2.) When I use this, does CloudFlare collect any data that could make my site CCPA/CGPR non-compliant.

I’m not sure how you’d get the results of your visitors’ cdn-cgi/trace query. Why not use cf-ipcountry?

I want to use cdn-cgi/trace in a bit of Javascript that I will embed in the webpages of my site to change the page being displayed to the visitor depending on which country the visitor is from. This is totally different from the typical CloudFlare use-case. I have added more details in the originally posted question.

1 Like

So you essentially want to use the value of loc on a non-proxied site? That should be possible and @Judge is doing that very same thing (well, for colo) at https://cloudflare-test.judge.sh, however I’d generally advise against it. It would be much better and more stable if you manage to get the IP address and then match that to the country, than going that route.

As for a licence, that should not be necessary.

This topic was automatically closed after 14 days. New replies are no longer allowed.