[drakma-devel] Handling chunked content

Nico Garcia Belmonte philogb at gmail.com
Thu Jun 5 00:43:48 UTC 2008


Hi,

...I'm kind of a newbie, so please forgive me if I make stupid questions.
I've been using drakma to request html pages and everything seems to work
fine.

I'm now using drakma to make a request to the new youtube json api, and I
get chunked content:

(http-request "
http://gdata.youtube.com/feeds/api/videos/-/Music/?max-results=10&vq=bush&alt=json&format=5
")

...chunked content...

((:CONTENT-TYPE . "application/json; charset=UTF-8")
 (:CACHE-CONTROL . "max-age=0, must-revalidate, no-transform, private")
 (:GDATA-VERSION . "1.0") (:LAST-MODIFIED . "Thu, 05 Jun 2008 00:20:27 GMT")
 (:TRANSFER-ENCODING . "chunked") (:DATE . "Thu, 05 Jun 2008 00:20:27 GMT")
 (:SERVER . "GFE/1.3") (:CONNECTION . "Close"))
#<PURI:URI
http://gdata.youtube.com/feeds/api/videos/-/Music/?max-results=10&vq=bush&alt=json&format=5
>
#<FLEXI-STREAMS:FLEXI-IO-STREAM {B90E249}>

The thing is that I need it to be a string in order to decode to json format
using the cl-json lisp package.
I tried changing the external-output parameter without any good results.

Do you have some advice on how I could serialize this content?

Thanks at advanced!

Your library is great!

Nico.

-- 
I would never die for my beliefs because I might be wrong.

Bertrand Russell
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/drakma-devel/attachments/20080605/47a1bee6/attachment.html>


More information about the Drakma-devel mailing list