Is it possible to add custom HTTP headers to every layer request (p.e. WMTSLayer)? I'd like to add the referer header because otherwise the WMTS Service doesn't delivier the image.
Unfortunately I wasn't able to alter the Referer item (translated to English):
"Attempt to use a forbidden header was rejected: Referer"
In 3.x you can use esriRequest.setRequestPreCallback()
esri/request | API Reference | ArcGIS API for JavaScript 3.17
This will let you modify the request before it is sent.
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.