Symptom
User can post a duplicate Goods Issue for an Stock Transport Order via the API: API_MATERIAL_DOCUMENT_SRV - error M7064 is not raised.
Environment
SAP S/4HANA Public Cloud Edition
Reproducing the Issue
- Created an STO 4500003143 for quantity 10.
- Go to MIGO / Post Goods Movement.
- Choose : Goods Issue / Purchase Order = 4500003143 / Movement Type 351.
- Select item / Quantity = 10
- Press Check & Save.
- Material Document is created.
- From MIGO - Try post the same goods issue again for the PO - we see the error M7064 Document 4500003143 does not contain any selectable items.
--------------------------------------------------------------------------------------------------
From the API - post a goods issue with Mvt 351 for STO 4500003143
/sap/opu/odata/sap/API_MATERIAL_DOCUMENT_SRV/A_MaterialDocumentHeader
{
"DocumentDate": "2026-10-14T00:00:00",
"PostingDate": "2026-10-14T00:00:00",
"GoodsMovementCode": "03",
"to_MaterialDocumentItem": {
"results": [
{
"Plant": "1010",
"StorageLocation": "101A",
"GoodsMovementType": "351",
"PurchaseOrder": "4500003143",
"PurchaseOrderItem": "10",
"EntryUnit": "EA",
"QuantityInEntryUnit": "10"
}
]
}
}
The goods issue posts, creating the MM Document : A_MaterialDocumentHeader(MaterialDocumentYear='2026',MaterialDocument='4900009007'.
Cause
The error M7064 is only applicable to dialog processes (such as MIGO).
Resolution
The API_MATERIAL_DOCUMENT_SRV does not perform the same checks as MIGO when performing goods movements.
Keywords
M7064, Goods Issue, 351, transit, STO, API, API_MATERIAL_DOCUMENT_SRV, dialog, , KBA , MM-IM-GI-2CL , Goods Issue and Return Delivery (Public Cloud) , Problem
SAP Knowledge Base Article - Public