SAP Document stock_transfer

Stock Transfer

Moves stock from one warehouse to another โ€” quantity leaves the source and arrives at the destination with no net change in inventory value and no business partner.

A Stock Transfer moves stock between two warehouses. The same units that leave one location arrive at another; nothing enters or leaves the company. Total inventory quantity across all warehouses is unchanged โ€” only where the stock sits changes.

In the Service Layer this is the StockTransfers service, object code oStockTransfer (67), created at /b1s/v1/StockTransfers.

A Stock Transfer has no CardCode and no CardName โ€” it is a purely internal movement between two of the company’s own warehouses, so no trading partner is involved. Its defining fields are the source warehouse and the destination warehouse.

When it is used

A Stock Transfer is the right document whenever physical stock relocates and the company owns both ends:

  • Replenishing a branch or shop from a central warehouse.
  • Moving goods to a quarantine or QA warehouse for inspection, then back to the main warehouse once cleared.
  • Consolidating stock from a remote or overflow location into the main store.
  • Staging for production โ€” moving raw materials to a warehouse near the shop floor.
  • Rebalancing to put stock where demand actually is, so picking succeeds from the right location.

If stock is leaving the company entirely (a sale, a scrap, a return to vendor) a transfer is the wrong document โ€” that is a Delivery, a Goods Issue, or a Purchase Return. The transfer is strictly warehouse-to-warehouse, both sides internal.

Key fields

The document carries a from and a to warehouse, and one or more StockTransferLines. The header names a default source/destination; each line can override them, so a single transfer can move different items along different warehouse pairs.

FieldTypeNotes
DocEntryEdm.Int32Internal primary key (system-assigned)
DocNumEdm.Int32User-visible document number
DocObjectCodeSAPB1.BoObjectTypesAlways oStockTransfer (67)
DocDateEdm.StringPosting date โ€” YYYYMMDD string
FromWarehouseEdm.StringDefault source warehouse for the lines
ToWarehouseEdm.StringDefault destination warehouse for the lines
CommentsEdm.StringFree-text reason for the move
JournalMemoEdm.StringMemo written onto any generated journal entry
SeriesEdm.Int32Numbering series
PriceListEdm.Int32Price list used to value the moved goods

Notably absent: CardCode, CardName โ€” no business partner.

Line (StockTransferLines)

FieldTypeNotes
LineNumEdm.Int32Line index (0-based)
ItemCodeEdm.StringItem being moved
ItemDescriptionEdm.StringItem name
QuantityEdm.DoubleUnits moved
FromWarehouseCodeEdm.StringSource warehouse for this line (overrides header)
WarehouseCodeEdm.StringDestination warehouse for this line (overrides header)
CostingCodeEdm.StringCost centre / profit-centre dimension
ProjectCodeEdm.StringProject dimension

The pair FromWarehouseCode โ†’ WarehouseCode is the heart of the line: stock leaves the first and arrives at the second. If a warehouse uses bin locations, the line additionally carries bin-allocation sub-collections for both ends.

GL and stock effect

Stock: for each line, the on-hand quantity of ItemCode decreases in FromWarehouseCode and increases by the same Quantity in WarehouseCode. The company-wide total for that item does not change.

Accounting โ€” normally none. A transfer between two warehouses that share the same inventory G/L account has no net accounting effect: the value simply moves from one warehouse’s stock to another’s, and both roll up to the same balance-sheet account. No revenue, no expense, no change in total inventory value.

There is one exception: if the two warehouses are mapped to different inventory G/L accounts (SAP B1 allows per-warehouse G/L determination), the transfer posts a balancing journal entry to move the value between those accounts:

DR  Inventory โ€” destination warehouse account   (value moved)
CR      Inventory โ€” source warehouse account          (same value)

Even here the total inventory value on the balance sheet is unchanged โ€” the entry only reclassifies value between two inventory accounts. Under identical warehouse accounts, no journal entry is created at all.

Service Layer

PropertyValue
Service (entity)StockTransfers
Object codeoStockTransfer (67)
Create pathPOST /b1s/v1/StockTransfers
Read oneGET /b1s/v1/StockTransfers(<DocEntry>)
Sub-collectionStockTransferLines (carries ItemCode, Quantity, FromWarehouseCode, WarehouseCode)

A minimal create payload names the item, the quantity, and both warehouses โ€” no partner:

POST /b1s/v1/StockTransfers
{
  "FromWarehouse": "01",
  "ToWarehouse": "02",
  "Comments": "Replenish branch 02 from central",
  "StockTransferLines": [
    { "ItemCode": "A00001", "Quantity": 20, "FromWarehouseCode": "01", "WarehouseCode": "02" }
  ]
}

Norma’s connector and mock use the /b1s/v1/ paths shown here; a live SAP B1 on Feature Pack 2405 or later exposes the same entity under /b1s/v2/ with identical shape.

The response returns the assigned DocEntry and DocNum. A TransNum appears only when the transfer crossed differing inventory accounts and therefore posted a reclassifying journal entry.