Purchase Orders does not have updated_at field

Hello @sh-agent

Need your suggestion on how to retrieve the recent purchase order updates using the API In case if we don’t have updated_at field in purchase order header. As I checked the documentation we don’t have any field for updated time_stamp, except created_at.

I would need this field for sorting purchase order data using the next EndCursor. Would it be possible to add the updated_at field, or please provide the alternative method to pull updated data.

Below is the query sample query -

query {
purchase_orders {
data (sort:“created_at”){
edges {
node {
account_id
arrived_at
created_at
date_closed
description
discount
fulfillment_status
id
images
legacy_id
locked_by_user_id
locking
origin_of_shipment
packing_note
partner_order_number
payment_due_by
payment_method
payment_note
pdf
po_date
po_note
po_number
ship_date
shipping_carrier
shipping_method
shipping_name
shipping_price
subtotal
tax
total_price
tracking_number
vendor_id
warehouse_id
}
}
pageInfo {
startCursor
endCursor
hasNextPage
hasPreviousPage
}
}
}
}

Thank you.

1 Like

Hello @nareshbiyyam

As you pointed out, there is no way to filter out POs by their updated date. I will make sure to pass along the feedback.

You can use the Purchase Order Update Webhook, which will trigger anytime a PO is updated, and it doesn’t consume any credits. Webhooks – Developer Resources | ShipHero

Have a nice day!
TomasFD

Hello @tomasfd,

Thanks for your suggestion, I will try out this approach and see if this works. However, As per the documentation I should not be rely on the Webhooks completely, since it won’t be trigger for all the changes.

Because of this reason, If we have feature include the updated_at field whenever the Purchase order get’s updated, that would be an awesome functionality and it would make our API implementation very simple and efficient.

Please do update me in case if any updates happens for this particular requirement.

Thanks for your help much appreciated.

Thanks.

2 Likes

+1, our team would really benefit from having the updated_at field available to query

1 Like