Prepare SAP S/4HANA Public Cloud for the integration


Activate services


Setup integration package


Authentication for S/4HANA Public Cloud

These steps are typically done by a SAP Consultant or developer - they will be able to help you prepare SAP S4/HANA Public Cloud for the integration with Pleo.


If you have SAP S/4HANA On Premise - follow this guide instead.


1. Activate services

Service name

Type

Description

Documentation
JournalEntryCreateRequestConfirmation_InSOAPService for synchronous journal entry processing in S4/HANA Public CloudJournal Entry API 
API_CV_ATTACHMENT_SRVODATAService for document attachment managementAttachments API
API_COMPANYCODE_SRVODATAService for reading Company informationCompany code API
API_COSTCENTER_SRVODATAService for reading Cost CentersCost Center API
API_FINWBSELEMENT_SRVODATAService for reading WBS elementsWBS elements API


1. SOAP services
  1. Navigate to Communication Systems 
  2. Click New
  3. Enter System ID and System Name
  4. Click Create
  5. On the new Communication Systems overview, enter the Host Name or System ID
  6. Navigate to the Users for Inbound Communication tab 
  7. Click + and select New User in the pop-up window
  8. Enter the User name, Description and password 
  9. Click Create
    • In case of Client Certificate authentication:
      1. Click Upload and choose the file from local storage
      2. For Authentication Method choose SSL Certificate
  10. Click Save
  11. Navigate to Communication Arrangements
  12. Click NEW
  13. Enter the details required:
    • Scenario: SAP_COM_0002 
    • Arrangement Name: Arrangement name
  14. Click Create
  15. Choose the created Communication System created
  16. Go to Outbound services
  17. Switch off all Service Status checkboxes
  18. Click Save
  19. Copy and save the API-URLfor:
    • Service URL
    • Journal Entry - Post (synchronous)


 2. OData services
  1. Go to Communication Arrangements
  2. Click New
  3. Enter the details required:
    • Scenario: SAP_COM_0087
    • Arrangement Name: Arrangement name
  4. Click Create
  5. Choose the in step 1.1 created Communication System created 
  6. Click Saveto activate:
    • API_FINWBSELEMENT_SRV
    • API_COSTCENTER_SRV
    • API_COMPANYCODE_SRV


 3. Authentication for S/4HANA Public Cloud
  1. Within the SAP BTP subaccount level click Services and navigate to Instances and Subscriptions 
  2. Click cf-api instance
  3. Click view credentials in the right window
  4. Copy and save values:
    1. Clientid
    2. Clientsecret
    3. Tokenurl
  5. Go to SAP CPI Monitor tab
  6. Click Security Material
  7. Click Create
  8. Choose OAuth2 Client Credentials
  9. Past the values (clientid, clientsecret, tokenurl) copied earlier
  10. Click Deploy
    • For Basic authentication:
      1. Go to SAP CPI Monitor tab
      2. Click Security Material
      3. Click Create
      4. For Type choose User credentials
      5. Enter the details set up in step 1.1
      6. Click Deploy
    • For Client Certificate Authentication:
      1. Go to Monitor/Keystore
      2. Click Add
      3. Choose Certificate
      4. Upload the certificate document
      5. Click Add


2. Setup integration package

Install integration package

  1. Within Design go to Integrations and APIs
  2. Click Import 
  3. Select the Pleo Integration with SAP S/4HANA Public Cloud integration package downloaded


3. Integration package configuration

1. Within Pleo Integration with SAP S4/HANA Public Cloud integration package, navigate to Artifacts


2. Click the icon and choose configure for Create Parameter in Value mapping
  1. For Receiver, enter the following details:
    • CPI_API_HOST: URL value from step 1.3
    • Credential Name: Name of the OAuth2 Client Credentials deployed in step 1.3
  2. Click Deploy


3. Click the icon and choose configure for Create Company settings in Value mapping
  1. Under Receiver
    1. For R_CPI_API_Flowreceiver, Enter the following details 
      • CPI_API_HOST: URL value from step 1.3
      • Credential Name: Name of the OAuth2 Client Credentials deployed in step 1.3
    2. For R_Pleo, enter the URL to the Pleo API Integration
  2. Under More, provide the necessary company settings:
    • CompanyID_S4: Company code from S4/HANA
    • CompanyName: Name of company in Pleo
    • CreatedBy_S4: Name of technical user in S4/HANA configured in step 1.3
    • Token: API token generated for S4/Hana in the Pleo Account settings
  3. Click Deploy


4. Click the icon and choose configure for Create Account Settings in Value mapping
  1. Under Receiver, for R_CPI_API, enter the following details:
    • CPI_API_HOST: URL value from step 1.3
    • Credential Name: Name of the OAuth2 Client Credentials deployed in step 1.3
  2. Under More, provide the necessary company settings:
    • Account_AccountsPayable: Vendor reconciliation account used in invoice and invoice payment journal entries
    • Account_Pocket: General ledger account used for out-of-pocket, mileage and per diem journal entries
    • Account_Reimbursement: General ledger account used for external and direct reimbursement journal entries
    • Account_Wallet: General ledger account used for card purchase, refund and chargeback journal entries
    • CompanyName: Name of the company in Pleo
    • Type_Atm_Withdrawal: Type of journal entry in S4 for ATM withdrawals
    • Type_Card_Invoice: Type of journal entry in S4 for card invoice
    • Type_Card_Purchase: Type of journal entry in S4 for card purchases
    • Type_Cashback: Type of journal entry in S4 for cashbacks
    • Type_Chargeback: Type of journal entry in S4 for chargebacks
    • Type_Direct_Reimbursement: Type of journal entry in S4 for direct reimbursements
    • Type_External_Reimbursement: Type of journal entry in S4 for external reimbursements
    • Type_Invoice: Type of journal entry in S4 for invoices
    • Type_Invoice_Payment: Type of journal entry in S4 for invoice payments
    • Type_Mileage: Type of journal entry in S4 for mileage claims
    • Type_Out_Of_Pocket: Type of journal entry in S4 for out-of-pocket expenses
    • Type_Per_Diem: Type of journal entry in S4 for per diem
    • Type_Refund: Type of journal entry in S4 for refunds
  3. Click Deploy


5. Click the icon and choose configure for Create Tag Export Settings in Value mapping
  1. Under Receiver, for R_CPI_API, enter the following details:
    • CPI_API_HOST: URL value from step 1.3
    • Credential Name: Name of the OAuth2 Client Credentials deployed in step 1.3
  2. Under More, provide the necessary company settings:
    • CompanyName: Name of company in Pleo
    • S4_CostCenter_Category: Category codes for CostCenter separated by ,
    • S4_InternalOrder_ControllingArea: Code for InternalOrder Controlling Area (1 value only)
    • S4_InternalOrder_OrderType: Code for InternalOrder Order Type (1 value only)
    • S4_WBS_Project: Filter value for project assignments separated by ,
  3. Click Deploy


6. Click the icon and choose configure for Create Tag Group in Pleo
  1. Under Receiver
    1. For R_CPI_API_Flowreceiver, Enter the following details 
      • CPI_API_HOST: URL value from step 1.3
      • Credential Name: Name of the OAuth2 Client Credentials deployed in step 1.3
    2. For R_Pleo, enter the URL to the Pleo API Integration
  2. Under More, provide the necessary company settings:
    • CompanyName: Name of company in Pleo
    • TG_CostCenter: Name of tag group for CostCenter in Pleo
    • TG_InternalOrder: Name of tag group for InternalOrder in Pleo
    • TG_WBS: Name of tag group for WBS element in Pleo
  3. Click Deploy


7. Click the icon and choose configure for Export Expenses from Pleo to S4
  1. Under Receiver
    1. For R_PLEO_JOBS_API, enter the URL to the Pleo API Integration
    2. For R_S4_CREATE_ENTRY, enter the following details:
      • Address: URL address of SOAP API activated in step 1.1
      • Authentication: Basic / Client Certificate
        • For Basic Credential Name: Name of User Credential from Security Store from step 1.3
        • For Client Certificate Private key alias: Name of certificate Alias from Keystore from step 1.3
    3. For R_S4_PING, provide S4_URL parameter as an address to Cloud connector from step 1.1
  2. Click Deploy


8. Click the icon and choose configure for Export Tags from Pleo to S4
  1. Under Receiver
    1. For R_PLEO API, enter the URL to the Pleo API Integration
    2. For R_S4, enter the following details:
      • S4_Host: URL address of S4 API
      • Authentication: Basic / Client Certificate
        • For Basic Credential Name: Name of User Credential from Security Store from step 1.3
        • For Client Certificate Private key alias: Name of certificate Alias from Keystore from step 1.3
    3. Under More, provide the necessary company settings:
      • DateTimeFormat_S4: date/time format value
      • WBSODataV2: True (indicator that S4/HANA system version is less than 2021 FPS01)
  2. Click Deploy


9. Click the icon and choose configure for Schedule Expenses Export from Pleo to S4
  1. Under Receiver
    1. For R_CPI_APIreceiver, Enter the following details 
      1. CPI_API_HOST: URL value from step 1.3
      2. Credential Name: Name of the OAuth2 Client Credentials deployed in step 1.3
    2. For R_Pleo, enter the URL to the Pleo API Integration
  2. Under More, provide the necessary company settings:
    • BypassTransactionDate: True / False (Indicator shows the requirement to update the transaction date in S4/HANA)
    • UploadReceipts: True / False (Indicator shows the requirement to upload attachments to S4/HANA)
    • ClosingPeriodDay: Specific day of the month (1-31) after which past expenses will be updated
  3. Click Deploy


10. Click the icon and choose configure for Schedule Tags Export from Pleo to S4
  1. Under Receiver
    1. For R_CPI_APIreceiver, Enter the following details 
      • CPI_API_HOST: URL value from step 1.3
      • Credential Name: Name of the OAuth2 Client Credentials deployed in step 1.3
    2. Click Deploy




Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article