public override LoadRequest GetLoadRequest(ShelfLoadContext loadContext, Type objectType) { //var request = new RestSharpLoadRequest( // loadContext, // GoodreadsClient.Current.BuildResource("review/list/{id}.xml"), // GoodreadsClient.Current.ConsumerKey, // GoodreadsClient.Current.ConsumerSecret, // GoodreadsClient.Current.AccessToken, // GoodreadsClient.Current.AccessTokenSecret); //request.AddUrlSegment("id", loadContext.UserId); var request = new RestSharpLoadRequest( loadContext, GoodreadsClient.Current.BuildResource("review/list/{id}.xml")); request.AddUrlSegment("id", loadContext.UserId); request.AddParameter("key", GoodreadsClient.Current.ConsumerKey); request.AddParameter("shelf", loadContext.ShelfName); request.AddParameter("v", "2"); //request.AddParameter("id", loadContext.UserId); request.AddParameter("page", loadContext.Page.ToString()); return(request); }
public override LoadRequest GetLoadRequest(IdLoadContext loadContext, System.Type objectType) { var request = new RestSharpLoadRequest( loadContext, GoodreadsClient.Current.BuildResource(String.Format("book/show/{0}", loadContext.Id))); request.AddParameter("format", "xml"); request.AddParameter("key", GoodreadsClient.Current.ConsumerKey); return(request); }
public override LoadRequest GetLoadRequest(IdLoadContext loadContext, Type objectType) { var request = new RestSharpLoadRequest( loadContext, GoodreadsClient.Current.BuildResource("shelf/list.xml")); request.AddParameter("key", GoodreadsClient.Current.ConsumerKey); request.AddParameter("user_id", loadContext.Id); return(request); }
public override LoadRequest GetLoadRequest(UserReviewLoadContext loadContext, Type objectType) { var request = new RestSharpLoadRequest( loadContext, GoodreadsClient.Current.BuildResource("review/show_by_user_and_book.xml")); request.AddParameter("key", GoodreadsClient.Current.ConsumerKey); request.AddParameter("user_id", loadContext.UserId); request.AddParameter("book_id", loadContext.BookId); return(request); }
public override LoadRequest GetLoadRequest(IdLoadContext loadContext, Type objectType) { var request = new RestSharpLoadRequest( loadContext, GoodreadsClient.Current.BuildResource("updates/friends.xml"), GoodreadsClient.Current.ConsumerKey, GoodreadsClient.Current.ConsumerSecret, GoodreadsClient.Current.AccessToken, GoodreadsClient.Current.AccessTokenSecret); return(request); }