Thanks for the response Michael.
So this is indeed an http request being made from an application on a server which uses Cloudflare as a CDN and WAF (I guess “proxied”?). Not sure why, but we have noticed that this issue happens only when we make the request from servers that “use” Cloudflare and not from other servers.
Someone even posted about it on the Apple Developer forum but not much engagement there:
It’s a tough problem, bc I figure even if Apple responded they would say that their API works fine and so this must be some issue with our side (either our server itself or Cloudflare). Since we have tried multiple servers from different providers, the only common denominator is Cloudflare (I have the same problem making the request from two different servers from two different providers that both use Cloudflare and when I try the request from a server that doesnt use Cloudflare then it works fine).
Again appreciate your help troubleshooting!