Setup Proxy for Xamarin development

Yauheni Pakala
1 min readApr 7, 2019

--

The short collection of fast steps about setup HTTP Proxying for iOS and Android development with Xamarin

Charles Proxy

Fiddler

Xamarin specific

  1. If you use the native (AndroidClientHandler, NSUrlSession) HTTP handler, then nothing needs to be done.
  2. If you use HTTP handler by default (managed), follow above:

Setup the proxy with a custom HttpClientHandler:

var handler = new HttpClientHandler
{
// local ip, charles port
Proxy = new WebProxy("192.168.0.52", 8888)
};

Then use it whenever you create an HttpClient in your app

var client = new HttpClient(handler);
// TODO: make some requests to test charles!

More resources

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Yauheni Pakala
Yauheni Pakala

Written by Yauheni Pakala

I’m a software engineer. I’m a fan of technology, cross-platform development, and programming.

No responses yet

Write a response