[sr-dev] http_query/Curl Async Module : custom http headers feature request

Olle E. Johansson oej at edvina.net
Wed Jan 27 14:56:02 CET 2016


> On 27 Jan 2016, at 14:53, Tim Chubb <tim.chubb at voicesimplified.com> wrote:
> 
> Hi 
>  
> Would it be possible to have a means of specifying additional request headers, i.e. things like the Authorization header, so that you would be able to make use of services which use a token based AAA system such as OAuth.
> From the cli its trivial to invoke curl with additional headers i.e. if I was to query such a service it would simply be something like this:
> curl --header "Authorization: Bearer <token>" https://<uri <https://%3curi/>>
>  
> Ideally having an optional parameter on http_request/curl_http_request where you could provide a delimited string of additional headers, as without that sort of functionality the usefulness of http requests is pretty limited against modern web services.  If this is already possible could someone guide me to the documentation which documents this ability?

I don’t think that exists today, but it is a very good idea and clearly possible in Curl.

We just need the code for it :-)

Best regards,
/Olle


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-dev/attachments/20160127/4107b295/attachment.html>


More information about the sr-dev mailing list