| Description | Manage Allocation Documents |
| Name | ManageAllocationDocumentIn |
| Namespace | http://sap.com/xi/AP/SupplierInvoicing/Global |
| Product | SAP Business ByDesign |
| Process component | Supplier Invoice Processing |
| Process component namespace | http://sap.com/xi/AP/SupplierInvoicing/Global |
| Deployment unit | Supplier Invoicing |
| Endpoint Activation | By Scoping of Process Component | Operations |
|
| Release Status | Released |
| Technical documentation on the SAP API Business Hub | Manage Allocation Documents |
| General web service documentation | A2X Web Services (SOAP) |
An interface to create, edit, release,cancel or delete one or more Allocation docments for the Supplier Invoice Items with Landed Cost Component.
The web service Interface Manage Allocation Document In enables you to connect external applications to your SAP Business ByDesign system and to create and edit Allocation documents for Supplier Invoices in your system. This web service is relevant if your company wants to access and manage Allocation Documents from external applications.
The web service interface Manage Allocation Document In offers the operations CHECK_MAINTAIN_BUNDLE and MAINTAIN_BUNDLE.
Here is an example of a simple web service request:
<n0:AllocationDocumentMaintainBundleRequest_Sync xmlns:n0="http://sap.com/xi/SAPGlobal20/Global"> <BusinessDocumentBasicMessageHeader> <ID>Token 4</ID> <UUID>12345678-90AB-CDEF-0123-456789ABCDEF</UUID> <ReferenceID>Token 10</ReferenceID> <ReferenceUUID>12345678-90AB-CDEF-0123-456789ABCDEF</ReferenceUUID> </BusinessDocumentBasicMessageHeader> <AllocationDocumentMaintainBundle actionCode="01" itemListCompleteTransmissionIndicator="true"> <ObjectNodeSenderTechnicalID>Token 14</ObjectNodeSenderTechnicalID> <ChangeStateID>Token 15</ChangeStateID> <InvoiceID>Token 19</InvoiceID> <InvoiceItemId>Token 20</InvoiceItemId> <InvoiceItemUUID>12345678-90AB-CDEF-0123-456789ABCDEF</InvoiceItemUUID> <PostingDate>2022-07-05</PostingDate> <AllocationDocumentID>Token 26</AllocationDocumentID> <releaseAllocationDocument>true</releaseAllocationDocument> <cancelAllocationDocument>false</cancelAllocationDocument> <checkAllocationDocument>false</checkAllocationDocument> <AllocationDocumentItem actionCode="01"> <AllocationDocumentItemID>Token 28</AllocationDocumentItemID> <InboundDeliveryUUID>12345678-90AB-CDEF-0123-456789ABCDEF</InboundDeliveryUUID> <InboundDeliveryItemUUID>12345678-90AB-CDEF-0123-456789ABCDEF</InboundDeliveryItemUUID> <InboundDeliveryID>Token 36</InboundDeliveryID> <InboundDeliveryItemID>Token 37</InboundDeliveryItemID> <Percent>100</Percent> <NetAmount currencyCode="USD">40</NetAmount> </AllocationDocumentItem> </AllocationDocumentMaintainBundle> </n0:AllocationDocumentMaintainBundleRequest_Sync>
Existence of referenced business documents:
The following business documents are only referenced and will not be created by the service operations. They must exist in the system already at the time the web service is called:
• Supplier Invoice with Landed Cost Component Items
Maintain Bundle operations enable external applications to create and change business document data. Check Maintain Bundle operations enable external applications to simulate maintain bundle requests without changing business document data.
In particular, Check Maintain Bundle operations have the following functions:
• Return system messages similar to corresponding Maintain_Bundle operation
• Provide the same message type as the corresponding Maintain_Bundle operation
• Does not assign internal numbers from a productive number range interval (number range status are not increased)
• Does not change business documents
Action codes represent an instruction to the recipient of the web service request to process transmitted message node elements. Following are the existing action codes and their description.
| Action Code | Description |
|---|---|
| 01 | Create; the system returns an error message if the node element already exists. |
| 02 | Update; the system returns an error message if the node element does not exist. |
| 03 | Delete; the system returns an error message if the node element does not exist. |
| 04 | Save; the system creates or changes the node element data. |
| 05 | Remove; the system deletes the node element. If the node element does not exist, the system does not send an error message. |
| 06 | No Action; the system does not change the node element. |
Default action code: 04 (Save).
Note: Action code 04 (Save) creates business documents if the system could not identify a matching target business document. This applies in particular if no business document ID or UUID is provided by the web service consumer. The web service consumer (external application) is responsible for providing correct business document IDs or UUIDs and to avoid accidental creation of duplicate business documents.
The processing of node elements with cardinality > 1 (for example a list of descriptions in different languages or a list of telephone numbers) can be controlled using List Complete Transmission Indicators (LCTI). The LCTI indicates whether a list of node elements is transmitted completely. The LCTI of a node element with cardinality > 1 is modeled as an attribute of its parent node element (attribute name: <name of child element>ListCompleteTransmissionIndicator).
| LCTI | Description |
|---|---|
| false | The list of node elements is not transmitted completely and hence all node elements that are not transmitted remain unchanged. If transmitted node elements in the list can be identified uniquely, the system processes the node elements according the action code. If transmitted node elements in the list cannot be identified uniquely, the system appends the node element to the corresponding list of node elements in the target business document. |
| true | The list of elements is transmitted completely and hence all node elements that are not transmitted are removed. If no node element is transmitted, the complete list is removed. |
Default list complete transmission indicator: false.
Note: The LCTI refers to the completeness of the list of node elements and does not state completeness of sub-elements.
You can find general information about Web services, their structure and consumption in the Web Services documentation. Please open the Web Services document in a new window.
Possible scenarios include the following:
• Create and edit one or many of Allocation Documents
• Release one or many of Allocation Documents
• Check one or many of Allocation Documents
• Delete one or many of Allocation Documents
| Description | Maintain allocation documents |
| Name | MaintainBundle |
| Synchronous | yes |
| Release Status | Released |
To create, update, check, cancel or delete Allocation Documents.
You can use the Manage Allocation Document service in the following business scenarios:
• When creating large numbers of allocation documents in SAP Business ByDesign.
• When updating large numbers of allocation documents in SAP Business ByDesign.
The request message of the operation MaintainBundle contains a BasicMessageHeader node element as well as an AllocationDocumentMaintainBundle node element that contains the allocation document to be created or updated. The detailed structure of the AllocationDocumentMaintainBundle node is explained in the following sub-chapters. Multiple Allocation Document can be created and updated by a single web service request. Hence, the AllocationDocumentMaintainBundle node can occur multiple times in the request message.
The response message of the operation MaintainBundle contains log items and an Allocation Document-specific node with ObjectNodeSenderTechnicalID,ChangeStateID, as well as AllocationDocumentID and AllocationDocumentUUID.
The AllocationDocumentMaintainBundle node element contains all the basic information about the allocation document such as Invoice ID, Allocation Document ID, Release Indicator and Allocation Document Items node.
Following are the elements of this node:-
| Element | Description |
|---|---|
| ObjectNodeSenderTechnicalID | Technical ID that the sender gives to a node, for example, 1, 2, 3. |
| ChangeStateID | Not required |
| InvoiceID | Reference ID of the Invoice against which the allocation document is to be created or updated. |
| InvoiceItemUUID | Reference UUID of the Invoice against which the allocation document is to be created or updated |
| AllocationDocumentID | This element is mandatorily needed in case of Update,Check,Cancel or Delete scenarios |
| releaseAllocationDocument | This indicator should be marked as true if the allocation document needs to be Released |
| cancelAllocationDocument | This indicator should be marked as true if the allocation document needs to be Cancelled |
| checkAllocationDocument | This indicator should be marked as true if the allocation document needs to be Checked for any errors |
There is a message node element in this Node i.e AllocationDocumentItem node which has Item related information against the Inbound Delivery document including Net Amount.
The attributes are:
| Attributes | Description |
|---|---|
| actionCode | To create an Allocation Document, set to value 01. For Update - 02 and Delete -03 |
| itemListCompleteTransmissionIndicator | Set to value True. |
This node groups all the elements related to the Inbound Delivery documents. The elements are :
| Element | Description |
|---|---|
| AllocationDocumentItemID | The Item ID of the allocation document |
| InboundDeliveryUUID | The UUID of the Inbound Delivery against which the allocation document is created |
| InboundDeliveryItemUUID | The Item UUID of the Inbound Delivery against which the allocation document is created |
| InboundDeliveryID | The ID of the Inbound Delivery against which the allocation document is created |
| InboundDeliveryItemID | The Item ID of the Inbound Delivery against which the allocation document is created |
| Percent | Percentage allocation of the total amount of the Inbound Delivery. In case both Percent and Net Amount are specified, Percent would be given preference. |
| NetAmount | The Net Amount against a particular Inbound Delivery Item |
<n0:AllocationDocumentMaintainBundleRequest_Sync xmlns:n0="http://sap.com/xi/SAPGlobal20/Global"> <BusinessDocumentBasicMessageHeader> <ID></ID> <UUID></UUID> <ReferenceID></ReferenceID> <ReferenceUUID></ReferenceUUID> </BusinessDocumentBasicMessageHeader> <AllocationDocumentMaintainBundle actionCode="01" itemListCompleteTransmissionIndicator="true"> <ObjectNodeSenderTechnicalID>1</ObjectNodeSenderTechnicalID> <ChangeStateID></ChangeStateID> <InvoiceID>USSA-1662-2022</InvoiceID> <InvoiceItemId>1</InvoiceItemId> <InvoiceItemUUID></InvoiceItemUUID> <AllocationDocumentID></AllocationDocumentID> <AllocationDocumentItem actionCode="01"> <AllocationDocumentItemID>10</AllocationDocumentItemID> <InboundDeliveryUUID></InboundDeliveryUUID> <InboundDeliveryItemUUID></InboundDeliveryItemUUID> <InboundDeliveryID>319</InboundDeliveryID> <InboundDeliveryItemID>10</InboundDeliveryItemID> <Percent>60</Percent> <NetAmount currencyCode="USD">40</NetAmount> </AllocationDocumentItem> <AllocationDocumentItemID>20</AllocationDocumentItemID> <InboundDeliveryUUID></InboundDeliveryUUID> <InboundDeliveryItemUUID></InboundDeliveryItemUUID> <InboundDeliveryID>319</InboundDeliveryID> <InboundDeliveryItemID>20</InboundDeliveryItemID> <Percent>40</Percent> </AllocationDocumentItem> </AllocationDocumentMaintainBundle> </n0:AllocationDocumentMaintainBundleRequest_Sync>
<n0:AllocationDocumentMaintainBundleResponse_Sync xmlns:prx="urn:sap.com:proxy:ACL:/1SAI/TAE6E7414FF54193FD7966F:804" xmlns:n0="http://sap.com/xi/SAPGlobal20/Global"> <Log/> <AllocationDocumentResponse> <ChangeStateID> 20220620041246.9030640</ChangeStateID> <AllocationDocumentUUID>fa163efe-92b9-1eec-bc89-e79b16323f20</AllocationDocumentUUID> <AllocationDocumentID>USSA-1662-2022-1-1</AllocationDocumentID> </AllocationDocumentResponse> </n0:AllocationDocumentMaintainBundleResponse_Sync>
<n0:AllocationDocumentMaintainBundleRequest_Sync xmlns:n0="http://sap.com/xi/SAPGlobal20/Global"> <BusinessDocumentBasicMessageHeader> <ID></ID> <UUID></UUID> <ReferenceID></ReferenceID> <ReferenceUUID></ReferenceUUID> </BusinessDocumentBasicMessageHeader> <AllocationDocumentMaintainBundle actionCode="01" itemListCompleteTransmissionIndicator="true"> <ObjectNodeSenderTechnicalID>1</ObjectNodeSenderTechnicalID> <ChangeStateID></ChangeStateID> <InvoiceID>USSA-1662-2022</InvoiceID> <InvoiceItemId>1</InvoiceItemId> <InvoiceItemUUID></InvoiceItemUUID> <AllocationDocumentID></AllocationDocumentID> <releaseAllocationDocument>true</releaseAllocationDocument> <AllocationDocumentItem actionCode="01"> <AllocationDocumentItemID>10</AllocationDocumentItemID> <InboundDeliveryUUID></InboundDeliveryUUID> <InboundDeliveryItemUUID></InboundDeliveryItemUUID> <InboundDeliveryID>319</InboundDeliveryID> <InboundDeliveryItemID>10</InboundDeliveryItemID> <Percent>100</Percent> <NetAmount currencyCode="USD">40</NetAmount> </AllocationDocumentItem> </AllocationDocumentMaintainBundle> </n0:AllocationDocumentMaintainBundleRequest_Sync>
<n0:AllocationDocumentMaintainBundleResponse_Sync xmlns:prx="urn:sap.com:proxy:ACL:/1SAI/TAE6E7414FF54193FD7966F:804" xmlns:n0="http://sap.com/xi/SAPGlobal20/Global"> <Log/> <AllocationDocumentResponse> <ChangeStateID> 20220620041246.9030640</ChangeStateID> <AllocationDocumentUUID>fa163efe-92b9-1eec-bc89-e79b16323f20</AllocationDocumentUUID> <AllocationDocumentID>USSA-1662-2022-1-1</AllocationDocumentID> </AllocationDocumentResponse> </n0:AllocationDocumentMaintainBundleResponse_Sync>
<n0:AllocationDocumentMaintainBundleRequest_Sync
xmlns:n0="http://sap.com/xi/SAPGlobal20/Global">
<BusinessDocumentBasicMessageHeader>
<ID></ID>
<UUID></UUID>
<ReferenceID></ReferenceID>
<ReferenceUUID></ReferenceUUID>
</BusinessDocumentBasicMessageHeader>
<AllocationDocumentMaintainBundle actionCode = "02" itemListCompleteTransmissionIndicator = "true">
<ObjectNodeSenderTechnicalID></ObjectNodeSenderTechnicalID>
<ChangeStateID></ChangeStateID>
<AllocationDocumentID>USSA-1805-2022-1-1</AllocationDocumentID>
<AllocationDocumentItem actionCode = "02">
<AllocationDocumentItemID>10</AllocationDocumentItemID>
<InboundDeliveryID>5079</InboundDeliveryID>
<InboundDeliveryItemID>10</InboundDeliveryItemID>
<Percent>30</Percent>
</AllocationDocumentItem>
<AllocationDocumentItem actionCode = "02">
<AllocationDocumentItemID>20</AllocationDocumentItemID>
<InboundDeliveryID>5079</InboundDeliveryID>
<InboundDeliveryItemID>20</InboundDeliveryItemID>
<Percent>15</Percent>
</AllocationDocumentItem>
</AllocationDocumentMaintainBundle> </n0:AllocationDocumentMaintainBundleRequest_Sync>
<cancelAllocationDocument>true</cancelAllocationDocument>
<checkAllocationDocument>true</checkAllocationDocument>
<n0:AllocationDocumentMaintainBundleRequest_Sync xmlns:n0="http://sap.com/xi/SAPGlobal20/Global">
<BusinessDocumentBasicMessageHeader>
<ID></ID>
<UUID></UUID>
<ReferenceID></ReferenceID>
<ReferenceUUID></ReferenceUUID>
</BusinessDocumentBasicMessageHeader>
<AllocationDocumentMaintainBundle actionCode="03" itemListCompleteTransmissionIndicator="true">
<ObjectNodeSenderTechnicalID>1</ObjectNodeSenderTechnicalID>
<ChangeStateID></ChangeStateID>
<AllocationDocumentID>USSI-705-1-1</AllocationDocumentID>
<AllocationDocumentItem actionCode="03">
<AllocationDocumentItemID>10</AllocationDocumentItemID>
<InboundDeliveryUUID></InboundDeliveryUUID>
<InboundDeliveryItemUUID></InboundDeliveryItemUUID>
<InboundDeliveryID>319</InboundDeliveryID>
<InboundDeliveryItemID>10</InboundDeliveryItemID>
</AllocationDocumentItem>
</AllocationDocumentMaintainBundle>
</n0:AllocationDocumentMaintainBundleRequest_Sync>
| Description | Check allocation documents |
| Name | CheckMaintainBundle |
| Synchronous | yes |
| Release Status | Released |
To simulate creation,deletion or the update of allocation documents.
The web service request and response message types of the CheckMaintainBundle operation are the same as those of the MaintainBundle operation.
The explanations given in MaintainBundle operation can therefore also be applied to the CheckMaintainBundle operation.
Show full documentation