BAPI_INCOMINGINVOICE_PARK — BAPI_INCOMINGINVOICE_PARK for Invoice Parking
BAPI_INCOMINGINVOICE_PARK parks an incoming vendor invoice in Logistics Invoice Verification, mirroring transaction MIR7 rather than MIRO. It creates a document that exists in the system for review, workflow approval, or correction but has not posted to FI. It requires an explicit BAPI_TRANSACTION_COMMIT and demands full inspection of the RETURN table, since a returned document number does not by itself confirm success.
This page covers what BAPI_INCOMINGINVOICE_PARK does, its main interface structures, and why callers routinely misread its success signals. It focuses on the commit trap, the RETURN table inspection discipline, and the data quality problems that surface later when a loosely-validated parked document is eventually posted or released.
Published 16 Sept 2026· 1,094 words
What it does
The BAPI acts on the incoming invoice object in Logistics Invoice Verification and mirrors the park function of transaction MIR7, as distinct from BAPI_INCOMINGINVOICE_CREATE, which mirrors direct posting via MIRO. A parked document is stored in the invoice verification tables but has no FI document assigned and no impact on vendor open items, GR/IR clearing, or PO history until it is later completed and posted. Parking is used where the invoice amount, tax data, or account assignment needs review, where a workflow approval step is required before financial posting, or where the invoice is entered against a PO that has not yet been fully goods-receipted. Because SAP relaxes several checks for parked documents that it enforces for posted ones, the BAPI accepts data that BAPI_INCOMINGINVOICE_CREATE would reject outright.
Important parameters
- HEADERDATA - invoice header: invoicing party, document date, posting date, gross invoice amount, currency, company code and reference document type
- ITEMDATA - line items tied to a purchase order and item, carrying quantity, amount, tax code and PO reference for goods or service items
- ACCOUNTINGDATA - account assignment detail for items not fully covered by the PO account assignment, such as cost center or order splits
- GLACCOUNTDATA - direct G/L account line items for invoices with a G/L account assignment rather than a PO reference
- TAXDATA - tax code and tax amount breakdown per item, required to reconcile with the header gross amount
- WITHTAXDATA - withholding tax lines for vendors subject to withholding tax calculation
- VENDORITEMSPLITDATA - splits the vendor line into multiple payment items with different due dates or payment terms
- RETURN - table of BAPIRET2 structures carrying every message generated during the parking attempt
- INVOICEDOCNUMBER - export parameter returning the number assigned to the parked document
- FISCALYEAR - export parameter returning the fiscal year of the parked document
Commit behaviour
The BAPI does not commit on its own. It builds the parked document in the update task and returns a document number and fiscal year that exist only inside the current LUW until BAPI_TRANSACTION_COMMIT is called explicitly by the caller. Programs that call the BAPI and then close the RFC session, or that branch away on an error condition without either committing or rolling back, leave the database in an inconsistent state: the caller believes a document number was assigned, but nothing is persisted. This is the single most common defect in custom parking programs, and it produces intermittent, hard-to-reproduce gaps where a document number appears in a log file but never shows up in the invoice verification tables.
Return handling
RETURN is a table, not a flag, and every line must be inspected. Reading only the first line, only the last line, or only checking whether INVOICEDOCNUMBER is populated are all common interface bugs that produce false positives. Because parking tolerates more inconsistency than posting, a batch of messages with type W or I is normal even on a fully successful park, so a naive check that treats any non-empty RETURN table as failure causes valid documents to be rejected by the calling program. The correct pattern loops the full table and tests specifically for message type E or A anywhere in it, since a genuine blocking error can appear several lines into a table that also contains harmless warnings about tolerance limits or price variance. A second, subtler bug appears when the calling program filters RETURN by a specific message ID or number it expects, missing a differently-coded error from a user exit or a custom validation that fires during parking and silently drops the invoice.
ECC vs S/4HANA
BAPI_INCOMINGINVOICE_PARK remains valid and in active use on S/4HANA on-premise and private cloud editions for custom integrations that need to park rather than post directly. There is no dedicated released successor API specifically for parking that has broadly displaced it. Fiori-based supplier invoice processing apps use their own backend service layer rather than calling this BAPI directly, but for RFC-based interfaces, custom uploads, and legacy integration programs, this BAPI is still the standard mechanism to reach MIR7-equivalent parking behaviour.
Common pitfalls
- Company code, plant or PO item data that would fail hard validation during posting is accepted during parking, and the inconsistency only surfaces later when the document is released or converted to a posted invoice
- PO history mismatches when ITEMDATA references an item that is already fully invoiced, blocked, or deleted, producing a park that later cannot be completed
- Duplicate invoice checks that run at posting time are bypassed or weakened at parking time, allowing the same vendor invoice number to be parked twice before anyone notices
- Tax code and header currency inconsistencies between HEADERDATA and TAXDATA that round differently than expected, discovered only when the finance team tries to post the parked document
- Withholding tax relevant vendors parked without WITHTAXDATA, so the invoice later posts without the withholding line the vendor master requires
- Batch jobs calling the BAPI in a loop without a commit after each successful park, so an error partway through the loop rolls back documents that appeared to succeed earlier in the same run
Whose problem this is
Interface failures, missing commits, and RETURN table misreads are development problems, evidenced by a debug trace or a dump showing INVOICEDOCNUMBER filled but no corresponding document in the invoice verification tables. Tolerance limits, tax code determination, withholding tax setup, and account assignment rules that cause valid-looking parks to fail later at posting are functional configuration issues, evidenced by the relevant IMG settings and a comparison against a manually parked document via MIR7 with identical data.
Related SAP objects
Reviewed pages this object connects to in the ERPClimb knowledge graph.
Source: ERPClimb — https://erpclimb.com/sap-bapis/bapi-incominginvoice-parkERPClimb is an independent platform and is not affiliated with SAP SE. Reference pages are written and reviewed by SAP consultants for learning and troubleshooting.