Recently I have been trying to do basic Web post requests and for some reason the inconsistency in Unity’s web request system is slightly causing frustration.
In Unity 2022 you can do this
UnityWebRequest www = UnityWebRequest.Post(sparqlEndpointURL, sparqlQuery, “application/sparql-query”);
Which creates a post request with a content-type of application/sparql-query
Unfortunately, for breaking changes in AR Foundation, we need to stick to Unity version 2021… where this code doesn’t work. I thought it would be as straight forward as writing this instead:
UnityWebRequest www = UnityWebRequest.Post(sparqlEndpointURL, sparqlQuery);
but no, doesn’t work
Is there a way we can see what actually is being sent so that I know where the problem is.