ItemInventoryAdd qbXML example

Adds an inventory item, with its income, cost of goods sold and asset accounts.

qbXML ItemInventoryAddRq, version 16.0
<?xml version="1.0" encoding="utf-8"?>
<?qbxml version="16.0"?>
<QBXML>
  <QBXMLMsgsRq onError="stopOnError">
    <ItemInventoryAddRq>
      <ItemInventoryAdd>
        <Name>Widget</Name>
        <SalesDesc>Blue widget, large</SalesDesc>
        <SalesPrice>125.00</SalesPrice>
        <IncomeAccountRef>
          <FullName>Sales</FullName>
        </IncomeAccountRef>
        <PurchaseDesc>Blue widget, large</PurchaseDesc>
        <PurchaseCost>60.00</PurchaseCost>
        <COGSAccountRef>
          <FullName>Cost of Goods Sold</FullName>
        </COGSAccountRef>
        <AssetAccountRef>
          <FullName>Inventory Asset</FullName>
        </AssetAccountRef>
        <ReorderPoint>10</ReorderPoint>
      </ItemInventoryAdd>
    </ItemInventoryAddRq>
  </QBXMLMsgsRq>
</QBXML>
Open in the validator Check it against the qbXML 16.0 schema, edit it, and run it in your own QuickBooks.

Things to know

  • A *Ref that names a record QuickBooks doesn't have answers 3120 when it gives a ListID and 3140 when it gives a FullName.
  • Elements must appear in the order the schema lists them: a valid element in the wrong place fails validation.

The same request with QuBe Sync's API

QuBe Sync takes this JSON, writes the qbXML for you and delivers QuickBooks' answer to your webhook as JSON.

POST /api/v2/connections/{connection_id}/item-inventories
{
  "asset_account_ref": {
    "full_name": "Inventory Asset"
  },
  "cogs_account_ref": {
    "full_name": "Cost of Goods Sold"
  },
  "income_account_ref": {
    "full_name": "Sales"
  },
  "name": "Widget",
  "purchase_cost": 60.0,
  "purchase_desc": "Blue widget, large",
  "reorder_point": 10,
  "sales_desc": "Blue widget, large",
  "sales_price": 125.0
}

Every field ItemInventoryAdd takes is in Intuit's reference.

More requests

Items

All qbXML examples