Create or update a physical stocktaking act.

Creating the act is the first step in physical stocktaking. Next, it must be filled with quantities counted in the warehouse. After all quantities have been recorded and verified, the act must be confirmed. Finally, surplus quantities should be taken into stock with an Inventory Registration and missing quantites written off with an Inventory Write-off. Note that just confirming the act will not update your inventory yet!

Inventory Registrations and Write-offs can be created manually in Erply back-end.

For related API calls, see getStocktakings, getStocktakingReadings, saveStocktakingReadings and incrementStocktakingReading.

Input parameters

Parameter name Description Possible value Required
warehouseID    Integer  yes  
confirmed  0 or 1, by default 0.

Always create the stocktaking initially in unconfirmed state (you may just omit this flag). Only when it has been finalized and all counts entered and double-checked, confirm the stocktake by re-saving it with flag confirmed = 1
recordCurrentQuantities  0 or 1, by default 0.

Whether the stocktaking sheet should be pre-populated with a list of products that you have in stock, and their quantities at the current moment.

You are STRONGLY recommended to set this flag to 1. If you do not pre-populate the sheet, products will be added to the list as you count them — but then the stocktaking won't catch items that have an inventory quantity in ERPLY, but which are no longer to be found in the warehouse, and you woun't be able to write them off. 
includeProducts  This field only works if you set recordCurrentQuantities = 1. Specifies the products to be included. Possible values:
  • ALL - all products
  • POSITIVE_STOCK - products in stock
  • NEGATIVE_STOCK - products with negative stock
  • NON_ZERO_STOCK - products with non-zero amount in stock
If omitted, 'NON_ZERO_STOCK' will be selected as default. 
excludeReservations  0 or 1, by default 0.

Set it to 1 if reserved items (items on layby) are physically located in another place, and won't be counted during stocktaking. 


Field name Type Description
stocktakingID  Integer