Skip to content

c/c++ Single header HTTP/s implementation win/unix

Notifications You must be signed in to change notification settings

ABDO10DZ/nativeHTTP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

nativeHTTP

native C/C++ single header for Win/Unix implementation for http/s connections

  • example :
	nativeHTTP::Request req;
	std::string myip = req.sendReq(L"https://www.myexternalip.com/raw").response;
	std::cout << "my ip is :" << myip << "\n";
  • example on json post :
        std::string JsonData = "{\"ab\":10}";
        req.sendReq(L"https://ptsv2.com/t/66j3d-1668215687/post", "POST", "{\"ab\":10}");
	/* json post ab = 10 - test room:https://ptsv2.com/t/66j3d-1668215687/d/4687238942162944 */
  • POST other methods ?
    if wanna application/x-www-form-urlencoded, multipart/form-data, or text/plain..etc edit line nativehttp:258
  • HTTP/S mode ?
    to connect through http instead of https remove the SECURE flag defined in or use NULL instead nativehttp:217

    #next
    *add cookies support
    *add full support unicode
    *add file upload post data with easy usage (mutipart file upload .. etc)
    *add switch btw json post and other post requests
    *add winhttp support
    *add unix support

About

c/c++ Single header HTTP/s implementation win/unix

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages