Web service

Web service provider settings

To offer your own web service, enter the required settings in the "Integration" module in the left-hand area under "Provide data / Web service". You can access the corresponding dialog in the "Settings" context menu if the "Web service" entry is selected.

To configure web services, the portal permission "Register web services" and permission for the "Tools" module are required.

Link address

Defines exactly who may access the web service. If "localhost" is entered, the web service is only available locally. Alternative entries are

  • any (IPv4)

  • any (IPv6)

  • an IP address

Select "localhost" if you wish to test your web service locally first.

Port

Defines under which TCP port the web service should be available. Ideally, use a port number between 49152 and 65535, one of the so-called "private ports". These can be used flexibly, as they are not registered and therefore do not belong to a specific application.

Host / Port

Together, they constitute the endpoint URL, under which your web service will be available. The web service can be integrated easily into your domain for public use.

Endpoint URL

Is generated automatically from the previous entries.

Activate provider

With this setting, your web service will be immediately available under the indicated endpoint URL.

Click "OK" to save the settings.

Provide web service

A new web service can by created via the main menu "Web service / New web service". This is only available if "Web service" under "Provide data" is selected. So that self-created web services can be consumed, the settings of the provided web service must be configured accordingly.

General properties for web service

Enter a unique name here. The web service can be accessed later under the namespace entered here. A brief description of the web service can also be entered here.

Different service location

For network scenarios where clients call the web service via the location defined here independent of the link address and port defined on Intrexx pages. The different service location is entered in the WSDL.

Click "Next".

Operations

The name and description of existing operations are displayed here.

Add parameter / Edit parameter

Opens a dialog in which an operation can be created or edited. Click here for more information.

Delete an operation

Deletes the currently selected operation.

Once you have defined the desired operation(s), click "Next" here.

Finish

Consume web service

If you want to use the web service in the same portal (e.g. with a web service action in processes), activate the "Consume web service" setting here and then configure the registration of the web service in the next step. Click here for more information.

Operations

Insert

With this operation type, a new data record, such as a new product, will be delivered to the web service, which will be inserted in its original data records.

Refresh

With this operation type, an existing data record in the source application will be changed.

Delete

With this operation type, an existing data record will be deleted from the source application. The procedure for the definition of this operation does not differ significantly from the operation type Refresh. The data record to be deleted will also be ascertained by the ID transmitted. Additional transfer parameters, i.e. additional data fields that will be taken into account for the comparison, cannot be defined. When deleting a data record, this will not be necessary.

Read

For this operation type, the data from existing data records will only be read. The identification takes place here automatically via the ID as well. All data fields of the source application can be selected as return parameters.

List

This operation type differentiates itself from the other types insofar that multiple data records, comparable to an array, can be read here. This operation type can be used, for example, to search for the occurrence of a specific character string in product numbers.

Click "Next" when you have selected the desired operation type.

Select data group

You can search for the name or the GUID of an application here. Select the desired application with a click. Then select the desired data group whose data is to be made available via the web service.

Click "Next".

Input parameters and return parameters

This dialog is also used to define return parameters.

The parameter name can be changed here by double-clicking. The name of the data field from the source application is displayed in the second column. This name cannot be edited. In the "Optional" column, you can specify which data group fields require mandatory input. If a field is marked as optional, then entering a value is not absolutely necessary.

Add a database parameter / Edit parameter

This button is only active for the "Insert" or "Select" operation types. It opens a dialog in which data fields can be selected. This determines which data should be collected upon an input.

Data fields to be copied

Select the required data field.

If you edit a parameter again, you will also find the "General" tab here.

Edit parameter ID

The name of the parameter can be edited here.

Then click "OK" to save the changes and close the dialog.

Add request parameter / Edit parameter

Opens a dialog where a request parameter can be defined. The "List" operation type must be selected for this.

Add parameter

Enter a unique name for the request variables here. This name will be used for assignment in the WSDL files.

The name of the request variable must begin with "rq_" in Intrexx. Otherwise, the variable will not be recognized as a request. This prefix is entered automatically when you enter the name for the request variable. The value is automatically stored in the request variable defined here.

The request variable will, in turn, be used for the return in order to filter the database for the input value. If you search for product numbers, for example, that contain the characters "SW" for software, the value "SW" will be saved to the request variables. The "List" operation type then performs a query for this character string in the source data and returns all data records that contain the characters SW in the article number.

Click "OK" to save your entries and close the dialog again.

Add data set count parameter

Defines the rowcount parameter. The "List" operation type must be selected for this. With this parameter, the maximum number of data records which are returned is defined. In this case as well, you can define whether the parameter is optional or mandatory.

Click "Next".

Lists filter

If you have selected the "List" operation, you can create a filter here to restrict the list. Click here for more information about this dialog.

Click "Next".

Further settings

If you have selected the "List" operation, you can edit the following settings here:

Values

Number of data records

If the "rowcount" parameter has not been defined as an input parameter, the maximum number of data records returned can be set here.

Sorting

Available fields column

Every field that can be used for the sorting is listed here.

Selected sort fields column

The fields listed here sort the data. You can define whether the fields should be sorted in ascending or descending order via the context menu.

Move the currently selected field from one list to the other.

Adjust the order of the sorting fields.

Click "Next".

General properties for operation

Define the name of the new operation here. A description can also be entered here that explains the operation and will be displayed later when registering or selecting an operation.

Click "OK" to save your entries and close the dialog again.

HTTPS encryption

In the following it is assumed that the relevant certificates as well keystore and truststore are already present. Care should be taken to ensure that keystore and truststore are of the Java keystore type.

AXIS2 configuration

To setup a transport using HTTPS, modifications to the Axis2 configuration file need to be carried out. To do this, go to the portal directory "internal/webservice/provider/axis2/conf/" and open the file "axis2.xml" in a text editor. Search for the following entry:

<!-- ================================================= -->
<!-- Non-blocking http/s Transport Listener  -->
<!-- the non blocking http transport based on HttpCore + NIO extensions -->
<transportReceiver class="de.uplanet.lucy.server.webservice.provider.axis2.transport.nhttp.HttpCore NIOListener" name="http">
	<parameter locked="false" name="port">"WS_PORT"</parameter>
	<parameter locked="false" name="non-blocking">true</parameter>
	<parameter locked="false" name="hostname">"HOST_NAME"</parameter>
</transportReceiver>

Below this entry you will find the commented out element <transportreceiver>. Remove the comment tags to activate the entry.

<!-- the non blocking https transport based on HttpCore + SSL-NIO extensions -->
<transportReceiver class="de.uplanet.lucy.server.webservice.provider.axis2.transport.nhttp.HttpCore
NIOSSLListener" name="https">
	<parameter locked="false" name="port">SSL_WS_PORT</parameter>
	<parameter locked="false" name="non-blocking">true</parameter>
	<parameter locked="false" name="keystore">
		<KeyStore>
			<Location>KEYSTORE.jks</Location>
			<Type>JKS</Type>
			<Password>KEYSTORE_PASSWORD</Password>
			<KeyPassword>KEY_PASSWORD</KeyPassword>
		</KeyStore>
	</parameter>
	<parameter locked="false" name="truststore">
		<TrustStore>
			<Location>TRUSTSTORE.jks</Location> 
			<Type>JKS</Type>
			<Password>TRUSTSTORE_PASSWORD</Password>
		</TrustStore>
	</parameter>
	<parameter name="SSLVerifyClient">require</parameter>
<!--supports optional|require or defaults to none -->
</transportReceiver>

The following values need to be filled in correctly:

Parameters

Description

SSL_WS_PORT

Port that can be used to call the HTTPS Web service. It should be noted that this port is different to the port for unsecured Web service calls.

KEYSTORE.jks

Path to the Keystore in the format JKS. The path must be entered relative to the portal directory "internal/webservice/provider/".

KEYSTORE_PASSWORD

Password for the stated Keystore.

KEY_PASSWORD

Password for the used key.

TRUSTSTORE.jks

Path to the Truststore in the format JKS. The path must be entered relative to the portal directory "internal/webservice/provider/".

TRUSTSTORE_PASSWORD

Password for the stated Truststore.

Once the values have been entered correctly, the next entry to search for is:

<transportSender class="org.apache.axis2.transport.http.CommonsHTTPTransportSender" name="https">
	<parameter name="PROTOCOL">HTTP/1.1</parameter>
	<parameter name="Transfer-Encoding">chunked</parameter>
</transportSender>

Beneath this entry is another "<transportsender>" element that is currently commented out. Remove the comment tags to activate the entry.

<!-- the non-blocking https transport sender based on HttpCore + NIO SSL extensions-->
<transportSender name="https" class="de.uplanet.lucy.server.webservice.provider.axis2.transport.nhttp.Http
CoreNIOSSLSender">
<parameter name="non-blocking" locked="false">true</parameter>
<parameter name="keystore" locked="false">
	<KeyStore>
		<Location>KEYSTORE.jks</Location>
		<Type>JKS</Type>
		<Password>KEYSTORE_PASSWORD</Password>
		<KeyPassword>KEY_PASSWORD</KeyPassword>
	</KeyStore>
</parameter>
<parameter locked="false" name="truststore">
	<TrustStore>
		<Location>TRUSTSTORE.jks</Location>
		<Type>JKS</Type>
		<Password>TRUSTSTORE_PASSWORD</Password>
	</TrustStore>
</parameter>
<parameter name="HostnameVerifier">DefaultAndLocalhost</parameter>
	;<!--supports Strict|AllowAll|DefaultAndLocalhost or the default if none 	specified-->
</transportSender>

The following values need to be filled in correctly:

Parameters

Description

KEYSTORE.jks

Path to the Keystore in the format JKS. The path must be entered relevant to the portal directory \internal\webservice\provider\

KEYSTORE_PASSWORD

Password for the stated Keystore.

KEY_PASSWORD

Password for the used key.

TRUSTSTORE.jks

Path to the Truststore in the format JKS. The path must be entered relative to the portal directory "internal/webservice/provider/".

TRUSTSTORE_PASSWORD

Password for the stated Truststore.

Save the file and then restart the portal service. When doing this, make sure that the entries are correct, i.e. When doing this, make sure that the entries are correct, i.e. the port and https instead of http. If the URL has been correctly entered, the applied certificate must be accepted. Subsequently, the WSDL file will be shown in the browser.

More information

General

Edit web service offer

Edit web service operation

Define new web service

Web service action in processes