To configure the driver to use HTTP header authentication:
  • Configure the minimum options required for a connection:
    • If you are using a Model file, set the REST Config File (RestConfigFile) option to provide the name and location of the Model file. For example, C:/path/to/myrest.rest.
    • If you are using the REST Sample Path method, set the REST Sample Path (RestSamplePath) option to specify the endpoint that the want to connect to and sample. For example, https://example.com/countries/.
  • Set the Authentication Method (AuthenticationMethod) option to 25 (HttpHeader).
  • Set the AuthHeader (AuthHeader) option to specify the name of the HTTP header used for authentication. The default is Authorization.
  • Set the Security Token (SecurityToken) option to specify the security token required to make a connection to your endpoint. For example, XaBARTsLZReM.
  • Optionally, set the Health Check URI (HealthURI) option to specify the URI that the driver calls to confirm connectivity. Services using HTTP header authentication do not perform an explicit action upon connection. You can work around this limitation by specifying a value for this option. The driver performs a connectivity test at connection, when executing a test connect, or whenever the driver needs to confirm connectivity.

  • Optionally, specify values for any additional options you want to configure. See "Connection option descriptions" for a complete list of options.

The following examples demonstrates a session using a Model file with HTTP header authentication enabled and AuthHeader is set to the default.

Using a connection URL:

DRIVER=DataDirect 8.0 Autonomous REST Connector;AuthenticationMethod=25;
       RestConfigFile=C:/path/to/myrest.rest;SecurityToken=XaBARTsLZReM;

Using an odbc.ini file with the 32-bit driver:

Driver=ODBCHOME/lib/ivautorestxx.so
Description=My Autonomous REST Data Source
...
AuthenticationMethod=25
...
RestConfigFile=C:/path/to/myrest.rest
...
SecurityToken=XaBARTsLZReM
...