public static BestSellersListNames GetNytBestSellersListNames() { BestSellersListNames bs = null; string res = String.Empty; using (WebParser wp = new WebParser(cStrNYTBooksBaseUrl)) { res = wp.Request(cStrNYTBooksResource, Method.GET, cStrNYTApiKeyStr, cStrNYTApiKeyVal); bs = wp.DeserializeJson <BestSellersListNames>(res); } return(bs); }
public static BestSellersListNames GetNYTBestSellersListNames() { BestSellersListNames bs = null; try { using (WebParser wp = new WebParser(cStrNYTBooksBaseUrl)) { string res = wp.Request(cStrNYTBooksResource, Method.GET, cStrNYTApiKeyStr, cStrNYTApiKeyVal); bs = wp.DeserializeJson <BestSellersListNames>(res); } } catch (Exception ex) { Console.WriteLine(ex.ToString()); } return(bs); }
public static string GetRawNYTBestSellersListNames() { string res = String.Empty; try { using (WebParser wp = new WebParser(cStrNYTBooksBaseUrl)) { res = wp.Request(cStrNYTBooksResource, Method.GET, cStrNYTApiKeyStr, cStrNYTApiKeyVal); Console.WriteLine(res); } } catch (Exception ex) { Console.WriteLine(ex.ToString()); } return(res); }