We had the same issue with RestTemplate, so we decided it’s a bit funny, but changed the user-agent string to “not java” and everything works since then. So, if you put a header like this:
curl -H "User-Agent: Java/1.8.0_131" ...
you will get in response:
<title>Access denied | cloud.squidex.io used Cloudflare to restrict access</title>
<div class="cf-section cf-wrapper">
<div class="cf-columns two">
<h2 data-translate="what_happened">What happened?</h2>
<p>The owner of this website (cloud.squidex.io) has banned your access based on your browser's signature (49572abeec7a8c7c-ua21).</p>