HTTP header authentication (S/4HANA only)
- Last Updated: July 30, 2025
- 1 minute read
- DataDirect Connectors
- ODBC
- SAP S/4HANA 8.0
- Documentation
HTTP header authentication can be used to authenticate with the S/4HANA sandbox hosted at https://api.sap.com.
To configure the driver to use HTTP header authentication:
- Set the Host Name (HostName) option to the S/4HANA sandbox instance: https://api.sap.com.
- Set the Authentication Method (AuthenticationMethod) option to
25(HTTP Header). - Set the AuthHeader (AuthHeader) option to specify the name of the HTTP header used for
authentication. The default is
Authorization. - Set the Security Token option to specify the security token for the user connecting to the service.
- Optionally, specify values for any additional options you want to configure. See "Connection option descriptions" for a complete list of options.
Note: The Security Token option is not
required to be stored in the connection string. It can also be passed separately by the
application.
The following example show the connection information required to establish a session with HTTP header authentication enabled and AuthHeader is set to the default.
Connection string
DRIVER=DataDirect 8.0 SAP S4HANA;HostName=https://api.sap.com;
AuthenticationMethod=25-HttpHeader;AuthHeader=X-Api-Key;
SecurityToken=12a3=bCD/EfGh4Ijk+Lgd8g-44tk3c527831;
odbc.ini
[SAP S4HANA]
Driver=ODBCHOME/lib/ivs4hana28.so
...
Description=DataDirect 8.0 SAP S4HANA
...
HostName=https://api.sap.com
...
AuthenticationMethod=25
...
AuthHeader=X-Api-Key
...
SecurityToken=12a3=bCD/EfGh4Ijk+Lgd8g-44tk3c527831
...