Select to view content in your preferred language

How to set a proxy on the ArcGISHTTPClient

235
3
04-30-2025 05:11 AM
johnms93
Emerging Contributor

I want all ArcGIS Kotlin SDK traffic to go through a proxy. I would expect to set this through the HTTP client, but the ArcGISHTTPClient doesn't expose any such methods.

I had a look at the network request interception support: https://developers.arcgis.com/kotlin/api-reference/arcgis-maps-kotlin/com.arcgismaps.httpcore/-inter...

But this only lets me change the request URL, headers and parameters.

How would I use a proxy in this case?

0 Kudos
3 Replies
Erick_1
Esri Contributor

Hello,

As of 200.8.0 we do not support configuring a proxy with ArcGISHttpClient. 

Could you share more information on what workflows you'd like to support?

0 Kudos
johnms93
Emerging Contributor

Our application is controlled by MDM to prohibit internet traffic. It connects through VPN to a network which doesn't allow internet access. We have been asked to specifically configure the ArcGIS traffic to go through a proxy so this traffic can be controlled.

We've done this before with Okhttp3, where you can set a proxy on the Builder, and I note that ArcGIS Kotlin SDK uses this under the hood. It would be useful if this configuration option was exposed in the ArcGISHttpClientBuilder.

0 Kudos
Erick_1
Esri Contributor

I appreciate the feedback. We will look into supporting  this in an upcoming release. 

0 Kudos