POST | /InventoryLocation/InventoryLocationUpdate | Inserts an inventory
location or updates a current inventory location. | Uses your API Key and applies a mvRecordAction
value on an mvInventoryLocation object. We can insert the mvInventoryLocation
object we specified using "Insert" as our mvRecordAction. We can update a current inventory location object using "Update",
we can insert it if it doesn't already exist, update it if it does using "InsertOrUpdate" and we can insert new fields or
update non-empty fields of the object using "InsertOrUpdateNonEmptyFields".
Optionally, you can use mvInsertUpdateDeleteSourceApplication when an external application ( eg WooCommerce ) is the
one that triggers the InventoryLocationUpdate call. InventoryLocationId cannot be updated.
A. Insert a new inventory location.
Value: {
"mvInventoryLocation": {
"InventoryLocationName": "Megaventory Warehouse",
"InventoryLocationAbbreviation": "MWH"
},
"mvRecordAction": "Insert",
"mvInsertUpdateDeleteSourceApplication": "WooCommerce"
}
Response: {
"mvInventoryLocation": {
"InventoryLocationID": 3410,
"InventoryLocationName": "Megaventory Warehouse",
"InventoryLocationAbbreviation": "MWH",
"InventoryLocationAddress": "",
"InventoryLocationCurrencyCode": ""
},
"ResponseStatus": {
"ErrorCode": "0"
},
"entityID": 3410
}
B.
Update the above inventory location by adding an InventoryLocationCurrencyCode, an address and updating
its location abbreviation.
Value: {
"mvInventoryLocation": {
"InventoryLocationID": 3410,
"InventoryLocationName": "Megaventory Warehouse",
"InventoryLocationAbbreviation": "MVWH",
"InventoryLocationAddress": "Megaventory Central Warehouse, Texas, USA",
"InventoryLocationCurrencyCode": "USD"
},
"mvRecordAction": "InsertOrUpdateNonEmptyFields",
"mvInsertUpdateDeleteSourceApplication": "Magento"
}
Response: {
"mvInventoryLocation": {
"InventoryLocationID": 3410,
"InventoryLocationName": "Megaventory Warehouse",
"InventoryLocationAbbreviation": "MVWH",
"InventoryLocationAddress": "Megaventory Central Warehouse, Texas, USA",
"InventoryLocationCurrencyCode": "USD"
},
"ResponseStatus": {
"ErrorCode": "0"
},
"entityID": 3410
}
|
---|