I’ve extended the Stock Item entity and added Related Items to the entity. I can successfully add new related items to the stock item as well as query the item and get the related items attached to it, but I can’t seem to remove a related item once it has been added other than using the web interface and manually removing it.
The URL being accessed via PUT is
https://MyTenant/entity/MyCustomEndpoint/1.100.001/StockItemJSON being sent is
{
"InventoryID":{"value":"601-0669"},
"RelatedItems":
[
{
"LineID":null,
"Delete":{"value":true},
"ID":{"value":"d6fdf2bf-565b-f011-8427-120e4ffdb993"}
}
]
}I’ve tried providing the ID as well as the LineID, but get the same error: "The request is invalid: An exception occurred during input parsing"
I’m using the exact same method to add/remove vendor details, attributes, etc. on stock items, but just can’t seem to get it to work with related items.
Anyone have any suggestions on how to accomplish this?