On Thu, Feb 23, 2017 at 5:11 PM, mascip <mas...@gmail.com> wrote: > Amazing, thank you James, thank you Micheal, it works! > > In Perl things are often pretty complex, but in this specific case the > code is dead easy: > > my $client = REST::Client->new( > cert => '/path/to/ssl.cert', > key => '/path/to/ssl.key'); > > my $response = $client->POST( > 'https://.../api/certlogin', > 'username=' . $username . '&password=' . $->password); > > > -- Pierre Masci >
Pierre, you might be interested in https://github.com/puppetlabs/clj-http-client. It provides an HTTP client which has an interface like you're describing. The docs appear to be a bit lacking, but you can basically write: (let [client (http/create-client {:ssl-cert "/path/to/ssl.cert" :ssl-key "/path/to/ssl.key" :ssl-ca-cert "/path/to/ssl.cert"})] (http/post client "https://.../api/certlogin")) -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.