1.1.5 • Published 4 years ago
devergroup-request v1.1.5
const DvAxios = require("../dist/index").default;
const axios = new DvAxios({
proxy: [],
autoUserAgent: true,
axiosOpt: {
timeout: 10 * 1000,
},
});
(async () => {
const { data } = await axios.post(
"https://sellthepeak.com/wp-login.php",
{
log: "Thinh",
pwd: "b$atf#M4epyH58ugCUI63XZ&",
redirect_to: "https://sellthepeak.com/wp-admin/",
"wp-submit": "Log In",
},
{
headers: {
cookie: "wordpress_test_cookie=WP+Cookie+check",
},
}
);
require("fs").writeFileSync("./test.html", data);
const cookie = axios.exportCookie();
console.log(cookie);
// console.log(data);
})();