Shipments Response Is Empty But Shipments Exist In Web UI

I’m working on an integration and am testing out the Shipments query with Altair before implementing in code. I’ve limited the scope of the query to just the surrounding days. I can see in the Web UI that a shipment was created on July 9 at 4pm; however, when querying for all shipments from July 8 to July 10, I get an empty response and no error messages.

Here is the web UI history of the order noting that an App User shipped the item from within ShipHero.

I’ve run the following query to try and retrieve this shipment data:

query($recordLimit:Int=5 $itemLimit:Int=10 $cursor:String="" $dateFrom:ISODateTime="2020-07-08" $dateTo:ISODateTime="2020-07-10" $sort:String="created_date") {
  shipments(date_from:$dateFrom date_to:$dateTo) {
    ...shipmentFields
  }
}

fragment shipmentFields on ShipmentsQueryResult {
  request_id
  complexity
  data(after:$cursor first:$recordLimit sort:$sort) {
    pageInfo {
      hasNextPage
      hasPreviousPage
      startCursor
      endCursor
    }
    edges {
      node {
        id
        legacy_id
        order_id
        user_id
        warehouse_id
        pending_shipment_id
        address {
          name
          address1
          address2
          city
          state
          country
          zip
          phone
        }
        picked_up
        created_date
        line_items(first:$itemLimit) {
          pageInfo {
            hasNextPage
            hasPreviousPage
            startCursor
            endCursor
          }
          edges {
            node {
              id
              line_item_id
              quantity
              line_item {
                barcode
                sku
              }
            }
            cursor
          }
        }
        shipping_labels {
          status
          tracking_number
          carrier
          shipping_name
          shipping_method
          cost
          address {
            name
            address1
            address2
            city
            state
            country
            zip
            phone
          }
          shipment_line_items(first:$itemLimit) {
            pageInfo {
              hasNextPage
              hasPreviousPage
              startCursor
              endCursor
            }
            edges {
              node {
                id
                line_item_id
                quantity
                line_item {
                  sku
                  shipped_line_item_lots {
                    lot_id
                    lot_name
                    lot_expiration_date
                  }
                }
              }
              cursor
            }
          }
        }
        order {
          id
          order_number
          partner_order_id
          shop_name
          fulfillment_status
          order_date
          email
          packing_note
        }
      }
      cursor
    }
  }
}

The response I get is:

{
  "data": {
    "shipments": {
      "request_id": "5f1af91b37302d2805771bee",
      "complexity": 101,
      "data": {
        "pageInfo": {
          "hasNextPage": false,
          "hasPreviousPage": false,
          "startCursor": null,
          "endCursor": null
        },
        "edges": []
      }
    }
  }
}

Why can I not retrieve shipment information for this shipment that clearly exists?

Hi @brett
Is there any chance you might be seeing another account?
I’m trying to get an order from 7/9/2020 on the account where your credentials are but getting the following:

Screen Shot 2020-07-24 at 16.24.56

Thanks in advance!
Tom

@tomasw D’oh! Thanks for that. I was in fact looking at the wrong account.

1 Like