SAP S/4HANA connector
The SAP S/4HANA connector lets you manage and synchronize accounts between SAP S/4HANA and IDM and Advanced Identity Cloud managed user objects. An SAP S/4HANA administrator account is required for this connector to work.
The SAP S/4HANA connector only supports SAP HANA Cloud. To connect to HANA DB use the SAP HANA Database connector. |
Before you start
Before you configure the connector, log in to your AWS administrator account and note the following:
- Username
-
Inbound Communication user of SAP S/4HANA.
- Password
-
Inbound Communication user password of SAP S/4HANA.
- Tenant ID
-
Which tenant the SAP S/4HANA instance is hosted on.
Install the SAP S/4HANA connector
If you are looking for the Advanced Identity Cloud application for this connector, refer to: |
You can download any connector from Backstage, but some are included in the default deployment for Advanced Identity Cloud, IDM, or RCS. When using an included connector, you can skip installing it and move directly to configuration.
Connector | IDM | RCS |
---|---|---|
No |
No |
Download the connector .jar file from Backstage.
-
If you are running the connector locally, place it in the
/path/to/openidm/connectors
directory, for example:mv ~/Downloads/saphana-connector-1.5.20.26.jar /path/to/openidm/connectors/
-
If you are using a remote connector server (RCS), place it in the
/path/to/openicf/connectors
directory on the RCS.
Configure the SAP S/4HANA connector
Create a connector configuration using the IDM admin UI:
-
From the navigation bar, click Configure > Connectors.
-
On the Connectors page, click New Connector.
-
On the New Connector page, type a Connector Name.
-
From the Connector Type drop-down list, select SAP S/4HANA Connector - 1.5.20.26.
-
Complete the Base Connector Details.
For a list of all configuration properties, refer to SAP S/4HANA Connector Configuration -
Click Save.
When your connector is configured correctly, the connector displays as Active in the admin UI.
Refer to this procedure to create a connector configuration over REST.
Test the SAP S/4HANA connector
Test that the configuration is correct by running the following command:
curl \ --header "X-OpenIDM-Username: openidm-admin" \ --header "X-OpenIDM-Password: openidm-admin" \ --header "Accept-API-Version: resource=1.0" \ --request POST \ "http://localhost:8080/openidm/system/saphana?_action=test" { "name": "saphana", "enabled": true, "config": "config/provisioner.openicf/saphana", "connectorRef": { "bundleVersion": "[1.5.0.0,1.6.0.0)", "bundleName": "org.forgerock.openicf.connectors.saphana-connector", "connectorName": "org.forgerock.openicf.connectors.saphana.SapHanaConnector" }, "displayName": "SAP HANA Connector", "objectTypes": [ "__ACCOUNT__", "__ALL__" ], "ok": true }
If the command returns "ok": true
, your connector has been configured correctly and can authenticate to the SAP S/4HANA system.
SAP S/4HANA remote connector
If you want to run this connector outside of PingOne Advanced Identity Cloud or IDM, you can configure the SAP S/4HANA connector as a remote connector. Java Connectors installed remotely on a Java Connector Server function identically to those bundled locally within PingOne Advanced Identity Cloud or installed locally on IDM.
You can download the SAP S/4HANA connector from here.
Refer to Remote connectors for configuring the SAP S/4HANA remote connector.
Use the SAP S/4HANA connector
The following SAP S/4HANA account attributes are supported by the SAP S/4HANA connector:
Attribute | Description |
---|---|
|
Unique identifier for a user. |
|
The external ID of the user. This can only include uppercase letters, numbers, |
|
Auto-generated user id. |
|
Auto-generated user id. |
|
Login username for the user. This can only include uppercase letters, numbers, |
|
First name of the user. Required. |
|
Last name of the user. Required. |
|
Middle name of the user. |
|
Status of the user. Either |
|
Gender of the user. Permitted values are |
|
Salutation of the user. Permitted values are |
|
Start date for the created user, in YYYY-MM-DD format. Required. |
|
End date for the created user, in YYYY-MM-DD format. |
|
Full name of the user. |
|
Academic title of the user. Permitted values are |
|
The correspondence language for the user. For example, |
|
Additional last name of the user. |
|
Birth name of the user. |
|
Nickname of the user. |
|
Initials of the user. |
|
Academic secondary title of the user. Permitted values are |
|
Supplemental titles of the user. Permitted values are |
|
Object with the following sub-attributes:
|
|
Email address of the user. |
|
Predefined code of the company of the user. Required. |
|
Status of the work agreement for the user. Permitted values are |
|
Language code for the user. |
|
What format dates should be displayed in. For example,
|
|
What format times should be displayed in. For example,
|
|
Time zone code of the user. |
|
What decimal notation numbers should be displayed in. Available codes:
|
|
Role assignment of the user. |
|
Unique ID of the work agreement associated with the user. |
|
External ID of the work agreement associated with the user. |
|
Role of the work agreement associated with the user. Permitted values are |
The following attributes are mapped in the connector automatically:
|
You can use the SAP S/4HANA connector to perform the following actions on an SAP S/4HANA account:
Create an SAP S/4HANA user
The following example creates a user with the minimum required attributes:
curl \ --header "X-OpenIDM-Username: openidm-admin" \ --header "X-OpenIDM-Password: openidm-admin" \ --header "Content-Type: application/json" \ --request POST \ --data '{ "__NAME__": "BJENSEN", "FirstName": "Barbara", "LastName": "Jensen", "StartDate": "2022-06-02", "PersonExternalID": "BJENSEN", "CompanyCode": 1010, "GenderCode": 2 }' \ "http://localhost:8080/openidm/system/saphana/__ACCOUNT__?_action=create" { "_id": "9980004320", "TimeFormatCode": "0", "PersonFullName": "Barbara Jensen", "__UID__": "9980004320", "FirstName": "Barbara", "UserID": "CB9980004320", "__NAME__": "BJENSEN", "DecimalFormatCode": "X", "StartDate": "2022-06-02", "LogonLanguageCode": "EN", "LastName": "Jensen", "PersonExternalID": "BJENSEN", "PersonUUID": "FA163EA9-3617-1EEC-B8DA-AD865EF3B625", "__ENABLE__": true, "TimeZoneCode": "CET", "EndDate": "9999-12-31", "DateFormatCode": "1" }
When you create a new user, you must specify at least:
See the list of available attributes for more information. |
Update an SAP S/4HANA user
You can modify an existing user with a PUT request, including all attributes of the account in the request. The following attributes can be modified on a user:
-
__USER__
-
PersonExternalID
-
FirstName
-
LastName
-
GenderCode
-
EmailAddress
-
PhoneInformation
-
PersonFullName
-
AcademicTitle
-
CorrespondenceLanguage
-
MiddleName
-
AdditionalLastName
-
BirthName
-
NickName
-
Initials
-
AcademicSecondTitle
-
NameSupplement
-
WorkAgreementStatus
-
CompanyCode
-
StartDate
-
EndDate
-
LockedIndicator
-
DateFormatCode
-
DecimalFormatCode
-
TimeFormatCode
-
TimeZoneCode
-
LogonLanguageCode
-
Role
When updating the validity period for a user, both |
For example, to add an email address to a user:
curl \ --header "X-OpenIDM-Username: openidm-admin" \ --header "X-OpenIDM-Password: openidm-admin" \ --header "Content-Type: application/json" \ --header "If-Match:*" \ --request PUT \ --data '{ "__NAME__": "BJENSEN", "FirstName": "Barbara", "LastName": "Jensen", "StartDate": "2022-06-02", "PersonExternalID": "BJENSEN", "CompanyCode": 1010, "GenderCode": 2, "EmailAddress": "bjensen@example.com" }' \ "http://localhost:8080/openidm/system/saphana/__ACCOUNT__/9980004320" { "_id": "9980004320", "TimeFormatCode": "0", "PersonFullName": "Barbara Jensen", "__UID__": "9980004320", "EmailAddress": "bjensen@example.com", "FirstName": "Barbara", "UserID": "CB9980004320", "__NAME__": "BJENSEN", "DecimalFormatCode": "X", "StartDate": "2022-06-02", "LogonLanguageCode": "EN", "LastName": "Jensen", "PersonExternalID": "BJENSEN", "PersonUUID": "FA163EA9-3617-1EEC-B8DA-AD865EF3B625", "__ENABLE__": true, "TimeZoneCode": "CET", "EndDate": "9999-12-31", "DateFormatCode": "1" }
Query SAP S/4HANA users
The following example queries all SAP S/4HANA users:
curl \ --header "X-OpenIDM-Username: openidm-admin" \ --header "X-OpenIDM-Password: openidm-admin" \ --header "Content-Type: application/json" \ --request GET \ "http://localhost:8080/openidm/system/saphana/__ACCOUNT__?_queryId=query-all-ids" { "result": [ { "_id": "9980000000" }, { "_id": "9980000002" }, { "_id": "9980000004" }, { "_id": "9980000006" }, [ ... ] { "_id": "9980004314" }, { "_id": "9980004316" }, { "_id": "9980004318" }, { "_id": "9980004320" } ], "resultCount": 2139, "pagedResultsCookie": null, "totalPagedResultsPolicy": "NONE", "totalPagedResults": -1, "remainingPagedResults": -1 }
The following command queries a specific user by their ID:
curl \ --header "X-OpenIDM-Username: openidm-admin" \ --header "X-OpenIDM-Password: openidm-admin" \ --header "Content-Type: application/json" \ --request GET \ "http://localhost:8080/openidm/system/saphana/__ACCOUNT__/9980004320" { "_id": "9980004320", "TimeFormatCode": "0", "PersonFullName": "Barbara Jensen", "__UID__": "9980004320", "EmailAddress": "bjensen@example.com", "FirstName": "Barbara", "UserID": "CB9980004320", "__NAME__": "BJENSEN", "DecimalFormatCode": "X", "StartDate": "2022-06-02", "LogonLanguageCode": "EN", "LastName": "Jensen", "PersonExternalID": "BJENSEN", "PersonUUID": "FA163EA9-3617-1EEC-B8DA-AD865EF3B625", "__ENABLE__": true, "TimeZoneCode": "CET", "EndDate": "9999-12-31", "DateFormatCode": "1" }
Enable an SAP S/4HANA user
curl \ --header "X-OpenIDM-Username: openidm-admin" \ --header "X-OpenIDM-Password: openidm-admin" \ --header "Content-Type: application/json" \ --header "If-Match:*" \ --request PUT \ --data '{ "__NAME__": "BJENSEN", "__ENABLE__": true }' \ "http://localhost:8080/openidm/system/saphana/__ACCOUNT__/9980004320" { "_id": "9980004320", "TimeFormatCode": "0", "PersonFullName": "Barbara Jensen", "__UID__": "9980004320", "EmailAddress": "bjensen@example.com", "FirstName": "Barbara", "UserID": "CB9980004320", "__NAME__": "BJENSEN", "DecimalFormatCode": "X", "StartDate": "2022-06-02", "LogonLanguageCode": "EN", "LastName": "Jensen", "PersonExternalID": "BJENSEN", "PersonUUID": "FA163EA9-3617-1EEC-B8DA-AD865EF3B625", "__ENABLE__": true, "TimeZoneCode": "CET", "EndDate": "9999-12-31", "DateFormatCode": "1" }
Disable an SAP S/4HANA user
curl \ --header "X-OpenIDM-Username: openidm-admin" \ --header "X-OpenIDM-Password: openidm-admin" \ --header "Content-Type: application/json" \ --header "If-Match:*" \ --request PUT \ --data '{ "__NAME__": "BJENSEN", "__ENABLE__": false }' \ "http://localhost:8080/openidm/system/saphana/__ACCOUNT__/9980004320" { "_id": "9980004320", "TimeFormatCode": "0", "PersonFullName": "Barbara Jensen", "__UID__": "9980004320", "EmailAddress": "bjensen@example.com", "FirstName": "Barbara", "UserID": "CB9980004320", "__NAME__": "BJENSEN", "DecimalFormatCode": "X", "StartDate": "2022-06-02", "LogonLanguageCode": "EN", "LastName": "Jensen", "PersonExternalID": "BJENSEN", "PersonUUID": "FA163EA9-3617-1EEC-B8DA-AD865EF3B625", "__ENABLE__": false, "TimeZoneCode": "CET", "EndDate": "9999-12-31", "DateFormatCode": "1" }
OpenICF Interfaces Implemented by the SAP HANA Connector
The SAP HANA Connector implements the following OpenICF interfaces. For additional details, see ICF interfaces:
- Create
-
Creates an object and its
uid
. - Schema
-
Describes the object types, operations, and options that the connector supports.
- Script on Connector
-
Enables an application to run a script in the context of the connector.
Any script that runs on the connector has the following characteristics:
-
The script runs in the same execution environment as the connector and has access to all the classes to which the connector has access.
-
The script has access to a
connector
variable that is equivalent to an initialized instance of the connector. At a minimum, the script can access the connector configuration. -
The script has access to any script arguments passed in by the application.
-
- Search
-
Searches the target resource for all objects that match the specified object class and filter.
- Test
-
Tests the connector configuration.
Testing a configuration checks all elements of the environment that are referred to by the configuration are available. For example, the connector might make a physical connection to a host that is specified in the configuration to verify that it exists and that the credentials that are specified in the configuration are valid.
This operation might need to connect to a resource, and, as such, might take some time. Do not invoke this operation too often, such as before every provisioning operation. The test operation is not intended to check that the connector is alive (that is, that its physical connection to the resource has not timed out).
You can invoke the test operation before a connector configuration has been validated.
- Update
-
Updates (modifies or replaces) objects on a target resource.
SAP HANA Connector Configuration
The SAP HANA Connector has the following configurable properties:
Basic Configuration Properties
Property | Type | Default | Encrypted(1) | Required(2) |
---|---|---|---|---|
|
|
|
|
Yes |
Provides the Username to authorize the SAP HANA APIs. |
||||
|
|
|
Yes |
Yes |
Provides the Password to authorize the SAP HANA APIs. |
||||
|
|
|
|
Yes |
Instance URL of the SAP HANA instance. |
||||
|
|
|
|
No |
Provides the Tenant ID to identify your custom SAP HANA APIs. |
||||
|
|
|
|
No |
Page Size for search operation. |
||||
|
|
|
|
No |
Provides the HTTP Proxy Host. |
||||
|
|
|
|
No |
Provides the HTTP Proxy Port. |
||||
|
|
|
|
No |
Provides the HTTP Proxy Username. |
||||
|
|
|
Yes |
No |
Provides the HTTP Proxy Password. |
(1) Whether the property value is considered confidential, and is therefore encrypted in IDM.
(2) A list of operations in this column indicates that the property is required for those operations.