Creating the configuration object for SAP API Management

Introduction

The configuration shown below as the example is based on the following API.

 

PROCEDURE:

  1. Create a new object definition with a description and the name of the tested SAP API.

  2. In Object Variables Settingsdefine variables names and descriptions. 

  3. In Variable Processing, define actions and variable processors that will process each of the variable's data.

  4. In Database Comparison Rules define Table Names of those tables that should be compared. 

  5. In Selection Criteria define how Int4 IFTT should locate those tables, e.g., by a reference to which value.

  6. In Comparison Details define a set of fields to be compared and rules to be applied.

  7. Define Additional Parameters
    For API Testing, some additional parameters are required that define what API is tested.

    1. ALT_RFC - alternative RFC connection created in SM59 where the message should be sent. In the shown example, RFC API_MGMT is used for this purpose.


      This RFC in the Target Host should the link you can find your API Portal under Host Alias.



    2. SYNC_URL (3)- direct endpoint to the tested SAP API. This parameter should be the value you can find in your API Portal for the tested API under API Base Path.

       

    3. HTTPHEADER (2)(4)(5) -  Values added to the custom header while sending the message. These parameters are optional, and they are dependent on the tested API.

  8. Define Number Ranges that can be used, e.g., to generate values for messages created after the test case execution. 

For more details about the Int4 IFTT Automation Object definition, visit this page: https://int4support.atlassian.net/wiki/spaces/IUM/pages/50153 .

 

HANDLING AUTHORIZATION POLICIES

In case of testing interfaces with specific authorization requirements e.g. protected with OAuth VerifyAccessToken policy it is possible to specify additional authorization request with Additional Parameter AUTH_REQ. This parameter should contain number of test case used for obtaining additional authorization data like access tokens. All variables from this authorization request can be used to populate HTTP headers of interface under test. These variable should be prefixed with ‘AUTH_’.

Example:

Configuration of automation object for OAuth protected interface:

Access token is fetched by test case 31729 which is configured to return the token in ACCESS_TOKEN variable.

 

© 2017 - 2022 Int4 AG All rights reserved