The Interact API responds to successful requests with an HTTP status code of 200. If an operation fails this will return a status code in the 400 range as described below.
if the status code returned from the call is in the 400 range, this means the request was not successful. The content type of the response may be text/plain for API-level error messages, such as a 404 status code when trying to call a method of the API that doesn't exist. The content type is application/json for business-level error messages because the response includes a JSON object with useful information about the error:
{
"Message": "Timeline item not found."
}
{
"Message": "An error has occurred.",
"ExceptionMessage": "Object reference not set to an instance of an object.",
"ExceptionType": "System.NullReferenceException",
"StackTrace": " at Neutrino.Web.Api.Infrastructure.TenantHeaderFilter.AuthenticateAsync(HttpAuthenticationContext context, CancellationToken cancellationToken) in C:\\BuildAgent\\work\\7a8ee0090a2ef594\\Neutrino.Web.Api\\Infrastructure\\TenantHeaderFilter.cs:line 32\r\n at System.Web.Http.Controllers.AuthenticationFilterResult.<ExecuteAsync>d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__1.MoveNext()"
}