Auto-Return Labels: Tracking Numbers

Trying to get the tracking number for my automated return labels.

Not seeing anything on the Order JSON object.

Is there an endpoint or webhook that can do this? Returns webhook is not firing for auto-return labels.

Edit: @sh-dev @yosef - Sorry for the desperation!

Hi @garrett!
So you are subscribed to the Return Update webhook and not getting the information on auto-return labels?
Did I get that right?
Thanks!
Tom

@tomasw Hi! Thank you so much for the quick response.

That is correct.

Yes we have an automatic trigger setup which creates a return tracking label for the order, but we are unable to find the returnTrackingNumber via code, API, or webhook. We have tried /returns, /get-order, and /shipments API endpoints.

Here is an example order which has a return tracking label, but no data in /returns API endpoint: https://app.shiphero.com/dashboard/orders/details/116290719

We have a Return Update webhook registered as well to receive all returns. This should get triggered when a label is automatically created correct?

Thank you for your help.

Thanks for the details @garrett & @aldev !
I confirmed it would not work for webhooks, and not showing on the orders/returns query, but posted a request for our team to be able to provide an answer on this.
I will post as soon as I have a response to this.
Thanks for the patience!
Tom

1 Like

Good morning @garrett & @aldev!
The label should be available now under the Order query.
For example, you could use:

query {
  order(id: "1111111111") {
    request_id
    complexity
    data {
      id
      legacy_id
      order_number
      partner_order_id
      shop_name
      fulfillment_status
      rma_labels {
        account_id
        order_id
        rma_id
        shipment_id
        shipping_name
        tracking_number
        status
        carrier
        shipping_method
        cost
        box_code
        dimensions {
            height
            weight
            width
            length
        }
        address {
            address1
            address2
            city
            state
            county
        }

        paper_pdf_location
        thermal_pdf_location
        pdf_location
        image_location
        delivered
        picked_up
        refunded
        needs_refund
        profile
        full_size_to_print
        partner_fulfillment_id
        created_at
        updated_at
      }
    }
  }  

And this should return the rma_label expected.
Please let me know if there’s anything else I can help you with.
Thanks for the patience on this!
Tom

Thanks @tomasw - coming back to this now that we’re using ShipHero Fulfillment Network and can’t reply on Shippo for return tracking info.

Here is a query for an order that is fulfilled and has a return label, but rma_labels is empty in response.

query {
  order(id: "T3JkZXI6MTMxNDMyMjQ0") {
    request_id
    complexity
    data {
      id
      legacy_id
      order_number
      partner_order_id
      shop_name
      fulfillment_status
      rma_labels {
        account_id
        order_id
        rma_id
        shipment_id
        shipping_name
        tracking_number
        status
        carrier
        shipping_method
        cost
        box_code
        paper_pdf_location
        thermal_pdf_location
        pdf_location
        image_location
        delivered
        picked_up
        refunded
        needs_refund
        profile
        full_size_to_print
        partner_fulfillment_id
        created_at
        updated_at
      }
    }
  }
}

Response:

{
    "data": {
        "order": {
            "request_id": "5ee3fb634cee0016e8fe196f",
            "complexity": 1,
            "data": {
                "id": "T3JkZXI6MTMxNDMyMjQ0",
                "legacy_id": 131432244,
                "order_number": "#118815",
                "partner_order_id": "2148594548788",
                "shop_name": "bytemedental.myshopify.com",
                "fulfillment_status": "fulfilled",
                "rma_labels": []
            }
        }
    }
}

Are we doing anything wrong here?

Hi @garrett
I see what you mean. I will engage the engineering team about this and let you know what we find asap.
Thanks again !
Tom

1 Like