SAP (ABAP)
Complete setup of the ABAP-based SAP integration with Bilendo.
Version: 2.2 · As of: 2026 · Target audience: SAP Consultant / ABAP Developer
Purpose
This document describes the complete setup of the Bilendo SAP integration. When you finish, an SAP system will be able to automatically transfer master and transaction data to Bilendo and write selected fields (dunning level, credit limit, etc.) back from Bilendo.
Table of Contents
| No. | Document | Content |
|---|---|---|
| 00 | 00 - Overview | This page – overview, architecture diagram, checklist |
| 01 | 01 - Architecture & Data Flow | System landscape, data flow, responsibilities |
| 02 | 02 - DDIC Structures | Structures ZFI_S_BILENDO_BSEG, ZFI_S_BILENDO_KNA1, table types |
| 03 | 03 - Assist Class | Complete code for ZCL_FI_BILENDO_ASSIST_V2 (definition + implementation) |
| 04 | 04 - Extractor Report | Report ZFI_BILENDO_EXPORT_V2 – Data extraction from SAP |
| 05 | 05 - Re-Integrate Report | Report ZFI_BILENDO_IMPORT_V2 – Writing field values back to SAP |
| 06 | 06 - Data Specification | Field definitions, required fields, formats, clearing logic |
| 07 | 07 - Variants & Job Scheduling | Selection variants, dynamic date fields, SM36 scheduling |
| 08 | 08 - Data Transport | SFTP configuration, file names, monitoring |
| 09 | 09 - Re-Integration Fields | Writing dunning level, credit limit, rating, etc. back to SAP |
| 10 | 10 - Transport & Installation | Transport request, abapGit, manual installation, post-installation |
Architecture Diagram
flowchart TB
subgraph SAP ["SAP ERP (FI-AR + optional SD)"]
direction TB
KNA1["KNA1 / KNB1\nCustomer master"]
BSID["BSID\nOpen items"]
BSAD["BSAD\nCleared items"]
VBAK["VBAK / VBAP\nOrders (sales orders)"]
STRUCT["DDIC structures\n• ZFI_S_BILENDO_BSEG\n• ZFI_S_BILENDO_KNA1\n• ZFI_S_BILENDO_VBAK"]
CLASS["ZCL_FI_BILENDO_ASSIST_V2\nAssist class"]
EXP["ZFI_BILENDO_EXPORT_V2\nExtractor report"]
IMP["ZFI_BILENDO_IMPORT_V2\nRe-integrate report"]
APPSERV["SAP application server\n/usr/sap/.../Bilendo_OUT/\n/usr/sap/.../Bilendo_IN/"]
end
subgraph TRANSFER ["Data transport"]
SFTP["SFTP / SAP CPI\nSeeburger / Lobster"]
end
subgraph BILENDO ["Bilendo platform"]
direction TB
IMPORT["Data import\n(automatic)"]
PLATFORM["Bilendo Core\nReceivables · Risk · Insights"]
EXPORT["Data export\n(write-back)"]
end
KNA1 --> CLASS
BSID --> CLASS
BSAD --> CLASS
VBAK --> CLASS
STRUCT -.-> CLASS
CLASS --> EXP
EXP -->|"TXT files\n(Customers, Open, Cleared, Orders)"| APPSERV
APPSERV -->|"Upload"| SFTP
SFTP -->|"Pick up files"| IMPORT
IMPORT --> PLATFORM
PLATFORM --> EXPORT
EXPORT -->|"CSV files\n(Limits, Rating, Dunning level)"| SFTP
SFTP -->|"Download"| APPSERV
APPSERV --> IMP
IMP -->|"BAPI / BDC"| SAP
style SAP fill:#e8f4f8,stroke:#2980b9,stroke-width:2px
style BILENDO fill:#e8f8e8,stroke:#27ae60,stroke-width:2px
style TRANSFER fill:#fef9e7,stroke:#f39c12,stroke-width:2pxData Flow in Detail
sequenceDiagram
participant SM36 as SM36 Job Scheduler
participant EXP as ZFI_BILENDO_EXPORT_V2
participant ASSIST as ZCL_FI_BILENDO_ASSIST_V2
participant FS as Application server
participant SFTP as SFTP
participant BIL as Bilendo
SM36->>EXP: Daily job (e.g., 03:00)
activate EXP
loop Per company code (T001)
EXP->>ASSIST: set_bukrs(bukrs)
EXP->>ASSIST: get_kna1()
ASSIST-->>EXP: at_kna1 (master data)
EXP->>ASSIST: kna1_file_to_server()
ASSIST->>FS: CC_Customers_..._V2.txt
EXP->>ASSIST: get_bsid()
ASSIST-->>EXP: at_bsid (open items)
EXP->>ASSIST: get_additional()
EXP->>ASSIST: bseg_file_to_server()
ASSIST->>FS: CC_open_..._V2.txt
EXP->>ASSIST: get_bsad()
ASSIST-->>EXP: at_bsad (cleared items)
EXP->>ASSIST: get_additional()
EXP->>ASSIST: bseg_file_to_server()
ASSIST->>FS: CC_cleared_..._V2.txt
EXP->>ASSIST: get_orders()
ASSIST-->>EXP: at_orders (orders)
EXP->>ASSIST: orders_file_to_server()
ASSIST->>FS: CC_orders_..._V2.txt
end
deactivate EXP
FS->>SFTP: File transfer (CPI/Seeburger/Lobster)
SFTP->>BIL: Read in files
BIL-->>BIL: Import & processingABAP Objects (Overview)
| Object | Type | Depends on | Create in |
|---|---|---|---|
ZFI_S_BILENDO_BSEG | DDIC structure | – | SE11 |
ZFI_S_BILENDO_KNA1 | DDIC structure | – | SE11 |
ZFI_S_BILENDO_VBAK | DDIC structure | – | SE11 |
ZFI_T_BILENDO_BSEG | Table type | ZFI_S_BILENDO_BSEG | SE11 |
ZFI_T_BILENDO_KNA1 | Table type | ZFI_S_BILENDO_KNA1 | SE11 |
ZFI_T_BILENDO_VBAK | Table type | ZFI_S_BILENDO_VBAK | SE11 |
ZFI_ADR6 | Table type | ADR6 | SE11 |
ZCL_FI_BILENDO_ASSIST_V2 | Class | Structures + table types | SE24 |
ZFI_BILENDO_EXPORT_V2 | Report | Class | SE38 |
ZFI_BILENDO_EXPORT_V2_D01 | Include | – | SE38 |
ZFI_BILENDO_EXPORT_V2_F01 | Include | – | SE38 |
ZFI_BILENDO_IMPORT_V2 | Report | Class | SE38 |
ZFI_BILENDO_IMPORT_F01 | Include | – | SE38 |
Order: Structures → Table types → Class → Reports
Installation Checklist
PHASE 1: DDIC objects (→ Doc 02)
[ ] ZFI_S_BILENDO_BSEG – Structure created and activated
[ ] ZFI_S_BILENDO_KNA1 – Structure created and activated
[ ] ZFI_S_BILENDO_VBAK – Structure created and activated
[ ] ZFI_T_BILENDO_BSEG – Table type created
[ ] ZFI_T_BILENDO_KNA1 – Table type created
[ ] ZFI_T_BILENDO_VBAK – Table type created
[ ] ZFI_ADR6 – Table type created (for email addresses)
PHASE 2: Class (→ Doc 03)
[ ] ZCL_FI_BILENDO_ASSIST_V2 – Definition created
[ ] ZCL_FI_BILENDO_ASSIST_V2 – Implementation of all methods (incl. delta methods)
PHASE 3: Extractor (→ Doc 04)
[ ] ZFI_BILENDO_EXPORT_V2 – Main report
[ ] ZFI_BILENDO_EXPORT_V2_D01 – D01 include (adjust paths + system IDs!)
[ ] ZFI_BILENDO_EXPORT_V2_F01 – F01 include
PHASE 4: Re-Integrate (→ Doc 05, optional)
[ ] ZFI_BILENDO_IMPORT_V2 – Import report
[ ] ZFI_BILENDO_IMPORT_F01 – Import include
PHASE 5: Configuration (→ Doc 07, 08)
[ ] Directories created on application server (DEV/QA/PRD)
[ ] Selection variant with dynamic date fields
[ ] Job created in SM36, released, periodicity set
PHASE 6: Data transport (→ Doc 08)
[ ] SFTP access received from Bilendo (host, port, user, key)
[ ] Middleware configured (CPI / Seeburger / Lobster / CLI)
[ ] Test files transferred and confirmed by Bilendo
PHASE 7: Acceptance
[ ] Test run DEV: Files visible on application server
[ ] Test run QA: Data visible in Bilendo staging
[ ] Go-live PRD: Automatic daily run confirmedContact & Copyright
ABAP codebase: Documentation: Bilendo GmbH