title: REST API: returning newly create resource id?
body: <p>In terms of good REST API design, is it a good idea to return <code>id</code> of the newly created resource? Say I have an API:</p>
  
  <pre><code>api/resource POST
  </code></pre>
  
  <p>I've seen some guru who has such API to return empty json and insert the URI into with <code>Location</code> header in response. I think returning </p>
  
  <pre><code>{ 'id': '1000' } 
  </code></pre>
  
  <p>so that the caller can do something right away with it is better. Save one more round-trip to the server. What's the problem with this approach if any?</p>