POST
/
quickbooks-desktop
/
item-groups
/
{id}
import Conductor from 'conductor-node';

const client = new Conductor({
  apiKey: process.env['CONDUCTOR_SECRET_KEY'], // This is the default and can be omitted
});

async function main() {
  const itemGroup = await client.qbd.itemGroups.update('80000001-1234567890', {
    revisionNumber: '1721172183',
    conductorEndUserId: 'end_usr_1234567abcdefg',
  });

  console.log(itemGroup.id);
}

main();
{
  "id": "80000001-1234567890",
  "objectType": "qbd_item_group",
  "createdAt": "2021-10-01T17:34:56.000Z",
  "updatedAt": "2021-10-01T20:45:30.000Z",
  "revisionNumber": "1721172183",
  "name": "Office Supplies Bundle",
  "barcode": "012345678905",
  "isActive": true,
  "description": "Complete office starter kit with essential supplies for new employees.",
  "unitOfMeasureSet": {
    "id": "80000001-1234567890",
    "fullName": "Weight Units"
  },
  "shouldPrintItemsInGroup": true,
  "specialItemType": "finance_charge",
  "externalId": "12345678-abcd-1234-abcd-1234567890ab",
  "lines": [
    {
      "item": {
        "id": "80000001-1234567890",
        "fullName": "Widget A"
      },
      "quantity": 5,
      "unitOfMeasure": "Each"
    }
  ],
  "customFields": [
    {
      "ownerId": "0",
      "name": "Customer Rating",
      "type": "string_1024_type",
      "value": "Premium"
    }
  ]
}

Authorizations

Authorization
string
header
required

Your Conductor secret key using Bearer auth (e.g., "Authorization: Bearer {{YOUR_SECRET_KEY}}").

Headers

Conductor-End-User-Id
string
required

The ID of the EndUser to receive this request (e.g., "Conductor-End-User-Id: {{END_USER_ID}}").

Example:

"end_usr_1234567abcdefg"

Path Parameters

id
string
required

The QuickBooks-assigned unique identifier of the item group to update.

Example:

"80000001-1234567890"

Body

application/json
revisionNumber
string
required

The current QuickBooks-assigned revision number of the item group object you are updating, which you can get by fetching the object first. Provide the most recent revisionNumber to ensure you're working with the latest data; otherwise, the update will return an error.

Example:

"1721172183"

name
string

The case-insensitive unique name of this item group, unique across all item groups.

NOTE: Item groups do not have a fullName field because they are not hierarchical objects, which is why name is unique for them but not for objects that have parents.

Maximum length: 31 characters.

Maximum length: 31
Example:

"Office Supplies Bundle"

barcode
object

The item group's barcode.

isActive
boolean

Indicates whether this item group is active. Inactive objects are typically hidden from views and reports in QuickBooks. Defaults to true.

Example:

true

description
string

The item group's description that will appear on sales forms that include this item.

Example:

"Complete office starter kit with essential supplies for new employees."

unitOfMeasureSetId
string

The unit-of-measure set associated with this item group, which consists of a base unit and related units.

Example:

"80000001-1234567890"

forceUnitOfMeasureChange
boolean

Indicates whether to allow changing the item group's unit-of-measure set (using the unitOfMeasureSetId field) when the base unit of the new unit-of-measure set does not match that of the currently assigned set. Without setting this field to true in this scenario, the request will fail with an error; hence, this field is equivalent to accepting the warning prompt in the QuickBooks UI.

NOTE: Changing the base unit requires you to update the item's quantities-on-hand and cost to reflect the new unit; otherwise, these values will be inaccurate. Alternatively, consider creating a new item with the desired unit-of-measure set and deactivating the old item.

Example:

false

shouldPrintItemsInGroup
boolean

Indicates whether the individual items in this item group and their separate amounts appear on printed forms.

Example:

true

clearItemLines
boolean

When true, removes all existing item lines associated with this item group. To modify or add individual item lines, use the field itemLines instead.

Example:

false

lines
object[]

The item lines in this item group.

Response

200 - application/json
Returns the updated item group.
id
string
required

The unique identifier assigned by QuickBooks to this item group. This ID is unique across all item groups but not across different QuickBooks object types.

Example:

"80000001-1234567890"

objectType
string
required

The type of object. This value is always "qbd_item_group".

Allowed value: "qbd_item_group"
Example:

"qbd_item_group"

createdAt
string
required

The date and time when this item group was created, in ISO 8601 format (YYYY-MM-DDThh:mm:ss±hh:mm). The time zone is the same as the user's time zone in QuickBooks.

Example:

"2021-10-01T17:34:56.000Z"

updatedAt
string
required

The date and time when this item group was last updated, in ISO 8601 format (YYYY-MM-DDThh:mm:ss±hh:mm). The time zone is the same as the user's time zone in QuickBooks.

Example:

"2021-10-01T20:45:30.000Z"

revisionNumber
string
required

The current QuickBooks-assigned revision number of this item group object, which changes each time the object is modified. When updating this object, you must provide the most recent revisionNumber to ensure you're working with the latest data; otherwise, the update will return an error.

Example:

"1721172183"

name
string
required

The case-insensitive unique name of this item group, unique across all item groups.

NOTE: Item groups do not have a fullName field because they are not hierarchical objects, which is why name is unique for them but not for objects that have parents.

Example:

"Office Supplies Bundle"

barcode
string | null
required

The item group's barcode.

Example:

"012345678905"

isActive
boolean
required

Indicates whether this item group is active. Inactive objects are typically hidden from views and reports in QuickBooks. Defaults to true.

Example:

true

description
string | null
required

The item group's description that will appear on sales forms that include this item.

Example:

"Complete office starter kit with essential supplies for new employees."

unitOfMeasureSet
object | null
required

The unit-of-measure set associated with this item group, which consists of a base unit and related units.

Example:
{
  "id": "80000001-1234567890",
  "fullName": "Weight Units"
}
shouldPrintItemsInGroup
boolean
required

Indicates whether the individual items in this item group and their separate amounts appear on printed forms.

Example:

true

specialItemType
enum<string> | null
required

The type of special item for this item group.

Available options:
finance_charge,
reimbursable_expense_group,
reimbursable_expense_subtotal
Example:

"finance_charge"

externalId
string | null
required

A globally unique identifier (GUID) you, the developer, can provide for tracking this object in your external system. This field is immutable and can only be set during object creation.

Example:

"12345678-abcd-1234-abcd-1234567890ab"

lines
object[]
required

The item lines in this item group.

customFields
object[]
required

The custom fields for the item group object, added as user-defined data extensions, not included in the standard QuickBooks object.