This commit is contained in:
trickster0
2021-09-27 19:04:20 +03:00
parent 026c5fd41f
commit 8bb1f90d08
8 changed files with 130 additions and 0 deletions
+9
View File
@@ -0,0 +1,9 @@
[package]
name = "http-https-requests"
version = "0.1.0"
edition = "2018"
author = "trickster0"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
reqwest = {version = "0.11.4", features = ["blocking"]}
+14
View File
@@ -0,0 +1,14 @@
extern crate reqwest;
fn main() {
let client = reqwest::blocking::Client::builder().danger_accept_invalid_certs(true).build().unwrap();
let _response = client.post("https://google.com/test").header("Authorization", "testtest" ).body("test").send();
let test = _response.unwrap().text().unwrap();
let client2 = reqwest::blocking::Client::builder().danger_accept_invalid_certs(true).build().unwrap();
let url = "https://google.com";
let argumentsdata = format!("register={}","1234");
let concat = [url,&argumentsdata].join("/");
client2.get(&concat).send();
}