Get product reference or barcode from FulfillmentOrderLineItem?

Solved

Get product reference or barcode from FulfillmentOrderLineItem?

MaximRIT
Shopify Partner
14 1 1

Hello,

 

According to the new fulfilment API I tried to use mutation fulfillmentCreateV2 which requires FulfillmentOrder and FulfillmentOrderLineItem GIDs. To get them by the known order GID I used simple GraphQL request like this:

query Order {
  order(id: "gid://shopify/Order/4965293555878") {
    fulfillmentOrders(first:2 query:"status:OPEN") {
      edges {
        node {
          id
          status
          lineItems(first:50) {
            edges {
              node {
                id
                sku
                productTitle
              }
            }
          }
        }
      }
    }
  }
}

Actually it returns me both FulfillmentOrder and FulfillmentOrderLineItem GIDs but the problem I faced is that I cannot map FulfillmentOrderLineItem to the barcode I'm receiving from 3rd party system. The only field I have is SKU but it's not the one I need.

Accepted Solution (1)

MaximRIT
Shopify Partner
14 1 1

This is an accepted solution.

The problem is resolved by requesting fulfilment orders information using REST API. It contains product variant ID which is enough to get barcode.

View solution in original post

Reply 1 (1)

MaximRIT
Shopify Partner
14 1 1

This is an accepted solution.

The problem is resolved by requesting fulfilment orders information using REST API. It contains product variant ID which is enough to get barcode.