Sie sind auf Seite 1von 13

BAPIs

(Business Application Programming Interface)

Copyright 2006 Deloitte Development LLC. All rights reserved.

Agenda: 1. What is BAPI and why is it used? 2. Difference Between BDC and BAPI. 3. What is BOR? 4. Accessing Business Object 5. Accessing BAPIs 6. Advantages of BAPI 7. Standard and service BAPIs

8. BAPI Explorer

Copyright 2006 Deloitte Development LLC. All rights reserved.

3. What is BOR?
Business Object Repository: - It is the central access point for the SAP business object types and their
BAPIs T-Code : SWO1 The Business Object Repository (BOR) is the repository of Business Objects in the R/3 System. It contains SAP Business Objects and SAP Interface types methods and their attributes. - BAPIs are defined in the BOR(Business object repository) as methods of SAP business object types that carry out specific business functions - The BOR provides the following services in the BAPI context: 1.Storage of all relevant information 2.It ensures BAPI interface stability 3.It creates instances of SAP business objects 4.It manages BAPIs in release updates
Copyright 2006 Deloitte Development LLC. All rights reserved.

4. Accessing Business Object

Copyright 2006 Deloitte Development LLC. All rights reserved.

Accessing BAPIs

Copyright 2006 Deloitte Development LLC. All rights reserved.

1. What is BAPI and why is it used?

- BAPI: Business Application Programming Interface.

- It is yet another data transfer technique.


- Can be used in diverse languages / Development Environments(ABAP, Visual Basic, Java, C++, etc.)

- It acts like an interface between SAP and non SAP system.


- Can be called from diverse platforms (COM, CORBA, Unix)

Copyright 2006 Deloitte Development LLC. All rights reserved.

5. Accessing a BAPI - BAPIs (Business APIs) are special methods that are applied to SAP business objects stored in R/3's Business Object Repository (BOR), in order to perform specific business tasks such as creating a sales order or checking the availability of a material. - BAPIs can be accessed in two ways, 1. BAPI in the BOR through object-oriented method calls 2. RFC calls to the Function Modules on which the BAPI is based.

Copyright 2006 Deloitte Development LLC. All rights reserved.

2. Difference Between BDC and BAPI


BAPI is used for Uploading/Downloading the data from SAP to Non-SAP like BDC, provided we have an existing BAPI for that. BAPI also used as an interface between SAP or Non-SAP systems BAPI function modules will also do all the checks required for data integrity like Transactions for BDC.
In BDC we need to specify (while recording) all the standard validation in all the screens exclusively in program.and a note of all screen data is also to be given in BDC (i.e. Dynrpro fnam fval etc). But all these can be avoided in BAPI. BAPI will skip all the screen data and includes all the default validations by itself.

Copyright 2006 Deloitte Development LLC. All rights reserved.

6. Advantages of BAPI

These are Business Standard Easy to use and understand Object Oriented Access Compatible with Different Communication Technologies Openness( Access BAPI from all development platforms that support the SAP Remote Function ( RFC) Protocol.

Copyright 2006 Deloitte Development LLC. All rights reserved.

7. Standard and Service BAPIs

They provide basic functions and can be used for most SAP BO. The Object methods with BAPIs can differentiate between Instance Methods and Class Methods. Standard BAPIs: BAPIs for Reading Data : GetList Class GetDetail Instance GetStatus Instance ExistenceCheck Instance BAPIs for Creating or Changing Data : Create or CreateFromData Class Change Instance Delete and Undelete Instance BAPIs for Replicating BO Instances : Replicate and SaveReplica
Copyright 2006 Deloitte Development LLC. All rights reserved.

Service BAPIs

They provide basic help functions.


HelpValues.GetList (F4 help) BapiService.FieldHelpGetDocu BapiService.InterfaceGetDocu BapiService.TransactionCommit BapiService.Rollback BapiService.DataConversionInt2Ext1 BapiService.DataConversionEnt2Int1

Copyright 2006 Deloitte Development LLC. All rights reserved.

8. BAPI Explorer

The BAPI Explorer is the R/3 System working environment for developing BAPIs.

A BAPI interface is defined by:


-Import parameters -Export parameters

-Import/export (table) parameters


Each function module underlying a BAPI:
Supports the Remote Function Call (RFC) protocol. Has been assigned as a method to an SAP Business Object in the BOR. Is processed without returning any screen dialogs to the calling application.
Copyright 2006 Deloitte Development LLC. All rights reserved.

Business Object , BAPI and Function Module

Method (BAPI) CreatefromDat1

Business Object Sales Order

Function Module BAPI_SALESORDER_ CREATEFROMDAT1

Transaction Code : BAPI

Copyright 2006 Deloitte Development LLC. All rights reserved.

Das könnte Ihnen auch gefallen