title: How do I add a child object to parent using REST APIs?
body: <p>Sorry if this question seems odd, I'm kind of new to REST APIs!</p>
  
  <p>I have two entities: Order and Item.</p>
  
  <p>An order can have multiple items, and an item can only have one order.</p>
  
  <p>Using Spring Boot, I have set up the two entities in the corresponding relationship, and each have their own endpoint on the specified base-path which is /api.</p>
  
  <p>I can add an Order or Item just fine, however, I'm trying to figure out how to add an item directly to an order. </p>
  
  <p>If I create a new Order and it has the path <code>api/orders/1</code>, it shows that an item list is referenced in it as well at <code>api/orders/1/items</code>. However, if I try to POST a new item to that url, it doesn't work.</p>
  
  <p>I've also tried to just create a new item at the url <code>api/items</code>, which works, but at this point I can't figure out how to set the Item's parent as the Order.</p>
  
  <p>I'm also using Postman for this task.</p>
  
  <p>Thanks for any help.</p>