Модуль для парсинга json ответов сервера
- Добавить
ResponseTypeAdapterFactoryв билдер gson`aGsonBuilder() .registerTypeAdapterFactory(responseTypeAdapterFactory) .create() - Добавить
gsonв билдер ретрофитаRetrofit.Builder() .client(okHttpClient) .baseUrl(apiUrl.toString()) .addConverterFactory(GsonConverterFactory.create(gson)) .addCallAdapterFactory(callAdapterFactory) .build()
Пример использования в приложении
Gradle:
implementation "ru.surfstudio.android:converter-gson:X.X.X"