title: Handling errors with the (now default) Ember Data JSON-API adapter
body: <p>I am using Ember 1.13.7 and Ember Data 1.13.8, which by default use the JSON-API standard to format the payloads sent to and received from the API.</p>
  
  <p>I would like to use Ember Data's built-in error handling in order to display red "error" form fields to the user.  I have formatted my API error responses as per the JSON-API standard, e.g.</p>
  
  <pre><code>{"errors":[
      {
          "title":"The included.1.attributes.street name field is required.", 
          "code":"API_ERR", 
          "status":"400", 
      }
  ]}
  </code></pre>
  
  <p>and when I attempt to save my model the error callback is being correctly executed.  If I look within the Ember Inspector I can see that the model's "isError" value is set to true but I can't see how Ember Data is supposed to know which field within the model is the one in an error state?  I see from the official JSON-API pages (<a href="http://jsonapi.org/format/#errors">http://jsonapi.org/format/#errors</a>) that you can include a "source" object within the error response:</p>
  
  <blockquote>
    <p>source: an object containing references to the source of the error,
    optionally including any of the following members: </p>
    
    <blockquote>
      <p>pointer: a JSON Pointer [RFC6901] to the associated entity in the request document
      [e.g. "/data" for a primary data object, or "/data/attributes/title"
      for a specific attribute]. </p>
      
      <p>parameter: a string indicating which query
      parameter caused the error.</p>
    </blockquote>
  </blockquote>
  
  <p>but is this what I should be doing in order to tell Ember Data which fields it should mark as being in an error state?</p>
  
  <p>If anyone can help shed some light on this I'd be grateful.</p>
  
  <p>Thanks.</p>