Pre-requisites
Prior to following this article, you will need to understand our main Postman article here, along with having a basic understanding of how API calls are structured.
API Call
Identifying Which to Use
The API call you will need to use to update an orderline status through our API is "POST services/api/OrderlineItem/UpdateItemStatus/{id}"
Further documentation on this API call can be found later in this document, and by adding /services/api to the end of your storefront URL.
Identifying the IDs
When using this API call, there are two parts you need to configure:
- The orderline ID
- The new status ID
The orderline ID is the easiest one to find - you can find this under the "Job ID" columnin Shared Print Operations:
And once again in the "Job ID" column of the "Products" tab when viewing the order through Sales -> Orders.
Please note that you must include the letter prefix shown in Shared Print Operations when making the API call, otherwise Catfish will not recognise the orderline ID.
The new status ID can be found documented in /services/api , but they are also listed below:
- Printed = 8
- Shipped = 9
- AwaitingApproval = 10
- AwaitingData = 11
- AwaitingParts = 12
- AwaitingProof = 13
- InArtworking = 14
- InFinishing = 15
- InPacking = 16
- InProduction = 17
- InReprographics = 18
- OnHold = 19
- ReadyForCollection = 46
- Blocked = 49
Configuring the Call
The base URL for this call is "/api/OrderlineItem/UpdateItemStatus/{id}" and thankfully there are only two changes that need to be made, so there is not too much configuration required.
Firstly, you'll need to set {id} to the orderline ID.
In the screenshots shown in the section above, the orderline ID has been identified as "n934", so the URL will then become:
/api/OrderlineItem/UpdateItemStatus/n934
Next, the new status ID needs to be passed in the newStatus parameter. For this example, the orderline status is going to be set to "Shipped", and in the table above we can see that the "shipped" orderline status is "9".
This means the URL will then become:
/api/OrderlineItem/UpdateItemStatus/n934?newStatus=9
Alternatively, you can configure this with Postman's "Parameters" tab as shown below:
Response
Assuming the authorisation has been configured as explained in our Postman article, this URL is ready to post.
If the IDs provided were valid (as above), then you will receive a "200 OK" response:
After receiving the 200 OK, we can check the orderline and see that it has indeed been updated to the "Shipped" status:
0 Comments