I'm try to request an ajax Post with laravel, they provided me a API with username and password authorization. how can I solve this.
here my code below.
$("#login_page").submit(function (e) {
$.ajax({
url: "https://api.seasolutions.ph/frontend/login/",
type: "POST",
headers: {
'Authorization': 'Basic ' + '***=',
},
data: $("#login_page").serialize(), //only input
success: function (response) {
console.log(response);
}
});
e.preventDefault();
});