provideRetrofit

@Provides
@Singleton
fun provideRetrofit(okHttpClient: OkHttpClient, gson: Gson, baseUrl: String): Retrofit

Provides an instance of Retrofit.

Return

A configured instance of Retrofit.

Parameters

okHttpClient

The OkHttpClient instance to be used by Retrofit.

gson

The Gson instance for JSON serialization/deserialization.

baseUrl

The base URL for the API.