{:group-id "org.babashka", :artifact-id "http-client", :version "0.4.19", :analysis {"clj" ({:name babashka.http-client, :publics ({:name ->Authenticator, :file "babashka/http_client.clj", :line 36, :arglists ([opts]), :doc "Constructs a `java.net.Authenticator`.\n\nOptions:\n\n* `:user` - the username\n* `:pass` - the password", :type :var} {:name ->CookieHandler, :file "babashka/http_client.clj", :line 46, :arglists ([opts]), :doc "Constructs a `java.net.CookieHandler` using `java.net.CookieManager`.\n\nOptions:\n\n* `:store` - an optional `java.net.CookieStore` implementation\n* `:policy` - a `java.net.CookiePolicy` or one of `:accept-all`, `:accept-none`, `:original-server`", :type :var} {:name ->Executor, :file "babashka/http_client.clj", :line 66, :arglists ([opts]), :doc "Constructs a `java.util.concurrent.Executor`.\n\nOptions:\n\n* `:threads` - constructs a `ThreadPoolExecutor` with the specified number of threads", :type :var} {:name ->ProxySelector, :file "babashka/http_client.clj", :line 9, :arglists ([opts]), :doc "Constructs a `java.net.ProxySelector`.\nOptions:\n* `:host` - string\n* `:port` - long", :type :var} {:name ->SSLContext, :file "babashka/http_client.clj", :line 17, :arglists ([opts]), :doc "Constructs a `javax.net.ssl.SSLContext`.\n\nOptions:\n\n* `:key-store` - a file, URI or URL or anything else that is compatible with `io/input-stream`, e.g. (io/resource somepath.p12)\n* `:key-store-pass` - the password for the keystore\n* `:key-store-type` - the type of keystore to create [note: not the type of the file] (default: pkcs12)\n* `:trust-store` - a file, URI or URL or anything else that is compatible with `io/input-stream`, e.g. (io/resource somepath.p12)\n* `:trust-store-pass` - the password for the trust store\n* `:trust-store-type` - the type of trust store to create [note: not the type of the file] (default: pkcs12)\n* `:insecure` - if `true`, an insecure trust manager accepting all server certificates will be configured.\n\nNote that `:keystore` and `:truststore` can be set using the\n`javax.net.ssl.keyStore` and `javax.net.ssl.trustStore` System\nproperties globally.", :type :var} {:name ->SSLParameters, :file "babashka/http_client.clj", :line 56, :arglists ([opts]), :doc "Constructs a `javax.net.ssl.SSLParameters`.\n\nOptions:\n\n* `:ciphers` - a list of cipher suite names\n* `:protocols` - a list of protocol names", :type :var} {:name client, :file "babashka/http_client.clj", :line 75, :arglists ([opts]), :doc "Construct a custom client. To get the same behavior as the (implicit) default client, pass `default-client-opts`.\n\nOptions:\n* `:follow-redirects` - `:never`, `:always` or `:normal`\n* `:connect-timeout` - connection timeout in milliseconds.\n* `:request` - default request options which will be used in requests made with this client.\n* `:executor` - a `java.util.concurrent.Executor` or a map of options, see docstring of `->Executor`\n* `:ssl-context` - a `javax.net.ssl.SSLContext` or a map of options, see docstring of `->SSLContext`.\n* `:ssl-parameters` - a `javax.net.ssl.SSLParameters' or a map of options, see docstring of `->SSLParameters`.\n* `:proxy` - a `java.net.ProxySelector` or a map of options, see docstring of `->ProxySelector`.\n* `:authenticator` - a `java.net.Authenticator` or a map of options, see docstring of `->Authenticator`.\n* `:cookie-handler` - a `java.net.CookieHandler` or a map of options, see docstring of `->CookieHandler`.\n* `:version` - the HTTP version: `:http1.1` or `:http2`.\n* `:priority` - priority for HTTP2 requests, integer between 1-256 inclusive.\n\nReturns map with:\n\n* `:client` - a `java.net.http.HttpClient`.\n\nThe map can be passed to `request` via the `:client` key.\n", :type :var} {:name default-client-opts, :file "babashka/http_client.clj", :line 5, :doc "Options used to create the (implicit) default client.\n", :type :var} {:name delete, :file "babashka/http_client.clj", :line 134, :arglists ([uri] [uri opts]), :doc "Convenience wrapper for `request` with method `:delete`\n", :type :var} {:name get, :file "babashka/http_client.clj", :line 127, :arglists ([uri] [uri opts]), :doc "Convenience wrapper for `request` with method `:get`\n", :type :var} {:name head, :file "babashka/http_client.clj", :line 141, :arglists ([uri] [uri opts]), :doc "Convenience wrapper for `request` with method `:head`\n", :type :var} {:name patch, :file "babashka/http_client.clj", :line 155, :arglists ([url] [url opts]), :doc "Convenience wrapper for `request` with method `:patch`\n", :type :var} {:name post, :file "babashka/http_client.clj", :line 148, :arglists ([uri] [uri opts]), :doc "Convenience wrapper for `request` with method `:post`\n", :type :var} {:name put, :file "babashka/http_client.clj", :line 164, :arglists ([url] [url opts]), :doc "Convenience wrapper for `request` with method `:put`\n", :type :var} {:name request, :file "babashka/http_client.clj", :line 100, :arglists ([opts]), :doc "Perform request. Returns map with at least `:body`, `:status`\n\nOptions:\n\n* `:uri` - the uri to request (required).\n May be a string or map of `:scheme` (required), `:host` (required), `:port`, `:path` and `:query`\n* `:headers` - a map of headers\n* `:method` - the request method: `:get`, `:post`, `:head`, `:delete`, `:patch` or `:put`\n* `:interceptors` - custom interceptor chain\n* `:client` - a client as produced by `client` or a clojure function. If not provided a default client will be used.\n When providing :client with a a clojure function, it will be called with the Clojure representation of\n the request which can be useful for testing.\n* `:query-params` - a map of query params. The values can be a list to send multiple params with the same key.\n* `:form-params` - a map of form params to send in the request body.\n* `:body` - a file, inputstream or string to send as the request body.\n* `:basic-auth` - a sequence of `user` `password` or map with `:user` `:pass` used for basic auth.\n* `:oauth-token` - a string token used for bearer auth.\n* `:async` - perform request asynchronously. The response will be a `CompletableFuture` of the response map.\n* `:async-then` - a function that is called on the async result if successful\n* `:async-catch` - a function that is called on the async result if exceptional\n* `:timeout` - request timeout in milliseconds\n* `:throw` - throw on exceptional status codes, all other than `#{200 201 202 203 204 205 206 207 300 301 302 303 304 307}`\n* `:version` - the HTTP version: `:http1.1` or `:http2`.", :type :var})} {:name babashka.http-client.interceptors, :publics ({:name accept-header, :file "babashka/http_client/interceptors.clj", :line 72, :doc "Request: adds `:accept` header. Only supported value is `:json`.\n", :type :var} {:name basic-auth, :file "babashka/http_client/interceptors.clj", :line 46, :doc "Request: adds `:authorization` header based on `:basic-auth` (a map\nof `:user` and `:pass`) in request.", :type :var} {:name construct-uri, :file "babashka/http_client/interceptors.clj", :line 222, :doc "Request: construct uri from map\n", :type :var} {:name decode-body, :file "babashka/http_client/interceptors.clj", :line 208, :doc "Response: based on the value of `:as` in request, decodes as `:string`, `:stream` or `:bytes`. Defaults to `:string`.\n", :type :var} {:name decompress-body, :file "babashka/http_client/interceptors.clj", :line 194, :doc "Response: decompresses body based on \"content-encoding\" header. Valid values: `gzip` and `deflate`.\n", :type :var} {:name default-interceptors, :file "babashka/http_client/interceptors.clj", :line 256, :doc "Default interceptor chain. Interceptors are called in order for request and in reverse order for response.\n", :type :var} {:name form-params, :file "babashka/http_client/interceptors.clj", :line 140, :doc "Request: encodes `:form-params` map and adds `:body`.\n", :type :var} {:name multipart, :file "babashka/http_client/interceptors.clj", :line 244, :doc "Adds appropriate body and header if making a multipart request.\n", :type :var} {:name oauth-token, :file "babashka/http_client/interceptors.clj", :line 59, :doc "Request: adds `:authorization` header based on `:oauth-token` (a string token)\nin request.", :type :var} {:name query-params, :file "babashka/http_client/interceptors.clj", :line 118, :doc "Request: encodes `:query-params` map and appends to `:uri`.\n", :type :var} {:name throw-on-exceptional-status-code, :file "babashka/http_client/interceptors.clj", :line 233, :doc "Response: throw on exceptional status codes\n", :type :var} {:name unexceptional-statuses, :file "babashka/http_client/interceptors.clj", :line 230, :type :var} {:name uri-with-query, :file "babashka/http_client/interceptors.clj", :line 102, :arglists ([uri new-query]), :doc "We can't use the URI constructor because it encodes all arguments for us.\nSee https://stackoverflow.com/a/77971448/6264", :type :var})} {:name babashka.http-client.websocket, :publics ({:name abort!, :file "babashka/http_client/websocket.clj", :line 61, :arglists ([ws]), :doc "Closes this WebSocket's input and output abruptly.\n", :type :var} {:name close!, :file "babashka/http_client/websocket.clj", :line 53, :arglists ([ws] [ws status-code reason]), :doc "Initiates an orderly closure of this WebSocket's output by sending a\nClose message with the given status code and the reason.", :type :var} {:name ping!, :file "babashka/http_client/websocket.clj", :line 43, :arglists ([ws data]), :doc "Sends a Ping message with bytes from the given buffer.\n", :type :var} {:name pong!, :file "babashka/http_client/websocket.clj", :line 48, :arglists ([ws data]), :doc "Sends a Pong message with bytes from the given buffer.\n", :type :var} {:name send!, :file "babashka/http_client/websocket.clj", :line 32, :arglists ([ws data] [ws data opts]), :doc "Sends a message to the WebSocket.\n`data` can be a CharSequence (e.g. string), byte array or ByteBuffer\n\nOptions:\n* `:last`: this is the last message, defaults to `true`", :type :var} {:name websocket, :file "babashka/http_client/websocket.clj", :line 10, :arglists ([{:keys [client], :as opts}]), :doc "Builds `java.net.http.Websocket` client.\n* `:uri` - the uri to request (required).\n May be a string or map of `:schema` (required), `:host` (required), `:port`, `:path` and `:query`\n* `:headers` - a map of headers for the initial handshake`\n* `:client` - a client as produced by `client`. If not provided a default client will be used.\n* `:connect-timeout` Sets a timeout for establishing a WebSocket connection (in millis).\n* `:subprotocols` - sets a request for the given subprotocols.\n* `:async` - return `CompleteableFuture` of websocket\n\nCallbacks options:\n* `:on-open` - `[ws]`, called when a `WebSocket` has been connected.\n* `:on-message` - `[ws data last]` A textual/binary data has been received.\n* `:on-ping` - `[ws data]` A Ping message has been received.\n* `:on-pong` - `[ws data]` A Pong message has been received.\n* `:on-close` - `[ws status reason]` Receives a Close message indicating the WebSocket's input has been closed.\n* `:on-error` - `[ws err]` An error has occurred.", :type :var}), :doc "Code is very much based on hato's websocket code. Credits to @gnarroway!\n"} {:name scratch, :publics ()})}, :pom-str "\n\n 4.0.0\n jar\n org.babashka\n http-client\n 0.4.19\n http-client\n \n \n org.clojure\n clojure\n 1.11.1\n \n \n \n src\n \n \n \n clojars\n https://repo.clojars.org/\n \n \n \n \n MIT License\n https://opensource.org/license/mit/\n \n \n\n"}