title: HTTP status code for async tasks
body: <p>I am implementing a REST API which involves creating a object on the server. The object creation involves multiple steps and may take a while. I do not want the user to wait on it. I simply return a 202 response with a unique request id for the client request and start some threads on the server to create the object. The client is supposed to check back to see whether the request is completed or not, in the future. The flow goes like this:</p>
  
  <ol>
  <li>The client POSTs the object.</li>
  <li>The server responds with a 202 Accepted code with a Location header <code>/my-app/&lt;reqId&gt;</code></li>
  <li>The client does a GET on <code>/my-app/&lt;reqId&gt;</code></li>
  </ol>
  
  <p>Now at the third step, these things might happen:</p>
  
  <ol>
  <li>Object creation is still in progress(client should check again after sometime).</li>
  <li>Some Error occured.</li>
  <li>Object is successfully created. </li>
  </ol>
  
  <p>Now what http code should my API <code>/my-app/&lt;reqId&gt;</code> respond for the above three scenarios?</p>