Goodreads Developers discussion
questions
>
Add book shelf
date
newest »


The problem is probably the square brackets. If you search the group you'll find others that may have a solution for making it work with PHP (if I recall that's what you're using) or, client side, with whatever you are using to send the request.

If I am interpreting you correctly I need to NOT URL encode the parameters, and pass the actual brackets, correct? I wonder if I can force my library to do that...

No, I didn't mean that. What I meant is that I know square brackets have caused a few issues to some, and how to solve them depends on the actual technology you are using to execute the request. Searching the forum might provide some insights.


Either there's a bug or the API documentation is wrong.




I can add a shelf, but none of the options (e.g. featured) get changed, they always end up 'false'
I can edit a shelf, and change any of those same options, so I know that API can handle the options ok.
Since the documented syntax for both API's is the same, I have to presume it's a problem with the add API.
I can add a book shelf successfully (in fact easier than I expected).
But I can't get the options to work.
My second try was to delete then add the same book shelf with all the options set to 'true'. Checking on the site shows they are all not checked, indicating to me they didn't set.
Request was
POST /user_shelves.xml HTTP/1.0 Host: www.goodreads.com User-Agent: Drupal (+http://drupal.org/) Content-Length: 142 Authorization: OAuth oauth_version="1.0",oauth_nonce="c4c0cc6ab8b86cf1a7befd39a3a8e46a",oauth_timestamp="1327442799",oauth_consumer_key="KEY",oauth_token="TOKEN",oauth_signature_method="HMAC-SHA1",oauth_signature="wLqw129ohqwLUngkTxSjsnXuDUY%3D" user_shelf%5Bname%5D=OAuth%20Test%20Shelf&user_shelf%5Bfeatured%5D=true&user_shelf%5Bexclusive_flag%5D=true&user_shelf%5Bsortable_flag%5D=true
Also on the book shelf page there are two other options, sticky and recs that aren't listed in the API documentation. Any reason they aren't included?