The Free Software Media System - Server Backend & API
Added GetRecentlyAddedItemsAsync method in ApiClient.
ScottIsAFool Scott Lovegrove ScottIsAFool300cf1ba18de
diff --git a/MediaBrowser.ApiInteraction/ApiClient.cs b/MediaBrowser.ApiInteraction/ApiClient.csindex 4e519ce4fb..55c30765d1 100644--- a/MediaBrowser.ApiInteraction/ApiClient.cs+++ b/MediaBrowser.ApiInteraction/ApiClient.cs@@ -104,6 +104,20 @@ namespace MediaBrowser.ApiInteraction}}+ /// <summary>+ /// Gets the recently added items+ /// </summary>+ /// <param name="userId">The user id.</param>+ /// <returns></returns>+ public async Task<DTOBaseItem[]> GetRecentlyAddedItemsAsync(Guid userId)+ {+ string url = ApiUrl + "/itemlist?listtype=recentlyaddeditems&userId=" + userId.ToString();+ using (Stream stream = await GetSerializedStreamAsync(url).ConfigureAwait(true))+ {+ return DeserializeFromStream<DTOBaseItem[]>(stream);+ }+ }+/// <summary>/// Gets all Years/// </summary>