Installation and Execution

The Web API service can either be installed using the Windows Installer or using command line arguments. The latter is the main topic of the present page.

Please visit the dedicated system requirements page for a more detailed description of required minimum hardware and operating system to install and run the Web API.

Command Line Installation

For security reasons a dedicated access Profile should be used for the Web API. If this profile exists before the Web API service is installed and started, the service can connect to the system and the corresponding Web API object is created automatically in the Server Model. Otherwise this object has to be created manually. So, for simplicity’s sake, said profile is created first.

Creating a Dedicated Profile for the Web API

To create a new Profile go to the Access Model and …​

1 Right-click onto empty space and select New > Profile from the context menu.

2 In the Create Profile wizard, enter a unique Object Name. Later on this page, the <profilename> symbol is used to represent this value.

3 Set the Administrative Role to Administrator.

4 Click Next to move on to the Profile Credentials section of the wizard.

5 Set the checkbox for the Available property as selected and provide a Password according to the Password Requirements. For the rest of this page, the <password> symbol is used to represent this value.

6 Click Create to close the wizard and create the new Profile in the Access Model.

Installing the Web API Service

Once the dedicated Profile for the Web API exists, the service itself can be installed.
To install the Web API service …​

1 Run PowerShell as Administrator.

2 Execute the following commands:
For more information regarding the supported command line arguments see the list below.

PS> cd <root folder>  # e.g. C:\inmation.root
PS> cd webapi
PS> .\inmationWebAPI.exe -i --corehost localhost --coreport 6512 --profile <profilename> --pwd <password>

After a brief moment a new Web API object will appear in the Access Model.

3 Right-click the new object and select Admin  Enable  Object.

Now you can Launch WebStudio and authenticate yourself by entering the <profilename> and <password> as provided in the installation command line above in the Username and Password fields.

Property changes for WebAPI objects

Whenever property changes are applied to the WebAPI object the WebAPI service has to be restarted manually.

Multiple WebAPIs running on the same host

  • If more than one WebAPI service shall be installed on the same machine, every additional WebAPI service has to be installed as a different instance.

  • Before enabling the WebAPI object corresponding to a newly installed WebAPI service, the object’s Common > Base Address property needs to be set to an individual port number.

  • When connecting a client, e.g. WebStudio, to a specific WepAPI service , make sure to specify the correct port number for the intended WebAPI.

Deleting Web API objects
If the Web API object is deleted and a new one created, the 'inmation Web API' service has to be stopped, the oid value in C:\inmation.root\webapicfg\webapi.config updated, and the 'inmation Web API' service started again. The oid refers to value in brackets for the Object ID property of the Web API object’s header.

Making Changes to an already installed Web API service

To change the command line of a Web API service, it is recommended to first remove the service and then reinstall it. This way it is possible to change the credentials with which Web API connects to the Core.

 inmationWebAPI.exe -r
If an instance name was specified at the time of installation then care must be taken to include the instance option in the command line with the correct instance name.
 inmationWebAPI.exe -r --instance instancename

The service can be reinstalled with new profile credentials:

 inmationWebAPI.exe -i --profile new_profile --pwd new_password
If replacing a previously installed Web API service, be sure to include the same instance name and corehost/coreport parameters used in the initially installed service.

Command Line Arguments

Command line options have the prefix '--'.

Action Options Description

help

Provides information about available actions and options.

-i

Install the Web API as a service.

corehost

Specifies the Core’s host address, by default localhost

coreport

Specifies a particular setting for the Core Service Port, by default 6512.

instance

Optional, specifies the instance name for the Web API.

profile

API User profile which is used in the communication with the Core.

pwd

API User password which is used in the communication with the Core.

coreencryption

Specifies the encryption mode of the connection to the Core. Options are "TLS" (default) or "none".

-e

Executes the Web API as a console application.

auth

Contains the credentials for the Web API account. (used when installed as a service.)

corehost

Specifies the Core’s host address, by default localhost

coreport

Specifies a particular setting for the Core Service Port, by default 6512.

oid

Specifies the 'Web API Server' object ID to link to.

profile

API User profile which is used in the communication with the Core.

pwd

API User password which is used in the communication with the Core.

service

(Default: 0) Value 1 indicates the Web API is started as a Windows Service.

coreencryption

Specifies the encryption mode of the connection to the Core. Options are "TLS" (default) or "none".

-r

Removes the 'Web API' Windows service.

instance

Optional, specifies the instance name of the Windows service to remove, by default "Web API"

Command line options have the prefix '--'.

Example command to install the Web API as a Windows service.

 inmationWebAPI.exe -i --corehost localhost --coreport 6512 --profile webapi --pwd password

After installation a Web API Server Object is automatically created in the Server Model. Only the first Web API Server object in the Server Model will automatically be enabled after creation.

Making Changes to an already installed Web API service

To change the command line of a Web API service, it is recommended to first remove the service and then reinstall it. This way it is possible to change the credentials with which Web API connects to the Core.

 inmationWebAPI.exe -r
If an instance name was specified at the time of installation then care must be taken to include the instance option in the command line with the correct instance name.
 inmationWebAPI.exe -r --instance instancename

The service can be reinstalled with new profile credentials:

 inmationWebAPI.exe -i --profile new_profile --pwd new_password
If replacing a previously installed Web API service, be sure to include the same instance name and corehost/coreport parameters used in the initially installed service.