package Ġcom . ray w ender lich . android . task ie . networking Ċ Ċ import Ġokhttp 3 . Ok HttpClient Ċ import Ġretrofit 2 . Ret rofit Ċ import Ġretrofit 2 . converter . mos hi . M oshi Converter Factory Ċ Ċ /** Ċ Ġ* ĠBuilds Ġretrofit Ġdependencies . Ċ Ġ*/ Ċ fun Ġbuild Client (): ĠOk HttpClient Ġ= ĊĠĠĠ ĠOk HttpClient . Builder () ĊĠĠĠĠĠĠĠ Ġ. build () Ċ Ċ fun Ġbuild Ret rofit (): ĠRet rofit Ġ{ ĊĠ Ġreturn ĠRet rofit . Builder () ĊĠĠĠĠĠ Ġ. client ( build Client ()) ĊĠĠĠĠĠ Ġ. baseUrl ( BASE _ URL ) ĊĠĠĠĠĠ Ġ. add Converter Factory ( M oshi Converter Factory . create (). as Len ient ()) ĊĠĠĠĠĠ Ġ. build () Ċ } Ċ Ċ fun Ġbuild ApiService (): ĠRemote ApiService Ġ= ĊĠĠĠ Ġbuild Ret rofit (). create ( Remote ApiService :: class . java )