Please see https://github.com/google/brotli for more detail.Compress request body on clientcli.set_compress(true); res = cli.Post("/resource/foo", "...", "text/plain");Compress response body on clientcli.set_decompress(false); res = cli.Get(...
cpp-httplib A C++ single-file header-only cross platform HTTP/HTTPS library. It's extremely easy to setup. Just includehttplib.hfile in your code! Server Example #include<httplib.h>intmain(void) {usingnamespacehttplib;Server svr; svr.Get("/hi", [](constRequest& req, Response& res) { ...
Please see https://github.com/google/brotli for more detail.Compress request body on clientcli.set_compress(true); res = cli.Post("/resource/foo", "...", "text/plain");Compress response body on clientcli.set_decompress(false); res = cli.Get(...
Brotli compression is available withCPPHTTPLIB_BROTLI_SUPPORT. Necessary libraries should be linked. Please seehttps://github.com/google/brotlifor more detail. cli.set_decompress(false); res = cli.Get("/resource/foo", {{"Accept-Encoding","gzip, deflate, br"}}); res->body;//Compressed data...
README.md appveyor.yml httplib.h A C++ single-file header-only cross platform HTTP/HTTPS library. It's extremely easy to setup. Just includehttplib.hfile in your code! Server Example #include<httplib.h>intmain(void) {usingnamespacehttplib;Server svr; svr.Get("/hi", [](constRequest& re...
Please see https://github.com/google/brotli for more detail.Compress request body on clientcli.set_compress(true); res = cli.Post("/resource/foo", "...", "text/plain");Compress response body on clientcli.set_decompress(false); res = cli.Get(...
#define CPPHTTPLIB_OPENSSL_SUPPORT #include "path/to/httplib.h" // HTTP httplib::Client cli("http://yhirose.github.io"); // HTTPS httplib::Client cli("https://yhirose.github.io"); auto res = cli.Get("/hi"); res->status; res->body;...
Please see https://github.com/google/brotli for more detail.Compress request body on clientcli.set_compress(true); res = cli.Post("/resource/foo", "...", "text/plain");Compress response body on clientcli.set_decompress(false); res = cli.Get(...
#define CPPHTTPLIB_OPENSSL_SUPPORT #include "path/to/httplib.h" // HTTP httplib::Client cli("http://cpp-httplib-server.yhirose.repl.co"); // HTTPS httplib::Client cli("https://cpp-httplib-server.yhirose.repl.co"); auto res = cli.Get("/hi"); res->status; res->body;...
Please see https://github.com/google/brotli for more detail.Compress request body on clientcli.set_compress(true); res = cli.Post("/resource/foo", "...", "text/plain");Compress response body on clientcli.set_decompress(false); res = cli.Get(...