Polling for orders:
For outbounds processed by InterFulfillment (Example Shipped Orders)
-
Use the GET Orders endpoint to pull by orders that were processed, marked as shipped/closed, and that have not already been polled.
Example GET URL Template
{{baseUrl}}/orders?pgsiz=100&pgnum=1&detail=All&Itemdetail= All&rql=readOnly.isClosed== true;readOnly.AsnSent!=true
-
Capture the OrderIDs returned in the GET request to then flag them as ASNSent (already polled) using our POST Orders ASN Sent endpoint. By flagging the Orders as ASNSent they will not return in future GET request using the GET URL template from step 1.
Note once orders are marked as ASNSent it cannot be unmarked.
Example POST
POST /orders/asnsentmarker HTTP/1.1
Host: box.secure-wms.com
Host: secure-wms.com
Content-Type: application/json; charset=utf-8
Accept: application/hal+json
Authorization: bearer {{EnterAccessToken Here}}
Content-Length: 98
{
"orderIdentifiers": [
{
"id": 339 //identifies OrderId to be marked as ASNSent
},
{
"id": 340 //identifies OrderId to be marked as ASNSent
}
]
}
Expected Response: 204 no content