use reqwest;
fn main() {
post();
}
fn post() {
let params = [("content", "// Rust!"), ("syntax", "rust")];
let client = reqwest::blocking::Client::new();
let res = client
.post("https://dpaste.com/api/")
.form(¶ms)
.send()
.unwrap();
println!("{:?}", res.headers()["location"]);
}