Encountering an issue with the Rest call to Moqui while running locally... The error message received is "REST Access Forbidden (no authz): User null is not authorized for View on REST Path /moqui/users". Additionally, the web console displays error code 403 (Forbidden).
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8>
<title>AJAX Test</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script>
</head>
<body>
<script>
$(document).ready(function() {
$.ajax({
type: "GET",
url: "http://localhost:8080/rest/s1/moqui/users",
headers: {
Accept: "application/json",
Authorization : "Basic am9obi5kb2U6bW9xdWk="
},
contentType: "application/json"
}).then(function(data) {
console.log(data);
});
});
</script>
</body>
</html>