{"id":14989986,"url":"https://github.com/scyth3-c/curl-http-wrapper","last_synced_at":"2025-04-12T02:02:20.707Z","repository":{"id":37669342,"uuid":"504964706","full_name":"scyth3-c/curl-http-wrapper","owner":"scyth3-c","description":"make http requests easily in c++ ⚡","archived":false,"fork":false,"pushed_at":"2024-02-25T03:18:06.000Z","size":77,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-05T22:05:31.857Z","etag":null,"topics":["api-client","cpp","cpp20","http","libcurl","library","linux","makefile","requests-module"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/scyth3-c.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-06-18T22:40:09.000Z","updated_at":"2024-06-27T11:57:53.000Z","dependencies_parsed_at":"2024-09-15T17:22:20.287Z","dependency_job_id":null,"html_url":"https://github.com/scyth3-c/curl-http-wrapper","commit_stats":{"total_commits":29,"total_committers":1,"mean_commits":29.0,"dds":0.0,"last_synced_commit":"03ecd830d0ab0802cb258ae45a71d3c78ceb2d7e"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scyth3-c%2Fcurl-http-wrapper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scyth3-c%2Fcurl-http-wrapper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scyth3-c%2Fcurl-http-wrapper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scyth3-c%2Fcurl-http-wrapper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/scyth3-c","download_url":"https://codeload.github.com/scyth3-c/curl-http-wrapper/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248505859,"owners_count":21115354,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api-client","cpp","cpp20","http","libcurl","library","linux","makefile","requests-module"],"created_at":"2024-09-24T14:19:16.810Z","updated_at":"2025-04-12T02:02:20.669Z","avatar_url":"https://github.com/scyth3-c.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n\n![Veridic](https://user-images.githubusercontent.com/52190352/176306430-5ead3b8f-e8ac-48bc-98cd-c89b432f673d.png)\n\n\n\n\n\n\n # prepare, build and run\n \n ```\n   sudo make install\n   \n   make\n   \n   ./bin/bin\n \n ```\n ## basic struct request\n \n ```c++\n //#include \"http/veridic\"\n \n  Veridic Url(\"https://URL\");\n  \n   string data = Url.get();\n   \n   cout \u003c\u003c data;\n  \n ```\n\n\n# curl-http-wrapper\n\nmake http requests easily in c++ using libcurl, contains two modules, raw http and Veridic that wraps the raw giving it even more functions, I recommend using Veridic but if you want you can use raw http but it has certain limitations, such as only making one request per instance which does not happen in Veridic\n\n# modules\n\n- **HTTP RAW (wrap curl)**\n- **VERIDIC (wrap HTTP RAW)**\n\n\n# examples \n  \n  _in main or function etc_\n \n### POST \n\n```C++\n\n  Veridic tasty(\"https://API_name\");\n  \n  POST fields = {\n    \"name: jhon\",\n    \"lastname: doe\"\n  }\n  \n  Headers headers = {\n    \"data: test\",\n    \"example: true\"\n  };\n    \n  tasty.post(fields, headers, \"/user\");\n  tasty.post(fields, \"/users\");\n  tasy.post(fields);\n  \n\n```\n### GET\n\n![get_dos](https://user-images.githubusercontent.com/52190352/174460062-32991239-6da1-43d4-a9ce-80ae3363f332.png)\n\n\n\n## Methods\n\n- POST\n- GET\n- PUT\n- DELETE\n- CUSTM\n\n### example get\n\n\u003cimg src=\"https://user-images.githubusercontent.com/52190352/174459669-46527c3c-8627-4b51-a1f5-ac9597699673.png\" width=\"500px\"/\u003e\n\n\u003cimg src=\"https://github.com/scyth3-c/curl-http-wrapper/assets/52190352/d7708690-b72d-4261-a122-870aaf44cab4.png\" width=\"500px\"/\u003e\n\n### example put\n\n\u003cimg src=\"https://user-images.githubusercontent.com/52190352/174459721-7897687d-14b3-40b6-936b-29dec5589fd9.png\" width=\"500px\"/\u003e\n\n### example delete\n\n\u003cimg src=\"https://user-images.githubusercontent.com/52190352/174459737-1ed37b98-23d0-46ff-bb50-48857096e166.png\" width=\"500px\"/\u003e\n\n### example custom\n\n\u003cimg src=\"https://user-images.githubusercontent.com/52190352/174459753-6037a866-b0c3-4012-89ef-83e08099a178.png\" width=\"500px\"/\u003e\n\n\n## Project and Headers\n\nthe structure is very flexible in case you want to use directly the one I put, as long as you add the .cpp code inside the **src/sources** folder and add it in the **makefile** like this\n\n```php\n  $(DIR_OBJ)/myFile.o\n  \n```\n \n ### FIELDS\n  \n  the fields are a structure in charge of controlling and preparing the necessary parameters for the requests, they have no limit\n \n Examples\n \n ```c++\n in headers fields, DATA: VALUE\n \n  Headers = {\n    \"data: 1\",\n    \"data: 2\",\n    \"data: N\",\n    \"N: N\",\n  };\n \n same that post \u003e\u003e\u003e\n  \n in POST fields, DATa=value\n \n    POST fields = {\n      \"uno=1\",\n      \"dos=2\",\n      \"tres=3\",\n      \"N=N\"\n    };\n    \n    GET fields = {\n      \"uno=1\",\n      \"dos=2\",\n      \"tres=3\",\n      \"N=N\"\n    };\n    \n    PUT fields = {\n      \"uno=1\",\n      \"dos=2\",\n      \"tres=3\",\n      \"N=N\"\n    };\n    \n    DELETE fields = {\n      \"uno=1\",\n      \"dos=2\",\n      \"tres=3\",\n      \"N=N\"\n    };\n    \n \n ```\n\n ### the fields\n \n the fields are the same structure but with a typedef to make the code easier to read, the only difference is the field Headers, which has another structure\n  \n  ### other media\n  \n  \n![veridic](https://user-images.githubusercontent.com/52190352/174459626-1684c6ab-8957-4a14-a7c9-f5ee421f739c.png)\n\n \n \n \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscyth3-c%2Fcurl-http-wrapper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fscyth3-c%2Fcurl-http-wrapper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscyth3-c%2Fcurl-http-wrapper/lists"}