Shawn Shawn’s Comments (group member since Dec 16, 2010)


Shawn’s comments from the Goodreads Developers group.

Showing 1-20 of 23
« previous 1

Jul 11, 2013 11:27AM

8095 I'm assuming this is a new change then since this has been working as is for a long time now?
Jul 07, 2013 03:12PM

8095 Yup, same here.
May 28, 2012 04:58PM

8095 Awesome! I've been working on my WP Goodreads client for ages but never quite finish it so glad to see this actually hit the Marketplace. I'll definitely give it a try.
OAuth details (8 new)
Mar 04, 2012 07:18PM

8095 Hey Tim, fancy seeing you around here :) Ping me if you want my Goodreads OAuth sample code. I'm writing a WP7 Goodreads client and I've worked out most of the kinks with using RestSharp + GoodReads. Are you doing a W8 version or WP7 as well?

I'm thinking of pushing my client up on Github so everyone can learn from it and tweak it. I hope to publish v1 in a week with a basic feature set.
Mar 04, 2012 07:06PM

8095 Hey Karsten, let me know if you run into any other .NET issue with the Goodreads API, I'm also writing a WP7 Goodreads client and I've worked out most of the kinks in calling the API. Also I'd recommend grabbing the RestSharp library, it makes the whole OAuth and REST calls a snap.
Mar 04, 2012 07:03PM

8095 Agreed, at this point people would probably break people all over the place :) I wrote a wee bit of code to parse it correctly for my app but I'd never seen it before. Thanks.
Feb 23, 2012 05:45PM

8095 I noticed in review/list.xml some of the date/times are in a format I don't recognize:

started_at: Sat Feb 18 20:04:08 -0800 2012
date_added: Sat Feb 18 20:04:08 -0800 2012
date_updated: Sat Feb 18 20:04:08 -0800 2012

The strangest thing is the year at the end instead of after the day, not sure I've seen that format before.

I see in other areas though, such as notifications, where it appears in a format I expect (and thus can use a canned parsing routine):

created_at: 2012-02-22T08:30:36-08:00

Anyone know if the first group of date/times is a standard format?

Thanks
Feb 21, 2012 07:17PM

8095 Ah bummer, I really like the look of the GoodReads home page with all your books and their latest status on the right side and I'm recreating it.

I'll just issue a separate show_by_user_and_book for each book and see what that does to perf. I'm caching pretty heavily so hopefully it won't be too bad.

Thanks
Feb 20, 2012 06:18PM

8095 On the main page of my app I'm showing a list of all the books the user is reading and their progress. Right now that results in 1 + N web requests, something like this:

1 call to review/list.xml to get the list of the books on a users "currently-reading" shelf.

N calls for each book to review/show_by_user_and_book.xml

Is there a better way to get what percentage complete a user is on each of their books?

Thanks
8095 Thanks Michael, trying to figure out which one to display in my app (I promise it'll be out soon so all my annoying questions will actually have a purpose :))

If you're in there making formats match there are a few other fields that are sometimes CDATA other times attributed that I've noticed.
8095 I'm curious what's the difference between these:





And:



333



1. First why are they different numbers? Is one the total number of reviews across all versions (hardback, paperback, different covers, etc.?) and the other is for that exact edition?

2. Why is one CDATA and the other has embedded type info (the integer attribute)?

Which # is used in the average rating calculation?

Thanks
Feb 06, 2012 03:10PM

8095 Hey Gregg did you ever figure this out? I'm running into the same situation, I have everything else working and I thought this would be a slam dunk but it didn't work for me.
Feb 01, 2012 04:39PM

8095 Thanks, I saw it awhile back and they're generating the call by hand without using a library and they're not using OAuth so it wasn't as helpful as I hoped.

For any other .NET developer that may stumble on this that are using the REST library Hammock (https://github.com/danielcrenna/hammock) it appears the square bracket param issue is known: (https://github.com/danielcrenna/hammo...). The dev had to change how he encoded params to work around how Twitter was interpreting the OAuth spec so that could be the source of pain.

I didn't apply the patch to verify but I did change to another lib, RestSharp (https://github.com/restsharp/RestSharp), and that works perfectly. I still want to fix up Hammock as there are some aspects of that library I like better but at least now I have a working vs. non-working sample to play with.

Thanks everyone for the pointers and help, greatly appreciated! I also plan to make my GoodReads lib open source and I'll throw it up on github once it's a little more tidy so at least people have a working example.
Jan 31, 2012 04:48PM

8095 Thanks for the reference, I'm digging through the Java now and trying to determine where the differences are. If I can just get these last calls working I'll be rocking on my app.
Jan 31, 2012 11:32AM

8095 Thanks Michael, it looks like I'm going to have to be the one that patches this particular library. I'm debating writing a quick and dirty request in Ruby just to inspect the request with the exact same params to see where the difference is.

Like Gregg mentioned every other request seems to work, the only ones that don't work for me are those with square brackets so I feel I'm close.

I remember hearing about an open source .NET API but a wee bit of searching hasn't turned it up. I'll dig again.
Jan 30, 2012 06:56PM

8095 I think I'm running into the square brackets issue when issuing my user_shelves.xml POST requests as I keep getting "not authorized" and I'm starting to beat my head against a wall. Add a friend works as does basic GETs using OAuth.

I'm using the .NET library Hammock to generate my requests and everything looks fine from a call perspective but then again I don't know what the square bracket issue is and what the GoodReads server expects.

The full request is (with consumer key obviously changed):

POST http://www.goodreads.com/user_shelves... HTTP/1.1
Accept: */*
Referer: file:///Applications/Install/3D67A276...
Content-Length: 24
Accept-Encoding: identity
Authorization: OAuth oauth_consumer_key="XXXXXXXXXXXXXXXXXXXXX",oauth_nonce="hef5vcmu5mw6qg2n",oauth_signature="apfIcMc4%2B4Hc2%2F60HVezOSYtdYI%3D",oauth_signature_method="HMAC-SHA1",oauth_timestamp="1327977976",oauth_token="hTZqHVG5nliRXG5SZtc6jA",oauth_version="1.0"
Content-Type: application/x-www-form-urlencoded
User-Agent: NativeHost
Host: www.goodreads.com
Proxy-Connection: Keep-Alive
Cache-Control: no-cache
Pragma: no-cache

user_shelf%5Bname%5D=buy
Jan 20, 2012 04:37PM

8095 That has a pretty funky code smell :)

I fully support the idea of smaller payloads but from everything I know of API design it's a bit confusing that when all you change is the message format you end up with different content. Most web sites that allow a variety of response formats don't change the actual content, just the packaging.

If the goal is to offer developers a way to get just the embed code why not add that as a param or a new resource (in REST speak), say book.widget? That way devs don't have to context switch back and forth between JSON or XML?

As a consolation prize can the help be updated to reflect this behavior?
Jan 19, 2012 09:46PM

8095 The json response from book.show returns only the widget while the xml returns much more. I'm assuming that the API is in flux due to yanking reviews from all the responses? I'm really hoping to use the JSON version instead of XML and would love to see the same data in both responses.

Here is the link I'm hitting:
http://www.goodreads.com/book/show?fo...

Thanks
Feb 20, 2011 10:04PM

8095 Reading the API descriptions I can't seem to find the API that returns the current page/percentage a user is on.
Feb 20, 2011 10:03PM

8095 I'm seeing the same thing with one of my books. I know I can work around it but it really should be spitting out the correct UTF-8 encoding. Any chance of getting this addressed?
« previous 1