use of io.plaidapp.data.api.DenvelopingConverter in project plaid by nickbutcher.
the class DesignerNewsPrefs method createApi.
private void createApi() {
final OkHttpClient client = new OkHttpClient.Builder().addInterceptor(new ClientAuthInterceptor(accessToken, BuildConfig.DESIGNER_NEWS_CLIENT_ID)).build();
final Gson gson = new Gson();
api = new Retrofit.Builder().baseUrl(DesignerNewsService.ENDPOINT).client(client).addConverterFactory(new DenvelopingConverter(gson)).addConverterFactory(GsonConverterFactory.create(gson)).build().create(DesignerNewsService.class);
}
use of io.plaidapp.data.api.DenvelopingConverter in project plaid by nickbutcher.
the class BaseDataManager method createProductHuntApi.
private void createProductHuntApi() {
final OkHttpClient client = new OkHttpClient.Builder().addInterceptor(new AuthInterceptor(BuildConfig.PROCUCT_HUNT_DEVELOPER_TOKEN)).build();
final Gson gson = new Gson();
productHuntApi = new Retrofit.Builder().baseUrl(ProductHuntService.ENDPOINT).client(client).addConverterFactory(new DenvelopingConverter(gson)).addConverterFactory(GsonConverterFactory.create(gson)).build().create(ProductHuntService.class);
}
use of io.plaidapp.data.api.DenvelopingConverter in project plaid by nickbutcher.
the class DribbblePrefs method createApi.
private void createApi() {
final OkHttpClient client = new OkHttpClient.Builder().addInterceptor(new AuthInterceptor(getAccessToken())).build();
final Gson gson = new GsonBuilder().setDateFormat(DribbbleService.DATE_FORMAT).create();
api = new Retrofit.Builder().baseUrl(DribbbleService.ENDPOINT).client(client).addConverterFactory(new DenvelopingConverter(gson)).addConverterFactory(GsonConverterFactory.create(gson)).build().create((DribbbleService.class));
}
Aggregations