cancel
Showing results for 
Search instead for 
Did you mean: 

BAPI_ACC_DOCUMENT_POST Commit Behaviour and API_CV_ATTACHMENT_SRV Object Validation

09-03-2026 9:57 AM
MassimoC Explorer
15 views 0 comments
0 Likes
SAP Managed Tags
Subscribe

Dear SAP Community

We are seeking clarification on the transaction and object validation behaviour of SAP S/4HANA 2025 in the context of an automated process designed with SAP Build Process Automation to process accounting documents.

In SAP Build Process Automation our integration pattern is:

BAPI_ACC_DOCUMENT_POST

↓

Accounting Document Number Returned

↓

POST API_CV_ATTACHMENT_SRV / AttachmentContentSet

In S/4HANA 2025, we observed that an immediate attachment upload may intermittently return HTTP 400, while introducing a short delay (500 ms) eliminates the issue in our tests.

Questions

1. Does a successful return from BAPI_ACC_DOCUMENT_POST guarantee that the Accounting Document is already committed and visible in the database to subsequent HTTP/OData requests?

2. When the SAP Build BAPI SDK is configured with Commit = True, does it execute BAPI_TRANSACTION_COMMIT?

o If yes, is WAIT = 'X' used?

o Is the behaviour equivalent to COMMIT WORK or COMMIT WORK AND WAIT?

3. Could there be a delay between successful document posting and visibility of the document to API_CV_ATTACHMENT_SRV, even when the commit is successful?

4. What object or persistence layer is validated by AttachmentContentSet when uploading an attachment to an Accounting Document?

o Does the service validate directly against BKPF?

o Or through another business object/service layer?

5. Is adding a short delay or retry mechanism before calling AttachmentContentSet considered an acceptable integration pattern, or is there a preferred SAP-recommended approach?

It would be great to at least have some of the above questions answered so that we can align our SAP Build integration design with SAP best practices.

0 Likes

Accepted Solutions (0)

Answers (0)