Retrieve the Available Quantity of an Inventory Item
If you are using the contract-based REST API to integrate MYOB Acumatica with an external system, this external system can retrieve from MYOB Acumatica the available quantity of an inventory item. This quantity is provided by the
Available Quantity by Inventory Item (GI640590) generic inquiry, which is available
for the external systems through the InventoryQuantityAvailable
entity of the Default/23.200.001 endpoint.
Testing of the Request
- Deploy a new MYOB Acumatica instance with the U100 dataset. For details on deploying an instance, see To Deploy an MYOB Acumatica Instance.
- To sign in to the instance in the client application, use the tenant name (which you specified when you created the instance) and the HEADOFFICE branch.
- If you use Postman as the client application for testing, in the IntegrationDevelopmentGuide.postman_collection.json collection (which is located in the IntegrationDevelopment\Help folder of the Help-and-Training-Examples repository on GitHub), make sure the collection variables have the proper values.
Request
You can use the following request example to retrieve the aggregated quantity of an inventory item through the contract-based REST API. You will retrieve the quantity of the APJAM08 inventory item that was available on June 7, 2023.
<MYOB Acumatica instance URL>
is the URL of the MYOB Acumatica
instance (such as https://my.acumatica.com/MyInstance). You can omit the instance
name in the URL (that is, you can use https://my.acumatica.com) if the instance
is installed in the root of the website.PUT ?$expand=Results HTTP/1.1
Host: [<MYOB Acumatica instance URL>]/entity/Default/23.200.001/InventoryQuantityAvailable
Accept: application/json
Content-Type: application/json
{
"InventoryID": { "value": "APJAM08" },
"LastModifiedDateTime": { "value": "6/7/2023" }
}
Usage Notes
In the Default/23.200.001 endpoint, you use the following fields of the InventoryQuantityAvailable entity:
- InventoryID: The identifier of the inventory item for which the available quantity is retrieved
- LastModifiedDateTime: The date and time for which the available quantity of the inventory item is retrieved