Re: How do I read HTTP body while using web.l

2019-05-15 Thread Alexander Burger
Hi Kashyap, > While my question was about the server side - it is super cool to learn > about "ssl" - although I am curious - was there a reason why "POST" was > left out of it? Good question! To be true, 'ssl' serves mainly other purposes (running as a daemon synchronizing databases), and the

Re: How do I read HTTP body while using web.l

2019-05-15 Thread C K Kashyap
Hey Alex, While my question was about the server side - it is super cool to learn about "ssl" - although I am curious - was there a reason why "POST" was left out of it? Also I agree about the point of parsing a program generated JSON looks like an overkill is many cases. Hey Andreas - I dont

Re: How do I read HTTP body while using web.l

2019-05-15 Thread Alexander Burger
Hi Andreas, > Web.l is a server-side framework. > ... Thanks! I've seen it, but never found the time to study it :) ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe

Re: How do I read HTTP body while using web.l

2019-05-15 Thread Alexander Burger
On Wed, May 15, 2019 at 09:18:47AM +0200, Alexander Burger wrote: > (from "\"EUR\"") > (from "\"last\" : ") > (read) ) Just for completeness: In the real case, I do not use 'read' as above. I handle our long-discussed fixpoint issue this way: (from "\"EUR\"") (from

Re: How do I read HTTP body while using web.l

2019-05-15 Thread andreas
Hi Alex, Web.l is a server-side framework. This thread is about how to handle a uploaded JSON file I believe, not about consuming a JSON/REST API as a client. Web.l is an alternative to the picolisp standard GUI framework form.l. I can recommend web.l for people learning how to implement a

Re: How do I read HTTP body while using web.l

2019-05-15 Thread Alexander Burger
On Wed, May 15, 2019 at 09:08:44AM +0200, Alexander Burger wrote: >(in '("@bin/ssl" "blockchain.info" 443 "de/ticker") > (while (line)) # Skip header > (readJson) ) Having discussed about Json all the time, let me say that in fact I never used 'readJson' etc. I feel it is

Re: How do I read HTTP body while using web.l

2019-05-15 Thread Alexander Burger
Hi Andreas, On Wed, May 15, 2019 at 08:27:19AM +0200, andr...@itship.ch wrote: > In web.l framework, you you define a request handler using (dh). I do not know the web.l framework, but like to add that using either 'client' (from "@lib/http.l") or @bin/ssl is a bit simpler. 'client' can handle

Re: How do I read HTTP body while using web.l

2019-05-15 Thread andreas
Hi Kashyap In web.l framework, you you define a request handler using (dh). When a http request is received by the (server) function (in web.l/http.l), it gets handed to the (http) function (defined in web.l/http.l). Now (http) is parsing the complete HTTP request before calling (req-handler)