some endpoints are returning the content type as text/html while the expected is application/json causing CORS error in the client side. when requesting from my localhost or from the server's IP address, the data is returned as expected. which means that the problem occurs from cloudflare. i am using portzilla to route traffic on the domain name to the required port to access the server-side code. i tried specifying the content type header in portzilla, however, the same behaviour happened.
is any more information needed to provide better assistance?