Skip to content

Collection of Kotlin extensions for OkHttp

Notifications You must be signed in to change notification settings

Horstexplorer/okhttp-ktx

Repository files navigation

okhttp-ktx

Collection of Kotlin extensions for OkHttp

Obtain this library via Github or Jitpack using Maven or Gradle

Features

  • enhanced proxy support

Usage Examples

Okhttp client using a socks proxy with credentials

val withCredentials = socksProxy.extended(UsernamePasswordCredentials(username, password))
val proxiedOkhttpClient = okhttpClient.withProxy(withCredentials)

Proxy provider and call manager

val rotatingProvider = RotatingProxyProvider(proxies)
val nextProxy = rotatingProvider.next()

val callManager = SimpleProxyCallManager(okhttpClient, rotatingProvider)
callManager.newCall(request).execute()

About

Collection of Kotlin extensions for OkHttp

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages