From 55d2b7526ea4b75b8b1beff6c099b304a1916c4e Mon Sep 17 00:00:00 2001 From: Stefan Boberg Date: Mon, 13 Sep 2021 21:44:38 +0200 Subject: Added client implementation of CbPackage filter/transact --- zenhttp/include/zenhttp/httpclient.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'zenhttp/include') diff --git a/zenhttp/include/zenhttp/httpclient.h b/zenhttp/include/zenhttp/httpclient.h index 10829a58c..8975f6fe1 100644 --- a/zenhttp/include/zenhttp/httpclient.h +++ b/zenhttp/include/zenhttp/httpclient.h @@ -4,6 +4,9 @@ #include "zenhttp.h" +#include +#include + #include // For some reason, these don't seem to stick, so we disable the warnings @@ -27,7 +30,14 @@ public: HttpClient(std::string_view BaseUri); ~HttpClient(); - void TransactPackage(std::string_view Url, CbPackage Package); + struct Response + { + int StatusCode = 0; + IoBuffer ResponsePayload; + }; + + [[nodiscard]] Response TransactPackage(std::string_view Url, CbPackage Package); + [[nodiscard]] Response Delete(std::string_view Url); private: std::string m_BaseUri; -- cgit v1.2.3