Hi. I have been using the Microsoft tutorials to understand plugins and (ex HttpResponseMessage & HttpClient).
The Task below works fine when my query parameter is either the "contacts" or "accounts" entities. I created a custom entity - "Automobile" which I am able to perform CRUD operations, create processes etc. from the CRM application, however, when I try to run the plugin below where the query is now "Automobiles" I am getting a 404 - Not found error. I don't know why my custom entity cannot be found. Any ideas why?
private async Task<HttpResponseMessage> SendCrmRequestAsync(HttpMethod method, string query, Boolean formatted = false, int maxPageSize = 10)
{
HttpRequestMessage request = new HttpRequestMessage(method, query);
request.Headers.Add("Prefer", "odata.maxpagesize=" + maxPageSize.ToString());
if (formatted)
request.Headers.Add("Prefer","odata.include-annotations=OData.Community.Display.V1.FormattedValue");
return await httpClient.SendAsync(request);
}
*This post is locked for comments