curl / Mailing Lists / curl-users / Single Mail

curl-users

Re: json awareness ?

From: <lars_at_bombocla.at>
Date: Sun, 24 Sep 2017 13:58:32 +0200

> I'm not really much of a heavy json user myself, but I created a wiki
> page for
> collecting ideas and allow brainstorming arund what improve json
> support in
> curl *might* be!

Hey,

I don't know if this is the proper way to respond,
first time using a mailing list :D

My current use of curl is to get json data from a hit rate limited API.
I can limit the bandwidth usage but not how many requests per x time
from a list of urls.
So for now I have to use libcurl to do this type of rate limiting
outside of curl.

Another way of JSON awareness could be providing the headers in JSON
format.
For example the combined output of headers and body would look something
like this:

{
   "headers": [
     {
       "Content-Type": "application/json"
     },
     {
       "etc": "etc"
     }
   ]
}
{"example": "json_answer"}

This can be read by jq directly and then used to process the data
differently.

lars
-----------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-users
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2017-09-24