Skip to content

Instantly share code, notes, and snippets.

@enginebai

enginebai/Api.kt

Created Jul 26, 2018
Embed
What would you like to do?
object Api {
fun api1(): Observable<Response<Media>> =
ApiHelper.getApi().api1()
fun api2(uploadUrl: String): Observable<okhttp3.Response> =
Observable.fromCallable {
val request = Request.Builder()
.url(uploadUrl)
.build()
ApiHelper.getMediaUploadHttpClient().newCall(request).execute()
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.