I am using reqres API to do a login but it is 400 error which says
{"error": "Missing email or username"}
I tried with postman but same error, this is my URL string from postman
https://reqres.in/api/login?email=eve.holt@reqres.in&password=cityslicka
and I am using the following in JS
form.addEventListener("submit", function(e){ const myData = 'email=eve.holt@reqres.in&password=cityslicka' e.preventDefault(); fetch("https://reqres.in/api/login", { method: 'post', headers : {"Content-Type": "application/x-www-form-urlencoded"} , body: { myData }, })})