# SAP MM BAPI List (Plus QM BAPIs and S/4HANA APIs) with Commit Notes

> Source: https://netray.co/tools/sap-mm-bapi-and-api-list-reference
> Publisher: Netray (netray.co), AI and integration engineering for ERP and manufacturing systems.
> Section: Free Tools

## Short answer

A searchable list of the common SAP MM and QM BAPIs and S/4HANA OData APIs, what each does, and whether it needs a commit.

## Category

sap

## Erp

SAP ECC / S/4HANA

## Audience

- SAP developer
- Integration engineer
- MM consultant

## Tool

**Kind:** worksheet

**Mode:** reference

**Columns:**

#### BAPI or API

**Key:** name

**Type:** text

#### Area

**Key:** area

**Type:** text

#### What it does

**Key:** does

**Type:** text

#### Key parameters and notes

**Key:** notes

**Type:** text

**Rows:**

#### BAPI_PO_CREATE1

**Area:** MM-PUR

**Does:** Create a purchase order

**Notes:** POHEADER and POHEADERX, POITEM and POITEMX, POSCHEDULE and POSCHEDULEX; RETURN table; needs BAPI_TRANSACTION_COMMIT

#### BAPI_PO_CHANGE

**Area:** MM-PUR

**Does:** Change a purchase order

**Notes:** PURCHASEORDER plus changed structures and their X flag structures; commit required

#### BAPI_PO_GETDETAIL1

**Area:** MM-PUR

**Does:** Read PO header, items, schedule lines

**Notes:** Read only, no commit; returns PO_HEADER, PO_ITEMS and PO_ITEM_SCHEDULES

#### BAPI_PO_RELEASE

**Area:** MM-PUR

**Does:** Release a PO with a release code

**Notes:** PURCHASEORDER, PO_REL_CODE; commit required

#### BAPI_PR_CREATE

**Area:** MM-PUR

**Does:** Create a purchase requisition

**Notes:** PRHEADER, PRITEM and PRITEMX; commit required. BAPI_REQUISITION_CREATE is the older equivalent

#### BAPI_REQUISITION_RELEASE

**Area:** MM-PUR

**Does:** Release a requisition

**Notes:** NUMBER, REL_CODE, ITEM; commit required

#### BAPI_CONTRACT_CREATE

**Area:** MM-PUR

**Does:** Create an outline agreement (contract)

**Notes:** HEADER, ITEM with their X structures; commit required

#### BAPI_GOODSMVT_CREATE

**Area:** MM-IM

**Does:** Post a goods movement (receipt, issue, transfer)

**Notes:** GOODSMVT_HEADER, GOODSMVT_CODE (for example 01 goods receipt for PO), GOODSMVT_ITEM; commit required

#### BAPI_MATERIAL_SAVEDATA

**Area:** MM-MD

**Does:** Create or change a material master

**Notes:** HEADDATA plus plant, storage, valuation structures and X flag structures; commit required

#### BAPI_MATERIAL_GET_DETAIL

**Area:** MM-MD

**Does:** Read material master data

**Notes:** MATERIAL, PLANT, VALUATIONAREA; read only

#### BAPI_MATERIAL_AVAILABILITY

**Area:** MM-IM

**Does:** Check availability (ATP) of a material

**Notes:** Read only; returns available quantity by date

#### BAPI_INCOMINGINVOICE_CREATE

**Area:** MM-IV

**Does:** Post a logistics invoice (like MIRO)

**Notes:** HEADERDATA, ITEMDATA; commit required. BAPI_INCOMINGINVOICE_PARK parks it

#### BAPI_TRANSACTION_COMMIT

**Area:** General

**Does:** Commit the pending BAPI changes

**Notes:** Call after a successful BAPI, with WAIT = X when the next step needs the data

#### BAPI_TRANSACTION_ROLLBACK

**Area:** General

**Does:** Roll back the pending BAPI changes

**Notes:** Call when RETURN contains type E or A messages

#### BAPI_INSPLOT_GETDETAIL

**Area:** QM

**Does:** Read an inspection lot

**Notes:** NUMBER = inspection lot; read only

#### BAPI_INSPOPER_GETDETAIL

**Area:** QM

**Does:** Read inspection operations and characteristics

**Notes:** Read only

#### BAPI_INSPOPER_RECORDRESULT

**Area:** QM

**Does:** Record inspection results

**Notes:** Characteristic results per operation; commit required

#### BAPI_INSPLOT_SETUSAGEDECISION

**Area:** QM

**Does:** Make the usage decision for a lot

**Notes:** NUMBER, UD_DATA; commit required

#### BAPI_QUALNOT_CREATE

**Area:** QM

**Does:** Create a quality notification

**Notes:** NOTIF_TYPE, NOTIFHEADER; follow with BAPI_QUALNOT_SAVE and commit

#### BAPI_QUALNOT_GETDETAIL

**Area:** QM

**Does:** Read a quality notification

**Notes:** Read only

#### API_PURCHASEORDER_PROCESS_SRV

**Area:** S/4HANA OData

**Does:** Create, read and change purchase orders

**Notes:** Published on SAP Business Accelerator Hub; uses CSRF token for writes

#### API_PURCHASEREQ_PROCESS_SRV

**Area:** S/4HANA OData

**Does:** Create, read and change purchase requisitions

**Notes:** OData V2 service; check available entity sets on the hub

#### API_MATERIAL_DOCUMENT_SRV

**Area:** S/4HANA OData

**Does:** Post and read material documents

**Notes:** Goods movements through OData instead of BAPI_GOODSMVT_CREATE

#### API_PRODUCT_SRV

**Area:** S/4HANA OData

**Does:** Read and maintain products (materials)

**Notes:** Product master through OData; check supported fields per release

#### API_SUPPLIERINVOICE_PROCESS_SRV

**Area:** S/4HANA OData

**Does:** Create and read supplier invoices

**Notes:** Replacement route for invoice BAPIs in cloud-style integration

#### API_INSPECTIONLOT_SRV

**Area:** S/4HANA OData

**Does:** Read and process inspection lots

**Notes:** QM inspection lot service; confirm the entity sets for your release on the hub

**Notes:** Always read the RETURN table after a BAPI call and check for message types E and A before you commit. Parameter lists are summarized, so confirm the exact structures in SE37 for your release and the OData metadata in the SAP Business Accelerator Hub. Your landscape may also expose newer APIs than the ones listed.

## Content

**Intro:** Integrations with SAP MM and QM usually go through BAPIs in ECC and through OData APIs in S/4HANA. This list gives the commonly used ones with what they do, the main parameters and whether you need to commit afterwards.

**Sections:**

#### How to use the list

**Body:** Search by object, such as purchase order, goods movement or inspection lot. Note the commit column: write BAPIs change data only in memory until you call BAPI_TRANSACTION_COMMIT, and read BAPIs need none. Open the function module in SE37 to see the exact import, export and table parameters before you code against it.

**Bullets:**

- Write BAPI, then check RETURN for E and A messages, then commit or roll back.
- Pass an X structure for every field you want to set or change.
- Use WAIT = X on the commit when a following call reads the new data.

#### BAPIs versus S/4HANA OData APIs

**Body:** BAPIs are remote-enabled function modules called through RFC from an ABAP or middleware client. OData APIs are web services published for S/4HANA, listed on the SAP Business Accelerator Hub with their entity sets and sample payloads. For new cloud or hybrid integrations OData is usually preferred because it passes through the gateway and respects released API contracts. On-premise systems often keep using BAPIs for batch jobs.

#### Commit and error handling

**Body:** Every BAPI returns messages in a RETURN structure or table. A type S or W message is acceptable; E or A means nothing should be committed. Wrap the call so that errors trigger BAPI_TRANSACTION_ROLLBACK. For bulk loads, commit per document rather than per file, so a bad row does not block a thousand good ones. Log the PO or document number returned by the call.

#### Common mistakes

**Body:** Developers often forget the X flag structure, so fields are silently ignored, skip the commit and see no document, or call BAPI_GOODSMVT_CREATE with the wrong GOODSMVT_CODE. Another trap is testing in a client without the right authorizations, then seeing different results in production. Test with the same user role as the production interface.

**Cta:** If you are building integrations or AI agents that write to SAP, we can help design a human-approved write-back pattern around these BAPIs and APIs, with the data staying in your environment.

**Faq:**

#### What are the main BAPIs for SAP MM?

**Answer:** The common ones are BAPI_PO_CREATE1 and BAPI_PO_CHANGE for purchase orders, BAPI_GOODSMVT_CREATE for goods movements, BAPI_MATERIAL_SAVEDATA for material master, BAPI_INCOMINGINVOICE_CREATE for invoices and BAPI_PR_CREATE for requisitions. Most of them need a commit afterwards.

#### Do I need BAPI_TRANSACTION_COMMIT after every BAPI?

**Answer:** After every BAPI that writes data, yes, once you have confirmed that the RETURN table has no error messages. Read-only BAPIs such as BAPI_PO_GETDETAIL1 do not need it. If errors appear, call BAPI_TRANSACTION_ROLLBACK instead.

#### What APIs does S/4HANA offer for MM and QM?

**Answer:** S/4HANA publishes OData services such as API_PURCHASEORDER_PROCESS_SRV, API_MATERIAL_DOCUMENT_SRV and API_INSPECTIONLOT_SRV, listed with their entity sets on the SAP Business Accelerator Hub. They use standard HTTP calls with a CSRF token for changes.

#### Why are my BAPI fields not saved?

**Answer:** Most change and create BAPIs use a second structure with an X flag per field. If the X structure does not mark the field, SAP ignores the value without an error. Fill both the value and the matching X structure, then inspect the RETURN table.

## Search terms

sap mm bapi list, sap mm bapi, sap mm api, sap qm api, sap qm bapi, sap s/4hana api documentation, bapi_po_create1 parameters, bapi_goodsmvt_create, bapi_material_savedata, sap business accelerator hub

---
Talk to an engineer: https://netray.co/contact?intent=erp_ai | Machine catalog: https://netray.co/agent/catalog.json
