Hi Mike
I reactivated this post - the accepted answer, the one you gave turned out to be a little far from reality - not of your doing.
MYOB's API Endpoint Notes and examples are woefully in error and lacking the information I needed and yourself to answer this question
I have battled other endpoints and have never been beaten in getting one coded and working - not to say that is due to MYOB's endpoint examples and notes - quite the opposite - due to just persisting until things worked.
Well I did that with the 'PUT' inventory/item update endpoint through the API - and NOTHING WORKED - nothing.
A month later - thinking everyday I would 'get it' - I never did. None of my old tricks worked - it just continued to error
I added ALL manadatory parameters as indicated by the website notes - and finally yesterday braved an email to the developers email site - to be told - sorry from 1 Jul 22 you needed to include your Developers ID and this email account is no longer monitored - you have to post a ticket.
No problem - I posted a ticket - was easy - just cut and paste from my email.
Reply from ticket system - Thank you - we will reply within 48 hrs except public hols etc. - but hey go to the Developers API endPoint notes etc.....
I waited - and in 24 hrs - Hannah cherry reply was waiting in my email folder - the jist of the reply.
Yep Howard the Developer API EndPoint notes are woefully dated and 'we are updating those but can't give a timeframe for completion' - however in reply to your POST - here is an example of the required PUT - the answer
The PUT had to be FULL BODIED - EVERY FIELD populated else the update ( which was only for the Purchase Standard Cost' ) would wipe out ALL the existing data.
Wow - that blows me away in logic - noting that a manual update through the import/export facility allows you to update distinct data fields so long as you include the ItemNumber.
However the end point requires you to load the entire Inventory data table with existing data and obviously the field you are changing.
I haven't tried it because the code to build the PUT body is going to be quite complex - nothwithstanding the need to download ALL this data for the said items so you can populate the PUT fields.
Hmm - my brain is reeling from that bombshell note.
The Doc ( shell shocked and in PTMURSS) Post Traumatic MYOB Update Requirement Shell Shock)
PS - I will update this post when I have success with a single update item - you will hear the scream