On 20.09.2011 13:01, Sven Van Caekenberghe wrote:
Olivier,
On 20 Sep 2011, at 12:32, Olivier Auverlot wrote:
Hi,
I try to write a client to www.jamendo.com with Zinc. Jamendo has a REST API to request the music catalog. It's a fun workshop to discover Zinc :-)
If I use the url " ZnClient get: 'http://api.jamendo.com/get2/name+url/album/xml" in my browser, I get the list of the last entries. But, if I do the same with Zinc, I get an error.
ZnClient get: 'http://api.jamendo.com/get2/name+url/album/xml'
The error is: "MessageNotUnderstood: Array>>peekFor:"
I think that the problem can be the URL rewriting. Maybe Zinc can't follow the link ?
Thanks for your help.
Olivier ;-) www.auverlot.fr Yes, REST API's are nice to play with and Zn should definitively be able to work with any of them.
The strange thing is that this server returns headers that don't look right to me:
Content-Length: 449, 449
or
Content-Length: 0, 0
I have never seen this before, but I will have to check the standard documents before I known what to do.
I will let you know.
http://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html#sec4 "Multiple message-header fields with the same field-name MAY be present in a message if and only if the entire field-value for that header field is defined as a comma-separated list [i.e., #(values)]. " Content-Length = "Content-Length" ":" 1*DIGIT So technically, they're doing something illegal :) Cheers, Henry