Which Event To Get Order Details With Orders API and Webhooks

Hello, I am trying to retrieve order details using webhooks in my web application. When a user checks out with a Square URL this data is sent to my server:

Full order created body:
  merchant_id: 'QMQ16MVGWH93N',
  type: 'order.created',
  event_id: 'c164463c-92d5-33ca-9818-06da863a7f72',
  created_at: '2023-04-26T17:48:15Z',
  data: {
    type: 'order',
    id: 'qvlZ3QTByCtNJ471bOr2NJbpQaSZY',
    object: { order_created: [Object] }
order obj body:
  created_at: '2023-04-26T17:48:14.975Z',
  location_id: '3WRDA0JSAPRV7',
  order_id: 'qvlZ3QTByCtNJ471bOr2NJbpQaSZY',
  state: 'OPEN',
  version: 1

This is good, but I want to get what the customer actually ordered. I believe in the Orders API it’s called ‘line items’. I am subscribed to the order.created event. I am looking for what the customer ordered, quantity, etc…

At this time you’ll need to call RetrieveOrder with the order_id to get all the line items of an order. :slightly_smiling_face: