Skip to content

Sage 50 US Inventory Adjustment XML

Import Inventory Adjustments allows you to adjust the stock level of your products in Sage 50 US. The task does not support updating existing inventory adjustments in Sage, it will only create new ones.

Tasks

XML

Any Sage fields not documented below are not supported with our imports/exports, if there are additional fields you need contact us at [email protected].

Sample file for the various inventory types:-

<?xml version="1.0" encoding="utf-8"?>
<ArrayOfInventoryAdjustment>
  <InventoryAdjustment>
    <ItemID>TEST0001</ItemID>
    <ReferenceNumber>ZYNK4</ReferenceNumber>
    <Date>2026-01-31T09:00:00</Date>
    <ReasonToAdjust>New stock</ReasonToAdjust>
    <InventoryAccount>1200</InventoryAccount>
    <AmountAdjusted>9</AmountAdjusted>
    <InventoryAdjustmentLines>
      <InventoryAdjustmentLine>
        <GLSourceAccount>5000</GLSourceAccount>
        <UnitCost>9</UnitCost>
        <Quantity>3</Quantity>
        <Amount>-27</Amount>
      </InventoryAdjustmentLine>
    </InventoryAdjustmentLines>
  </InventoryAdjustment>
</ArrayOfInventoryAdjustment>

In each of the following sections most of the XML has been omitted to make the samples easier to read. The sections have been broken up into the various sections of the inventory record as viewed within Sage 50 US.

Header Fields

The following fields can be specified at the header level of an inventory adjustment record.

Sage Field XML Field Example Field Type Field Length Input
- ExternalId 1354155 string 255 Optional
Item ID ItemID TEST0001 string 20 Required
Reference ReferenceNumber ZYNK4 string 20 Required
Date Date 2026-01-31T09:00:00 datetime - Required
Job JobID JOB0001 string 20 Optional
Reason to Adjust ReasonToAdjust New stock string 30 Optional
- InventoryAccount 1200 string 15 Optional
- AmountAdjusted* 9 decimal - Optional
- DateInventoryAccountClearedInBankRec 2026-01-31T09:00:00 datetime - Optional
- NumberOfDistributions* 1 integer - Optional
- TransactionPeriod 10 integer - Optional
- TransactionNumber 1 integer - Optional
- SerialNumber XP001241B string 30 Optional
  • *AmountAdjusted - If not specified, it will be set to the unit cost from the first InventoryAdjustmentLine element.
  • *NumberOfDistributions - If not specified, it will be set to the count of InventoryAdjustmentLine elements provided.
<?xml version="1.0" encoding="utf-8"?>
<ArrayOfInventoryAdjustment>
  <InventoryAdjustment>
    <ExternalId>1354155</ExternalId>
    <ItemID>TEST0001</ItemID>
    <ReferenceNumber>ZYNK4</ReferenceNumber>
    <Date>2026-01-31T09:00:00</Date>
    <JobID>JOB0001</JobID>
    <ReasonToAdjust>New stock</ReasonToAdjust>
    <InventoryAccount>1200</InventoryAccount>
    <AmountAdjusted>9</AmountAdjusted>
    <DateInventoryAccountClearedInBankRec>2026-01-31T09:00:00</DateInventoryAccountClearedInBankRec>
    <NumberOfDistributions>1</NumberOfDistributions>
    <TransactionPeriod>10</TransactionPeriod>
    <TransactionNumber>1</TransactionNumber>
    <SerialNumber>XP001241B</SerialNumber>
  </InventoryAdjustment>
</ArrayOfInventoryAdjustment>

Line Fields

The following fields can be specified at the line level of an inventory adjustment record.

Sage Field XML Field Example Field Type Field Length Input
GL Source Account GLSourceAccount* 5000  string 15 Required
Unit Cost UnitCost 9 decimal - Required
Adjust Quantity By Quantity* 3 decimal - Required
- Amount* -27  decimal - Optional
DateGLAccountClearedInBankRec 2026-01-31T09:00:00 date - Optional
  • *GLSourceAccount - Typically, the cost of sales account would be specified.
  • *Quantity - Set to a positive value to receive stock into Sage, or a negative value to take stock out.
  • *Amount - Will be calculated automatically based on UnitCost and Quantity if not specified. When receiving stock, a negative value should be specified. When reducing stock, a positive value should be specified.
<?xml version="1.0" encoding="utf-8"?>
<ArrayOfInventoryAdjustment>
  <InventoryAdjustment>
    <InventoryAdjustmentLines>
      <InventoryAdjustmentLine>
        <GLSourceAccount>5000</GLSourceAccount>
        <UnitCost>9</UnitCost>
        <Quantity>3</Quantity>
        <Amount>-27</Amount>
        <DateGLAccountClearedInBankRec>2026-01-31T09:00:00</DateGLAccountClearedInBankRec>
      </InventoryAdjustmentLine>
    </InventoryAdjustmentLines>
  </InventoryAdjustment>
</ArrayOfInventoryAdjustment>