Skip to content
Mojtaba Razaghi edited this page Sep 30, 2019 · 3 revisions

Welcome to the RetrofitHelper wiki!

This is a library written in Kotlin, for simplifying the API calls in android.
The retrofit helper will make a synchronous call, just using multiple lines of code.
It's as easy as this :

 retrofitClient.Get<GetResponseModel>()
            .setPath("api/users/2"))
            .setResponseHandler(GetResponseModel::class.java,
                object : ResponseHandler<GetResponseModel>() {
                    override fun onSuccess(response: Response<GetResponseModel>) {
                        super.onSuccess(response)
                        //Handle Response
                    }
                }).run(this)

Using the benefits of RxAndroid, the API calls will occur in IO thread and the response will get to you in UI thread.

Retrofit Helper Documentation

Clone this wiki locally