public static void getClientTimeline( PlexClient client, final int commandId, final PlexHttpMediaContainerHandler responseHandler) { String url = String.format("http://%s:%s", client.address, client.port); PlexHttpService service = getService(url, true); Logger.d( "Polling timeline with uuid %s", VoiceControlForPlexApplication.getInstance().prefs.getUUID()); Call<MediaContainer> call = service.pollTimeline( VoiceControlForPlexApplication.getInstance().prefs.getUUID(), commandId); call.enqueue( new Callback<MediaContainer>() { @Override public void onResponse(Response<MediaContainer> response) { responseHandler.onSuccess(response.body()); } @Override public void onFailure(Throwable t) { responseHandler.onFailure(t); } }); }