Hello,
i’m trying to use the rest api service to search inside an entity but i receive a 500 error when i try to do this request by javascript after the authentication. In catalina i see this error : Expected BEGIN_OBJECT but was STRING at line 1 column 1 path.
Sorry Can someone help me to find the error?
Greetings
function loadTrace() {
var d={
"filter":
{
"property": "booleanField",
"operator": "=",
"value": true
}
,
"view": "someViewName",
"returnCount": true
};
$.post({
url: 'http://localhost:8080/app/rest/v2/entities/trace_Tracciabilita/search',
headers: {
'Authorization': 'Bearer ' + oauthToken,
'Content-Type': 'application/x-www-form-urlencoded'
},
dataType: 'json',
data:d,
success: function (data) {
$('#customers').show();
$.each(data, function (i, tracciabilita) {
$('#customersList').append("<li>" + tracciabilita.id_soggetto.denominazione + " ( )</li>");
});
}
})
}