How to use IBM App Connect with SAP (via OData)

SAP is an Enterprise Resource Planning (ERP) system. Using OData services you can create a connection and import data from the datasources.

Availability:
  • A connector in IBM App Connect on IBM CloudCloud-managed connector
  • A local connector in a Designer instance of IBM App Connect in containers (Continuous Delivery release)Local connector in containers (Continuous Delivery release) 11.0.0.10-r1 or later
  • A local connector in a Designer instance of IBM App Connect in containers (Extended Update Support)Local connector in containers (Extended User Support release)
  • A local connector in a Designer instance of IBM App Connect in containers (Long Term Support)Local connector in containers (Long Term Support release)

In IBM® App Connect Designer, as a business user (or anyone else wanting a simple integration experience) you can create integration flows that retrieve or create SAP OData resources and use data retrieved from SAP for other activities in the flow. The flows can be triggered by events in apps such as Salesforce, or by calling an API such as from mobile and web applications.

The following information describes how to use IBM App Connect to connect SAP (via OData) to your other applications.

Connecting to SAP (via OData)

If your SAP Gateway has been configured to use OData for SAP products, App Connect can access SAP OData resources in real time, to share SAP data with SaaS apps like Salesforce.com and with other apps and systems that App Connect can connect to. For two-way communication with SAP, App Connect uses an SAP OData 2.0 connector and the IBM Secure Gateway to connect to an SAP Gateway OData service in the private network that hosts the SAP system.

  1. Before you can use IBM App Connect Designer to connect to SAP, you need the following prerequisites:
    1. A well-defined SAP Gateway OData service that conforms to several requirements; your SAP objects should be defined without relationships, and your SAP service should be enabled with the sap:creatable:false flag. For more information about the requirement for an SAP service, see Creating a well-defined SAP Gateway OData service for use with IBM App Connect.
    2. A network in App Connect configured to enable access to an SAP Gateway system in a private network. If you want App Connect to connect to an SAP Gateway OData service in a private network, ensure that you have an existing network in App Connect defined for your private network, that the Access control list (ACL) for the network is configured to allow connections to the SAP system, and ensure that any firewall between the IBM Secure Gateway Client and the internet is configured to allow connections on the ports that you want App Connect to use. In App Connect, when connecting to SAP, you can select the option to create a new network. For information about creating a network in App Connect, see Configuring a private network.
  2. To connect App Connect to an SAP account that you want App Connect to use, you need the following connection details:
    SAP Gateway Service URL
    Specifies the URL to the SAP Gateway OData service. Use the URL value without an ending '/'; for example: http://9.111.222.34:8000/opu/odata/ZGW_ORDER_STATUS_SRV
    UserName
    Specifies the user name to use when connecting to the SAP Gateway OData service.
    Password
    Specifies the password to the user name when connecting to the SAP Gateway OData service.
    Network name
    The name of the Network defined in App Connect to connect to the private network used to access SAP.

To connect to SAP from the App Connect Designer Catalog page for the first time, under SAP click Connect. This creates an account in App Connect. For more information about ways to connect to SAP, see Managing accounts in App Connect.

Tip:

Before you use the account that is created in App Connect in a flow, rename the account to something meaningful that helps you to identify it. To rename the account on the Catalog page, select the account, open its options menu (⋮), then click Rename Account.

What should I consider first?

Before you use App Connect Designer with SAP (via OData), take note of the following considerations:

  • (General consideration) You can see lists of the trigger events and actions that are available on the Catalog page of the App Connect Designer.

    For some applications, the events and actions in the catalog depend on the environment (IBM Cloud Pak for Integration or App Connect on IBM Cloud) and whether the connector supports configurable events and dynamic discovery of actions. If the application supports configurable events, you see a Show more configurable events link under the events list. If the application supports dynamic discovery of actions, you see a Show more link under the actions list.

  • (General consideration) If you are using multiple accounts for an application, the set of fields that is displayed when you select an action for that application can vary for different accounts. In the flow editor, some applications always provide a curated set of static fields for an action. Other applications use dynamic discovery to retrieve the set of fields that are configured on the instance that you are connected to. For example, if you have two accounts for two instances of an application, the first account might use settings that are ready for immediate use. However, the second account might be configured with extra custom fields.
  • Before using the SAP connection in App Connect Designer, start the IBM Secure Gateway client that you configured for use with SAP. After starting the client, the Applications tab on the Catalog page in App Connect Designer should list the SAP objects and their actions that you can use; for example:
    Figure 1. SAP objects and their actions as listed on the Applications tab
    SAP objects and their actions as listed on the Applications tab
    Tip: If you start the IBM Secure Gateway client after logging in to App Connect Designer, you can refresh the Applications tab to see the list of SAP objects and their actions.
  • When App Connect makes a request to retrieve OData resources from SAP, the response is returned as an OData collection of structured entries. The entries are enriched with a __metadata name/value pair whose value is a JSON object of name/value pairs. To learn more about ways to handle such OData __metadata information in App Connect flows, see Ways of accessing SAP OData __metadata information in App Connect

Events and actions

SAP (via OData) events

These events are for changes in this application that trigger a flow to start performing the actions in the flow.

Note: Events are not available for changes in this application. You can trigger a flow in other ways, such as at a scheduled interval or at specific dates and times.

SAP (via OData) actions

These are actions on this application that you want a flow to complete.

Available items are listed when you have connected App Connect to SAP (via OData).

Examples

An event-driven flow that connects Eventbrite to SAP to retrieve OData resources

Creating an event-driven flow to retrieve SAP OData resources and act on Salesforce and SAP

Learn how easy it is to create an event-driven flow in App Connect Designer to retrieve OData resources from SAP and use that data to enhance actions on Salesforce and SAP.

An API flow that creates SAP OData resources and acts on Salesforce

Creating an API flow to create SAP OData resources

Learn how easy it is to create an API flow in App Connect Designer to create OData resources in SAP and act on Salesforce.

Troubleshooting

  • If you see the message 'We are unable to retrieve objects for SAP.', check the network that you selected for use with the SAP connection:
    • The IBM Secure Gateway client is running
    • The ACL for the IBM Secure Gateway is configured to allow connections to the host and port of the SAP system

    For example:

    Figure 2. Network page showing a connected network for SAP, with ACL that allows access to the SAP system
    Network page showing a connected network for SAP, with ACL that allows access to the SAP system

    (Click the image to see more of the Network page.)

    Figure 3. Secure Gateway ACL page for SAP network, with ACL that allows access to the SAP system
    Secure Gateway ACL page for SAP network, with ACL that allows access to the SAP system

    (Click the image to see more of the Secure Gateway ACL page.)

    If starting the IBM Secure Gateway client with the correct ACL does not display the list of SAP objects, also verify the following:
    • The computer on which the IBM Secure Gateway client is running is connected to the host of the SAP system (for example, can ping the IP address of the host)
    • The user name to use when connecting to the SAP Gateway OData service is authorized to pass through any internal firewalls between the IBM Secure Gateway client and the SAP system.