QuickBooks Integrator 2020 Node.js Edition

Questions / Feedback?

ItemType Property

The type of item.

Syntax

 item.getItemType([callback])
 item.setItemType( itemType, [callback])

Possible Values

  0 (itUnknown), 
  1 (itService), 
  2 (itInventory), 
  3 (itNonInventory), 
  4 (itPayment), 
  5 (itDiscount), 
  6 (itSalesTax), 
  7 (itSubtotal), 
  8 (itOtherCharge), 
  9 (itInventoryAssembly), 
  10 (itGroup), 
  11 (itSalesTaxGroup), 
  12 (itFixedAsset)

Default Value

0

Callback

The 'callback' parameter specifies a function which will be called when the operation completes (or an error is encountered). If the 'callback' parameter is not specified, then the method will block and will not return until the operation completes (or an error is encountered).

The callback for the getItemType([callback]) method is defined as:

function(err, data){ }

'err' is the error that occurred. If there was no error, then 'err' is 'null'.

'data' is the value returned by the method.

The callback for the setItemType([callback]) method is defined as:

function(err){ }

'err' is the error that occurred. If there was no error, then 'err' is 'null'.

'err' has 2 properties which hold detailed information:

err.code
err.message

Remarks

The type of item. It is necessary to specify this before invoking Add or Update. It is not necessary to specify before a call to Get however.

The following values are permitted:

itUnknown0
itService1
itInventory2
itNonInventory3
itPayment4
itDiscount5
itSalesTax6
itSubtotal7
itOtherCharge8
itInventoryAssembly9
itGroup10
itSalesTaxGroup11
itFixedAsset12

The following properties may be specified for each type of item. Required properties are in bold, reference (Name or Id) properties are starred, and special fields are in italics.

Service ItemsItemName, Description, Parent*, IsActive, SalesTaxCode*, Price, PricePercent, Account*, PurchaseCost, PurchaseDescription, PurchasePreferredVendor*, PurchaseExpenseAccount*.
Non-Inventory ItemsSame as for service items.
Inventory ItemsItemName, Description, Parent*, IsActive, SalesTaxCode*, Price, PricePercent, Account*, PurchaseCost, PurchaseDescription, PurchasePreferredVendor*, PurchaseAssetAccount*, PurchaseCOGSAccount*, InventoryReorderPoint, InventoryQuantityOnHand, InventoryAverageCost, InventoryQuantityOnOrder, InventoryQuantityOnSalesOrder, InventoryDate.
Payment ItemsItemName, IsActive, Description, Account*, PaymentMethod*.
Discount ItemsItemName, IsActive, Parent*, SalesTaxCode*, Description, Price, PricePercent, Account*.
Sales Tax ItemsItemName, IsActive, Description, TaxRate, TaxVendor*.
Subtotal ItemsItemName, IsActive, Description.
Other Charge ItemsSame as for service items.

This property is required.

Data Type

Integer

Copyright (c) 2021 /n software inc. - All rights reserved.
QuickBooks Integrator 2020 Node.js Edition - Version 20.0 [Build 7941]