Show TOC

Programming with ABAP SMI ODataLocate this document in the navigation structure

This section explains how to use the ABAP SMI APIs for consuming OData services.

ABAP Social Media Integration (ABAP SMI) is located in the main package AR_FND_SM_MAIN. The ABAP SMI API offers ABAP classes and methods for consuming OData services provided by collaboration platforms such as SAP Jam.

The high-level procedure for using the ABAP SMI API in your code is as follows:
  1. Get an ABAP SMI API instance.
  2. Build a request.

    Depending on the OData endpoint that you want to access, you may also need to specify header fields or a request body.

  3. Submit the request.
  4. Collect the result.

These steps are described in the following sections, illustrated by sample code snippets.

Caution When you use ABAP SMI to connect your application to SAP Jam, your application is responsible for checking the input and the result of requests with respect to security and correctness issues. Typical scenarios include, but are not limited to the following:
  • File upload/download: Make sure that file content is not corrupt or infected.
  • Building request URLs: Make sure that special characters in URL strings or substrings are correctly escaped.
    Example To achieve this, use method escape in class CL_CLB2_TOOLS. An example can be found in the scenario test class CL_JAM_SCENARIO, local test class TC_ODL_GROUP, method upload_nonascii_file_to_group.