Postman: Update orderline status

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

When using this API call, there are two parts you need to configure:

  1. The orderline ID
  2. 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:

mceclip0.png

 

And once again in the "Job ID" column of the "Products" tab when viewing the order through Sales -> Orders.

mceclip1.png

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:

mceclip3.png

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:

mceclip4.png

After receiving the 200 OK, we can check the orderline and see that it has indeed been updated to the "Shipped" status:

mceclip5.png

Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.