UnityGLTF icon indicating copy to clipboard operation
UnityGLTF copied to clipboard

Provide UnityWebRequest Headers options and Post method

Open vsantosu opened this issue 9 years ago • 3 comments

Hello there,

First of all, thanks so much for this loader, it is a great contribution!

Can you provide a HTTP headers dictionary as argumento to the Loader object?

I need to provide authentication token to the Web Server:

`

var www = UnityWebRequest.Get(_gltfUrl);

 foreach(KeyValuePair<string, string> entry in headersDictionary)
 {
    www.SetRequestHeader(entry.Key,entry.Value);
 }

`

Also, can be there an option to use Post instead of Get?

var www = UnityWebRequest.Post(_gltfUrl, postData);

Thanks in advanced!

vsantosu avatar Jul 22 '17 20:07 vsantosu

Fixed in Pull Request 37

vsantosu avatar Jul 23 '17 21:07 vsantosu

Closed #37 So we need to make sure to get the idea of these changes back in.

blgrossMS avatar Mar 11 '18 01:03 blgrossMS

Not high priority due to ILoader interface extensibility (close this @blgrossMS)

Feel free to make a pull request

ericob avatar Jul 09 '18 23:07 ericob