i am trying to call Action created for Phonecall through the Web API using below code.
var data = {
"GenderId": "77142D3D-96EB-E711-8116-5065F38A5B01"
};
var req = new XMLHttpRequest();
// specify name of the entity, record id and name of the action in the Wen API Url
req.open("POST", serverURL + "/api/data/v8.2/phonecalls(97953273-B496-E711-8111-5065F38A6AD1)/Microsoft.Dynamics.CRM.new_UpdateCustomFieldinPhonecallthroughAction", true);
req.setRequestHeader("Accept", "application/json");
req.setRequestHeader("Content-Type", "application/json; charset=utf-8");
req.setRequestHeader("OData-MaxVersion", "4.0");
req.setRequestHeader("OData-Version", "4.0");
req.onreadystatechange = function () {
if (this.readyState == 4 /* complete */) {
req.onreadystatechange = null;
if (this.status == 200) {
var data = JSON.parse(this.response);
alert(data);
} else {
var error = JSON.parse(this.response).error;
alert(error.message);
}
}
};
// send the request with the data for the input parameter
req.send(window.JSON.stringify(data));
But i am getting error :-
No HTTP resource was found that matches the request URI while calling ms crm action through javascript
Kindly suggest some solution is some one has faced the same issue
*This post is locked for comments