Integrate with Theobald yunIO via Nintex Gateway
In this example, you will create an Xtension A set of instructions for Nintex Automation Cloud to use third-party API functionality with Nintex workflows. An Xtension may include workflow actions, start events, forms or file control. for the Theobald yunIO on-premises application via Nintex Gateway. For more information on yunIO, see the Theobald help documentation: Introduction to yunIO. |
Nintex Gateway allows you to integrate on-premises applications with Nintex Automation Cloud. Nintex Gateway acts as middleware to authenticate the communication between Nintex Automation Cloud and your on-premises application, allowing you to connect your application without leaving ports vulnerable in your network.
For more information on Nintex Gateway, see Nintex Gateway.
For more information on creating on-premises Xtensions with Nintex Gateway, see Integrate on-premises applications via Nintex Gateway.
Before you start
- Download, install, and configure Nintex Gateway on your network.
- Download the OpenAPI Specification from your Theobald yunIO installation.
- Create a service in yunIO and configure the operations you need.
-
Open the Services page in yunIO and download the OpenAPI Specification (Swagger) file.
See Install and Configure Nintex Gateway.
In this example, the service is called KNA1Service.
For more information, see the Theobald yunIO help documentation.
Jump to:
Tip: If you're not familiar with OpenAPI Specifications, we recommend working through our OpenAPI Specification tutorial before you start.
Define the Nintex Gateway host and basePath
In the root level of your OpenAPI Specification:
- Add the x-ntx-host property with a value of {{x-ntx-gateway-uri}}.
- Change the value of the basePath property to /xtension.
If your OpenAPI Specification does not have a basePath property, create a new basePath property underneath x-ntx-host, and add a value of /xtension.
For more information on overriding the host value, see x-ntx-host.
{
"swagger": "2.0",
"info": {
"version": "1.0.0",
"title": "yunIO",
"description": "On-premises yunIO Xtension"
},
"host": "yunioservices.theobald-software.com:8175",
"x-ntx-host": "{{x-ntx-gateway-uri}}",
"basePath": "/xtension",
"schemes": [
"https"
]
...
}
Add the validation operation
Nintex Automation Cloud validates all new Nintex Gateway connections The stored authorization credentials for a connector. using a special validation endpoint The address of a specific resource provided by the third-party API. to make sure the Nintex Gateway instance is available at the URL specified in the connection.
In the paths object:
- Add a new operation A single request to a third-party API. Operations often become actions in the workflow designer. of /x-ntx-validate.
- Add a GET HTTP method The HTTP action to perform on the endpoint, such as GET, POST, DELETE, PUT. In defined inside the operation's path object in the OpenAPI specification..
- Add an operationId of validateConnection.
- Add the property x-ntx-visibility with a value of internal.
- Add a response The return from a third-party API after a request has been made by the client. object of 200.
- Add a response object of default for all other response codes.
For more information on defining operations, see our basic OpenAPI Specification tutorial: Define the operations
"paths": {
"/x-ntx-validate": {
"get": {
"operationId": "validateConnection",
"x-ntx-visibility": "internal",
"responses": {
"200": {
"description": "OK"
},
"default": {
"description": "Operation Failed."
}
}
}
},
Add connection validation to the security definition
To ensure Nintex Automation Cloud validates your Nintex Gateway URL when creating a connection, add the validation URL to the security definition using the x-ntx-connection-validation specification extension.
In the securityDefinition object:
- Create an object for basic authentication Identifying the API requestor using a username and password passed in the HTTP header., if one doesn't already exist.
- Inside the basic security definition, add the x-ntx-connection-validation property.
- Inside the x-ntx-connection-validation property, add the property operationId with a value of validateConnection.
See Add basic authentication for help with creating basic authentication security definitions.
For more information on validation operations, see x-ntx-connection-validation.
"securityDefinitions": {
"basic": {
"type": "basic",
"x-ntx-connection-validation": {
"operationId": "validateConnection"
}
}
}
Add connection properties to the security definition
When creating a connection to your Xtension, workflow designers need to:
- Select which Nintex Gateway integration to use in your Nintex Automation Cloud tenant.
- Specify the yunIO service URL.
- Authenticate to your network via Nintex Gateway.
- Authenticate to the yunIO application.
This information is collected by additional fields that are displayed on the Add connection screen. These fields are defined in your OpenAPI Specification using the x-ntx-connection-properties specification extension.
To add connection properties to the security definition:
- Inside the basic security definition, add the x-ntx-connection-properties object.
- Inside the x-ntx-connection-properties object:
- Add a type property with a value of object.
- Add a properties object.
We will add the connection properties to this properties object in the next steps.
For more information on defining custom connection properties, see x-ntx-connection-properties.
"securityDefinitions": {
"basic": {
"type": "basic",
"x-ntx-connection-validation": {
"operationId": "validateConnection"
},
"x-ntx-connection-properties": {
"type": "object",
"properties": {}
}
}
}
Add a connection property for Nintex Gateway integration
Your Nintex Automation Cloud tenant may have more than one Nintex Gateway integration. Add the x-ntx-gateway-id connection property so your workflow designers can select from a drop-down list of existing Nintex Gateway integrations when they create their connections.
Inside the properties object of x-ntx-connection-properties:
- Add an x-ntx-gateway-id object.
- Inside the x-ntx-gateway-id object:
- Add a type property with the value of string.
- Add a title property with the value Select Nintex Gateway.
"x-ntx-connection-properties": {
"type": "object",
"properties": {
"x-ntx-gateway-id": {
"type": "string",
"title": "Select Nintex Gateway"
}
}
}
Add a connection property for the yunIO service URL
The yunIO service URL is the base URL where the yunIO application expects to receive requests from integrating services.
Add the x-ntx-gateway-xtension-baseurl property to store the yunIO service URL:
Inside the properties object of x-ntx-connection-properties:
- Add an x-ntx-gateway-xtension-baseurl object.
- Inside the x-ntx-gateway-xtension-baseurl object:
- Add a type property with the value of string.
- Add a title property with the value yunIO service URL.
- Add a description property with the value Base URL of the yunIO service, including HTTPS://.
- Add a pattern property with the value of ^(https?:\/\/[^\/?#]+)(?:[\/]|\/.+|)$.
"x-ntx-connection-properties": {
"type": "object",
"properties": {
...
"x-ntx-gateway-xtension-baseurl": {
"type": "string",
"title": "yunIO service URL",
"description": "Base URL of the yunIO service, including HTTPS://.",
"pattern": "^(https?:\/\/[^\/?#]+)(?:[\/]|\/.+|)$"
}
}
}
Add connection properties for yunIO authentication
Add username and password connection properties to collect the username and password that will be supplied to yunIO when making requests.
Inside the properties object of x-ntx-connection-properties:
- Add a username object.
- Inside the username object:
- Add a type property with the value of string.
- Add a title property with the value yunIO username.
- Add a password object.
- Inside the password object:
- Add a type property with the value of string.
- Add a title property with the value yunIO password.
- Add a format property with the value password.
"x-ntx-connection-properties": {
"type": "object",
"properties": {
...
"username": {
"type": "string",
"title": "yunIO username"
},
"password": {
"type": "string",
"title": "yunIO password"
}
}
}
Add connection properties for Nintex Gateway authentication
Add connection properties for the Active Directory username and password. These credentials will be used by Nintex Gateway to authenticate to your network.
Inside the properties object of x-ntx-connection-properties:
- Add an x-ntx-gateway-username object.
- Inside the x-ntx-gateway-username object:
- Add a type property with the value of string.
- Add a title property with the value Active Directory username.
- Add an x-ntx-gateway-password object.
- Inside the x-ntx-gateway-password object:
- Add a type property with the value of string.
- Add a title property with the value Active Directory password.
- Add a format property with the value password.
If your organization does not use Active Directory, you can also authenticate using API keys. See Managed authentication with an API key .
"x-ntx-connection-properties": {
"type": "object",
"properties": {
...
"x-ntx-gateway-username": {
"type": "string",
"title": "Active Directory username"
},
"x-ntx-gateway-password": {
"type": "string",
"title": "Active Directory password",
"format": "password"
}
}
}
Add the list of required connection properties
Designate all the connection properties you have added as required so the workflow designer must complete them all when they create a connection to yunIO.
Inside the properties object of x-ntx-connection-properties:
- Add a required property.
- For the value of the required property, add an array of the property names of each connection property you created.
"securityDefinitions": {
"basic": {
"type": "basic",
"x-ntx-connection-validation": {
"operationId": "validateConnection"
},
"x-ntx-connection-properties": {
"type": "object",
"required": [
"x-ntx-gateway-username",
"x-ntx-gateway-password",
"x-ntx-gateway-id",
"x-ntx-gateway-xtension-baseurl",
"username",
"password"
],
"properties": { ... }
Example OpenAPI Specification
{
"swagger": "2.0",
"info": {
"title": "yunIO",
"version": "1.0.0"
},
"host": "yunioservices.theobald-software.com:8175",
"x-ntx-host": "{{x-ntx-gateway-uri}}",
"basePath": "/xtension",
"schemes": [
"https"
],
"paths": {
"/services/KNA1Service": {
"post": {
"summary": "KNA1Service",
"operationId": "post-KNA1Service",
"consumes": [
"application/json"
],
"security": [
{
"basic": []
}
],
"parameters": [
{
"in": "body",
"name": "body",
"description": "JSON data for runtime parameters",
"required": false,
"schema": {
"type": "object",
"properties": {
"whereClause": {
"type": "string",
"default": ""
}
}
}
}
],
"produces": [
"application/json"
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"KUNNR": {
"type": "string",
"maxLength": 10,
"readOnly": true
},
"LAND1": {
"type": "string",
"maxLength": 3,
"readOnly": true
},
"NAME1": {
"type": "string",
"maxLength": 35,
"readOnly": true
},
"NAME2": {
"type": "string",
"maxLength": 35,
"readOnly": true
},
"ORT01": {
"type": "string",
"maxLength": 35,
"readOnly": true
},
"PSTLZ": {
"type": "string",
"maxLength": 10,
"readOnly": true
},
"REGIO": {
"type": "string",
"maxLength": 3,
"readOnly": true
},
"STRAS": {
"type": "string",
"maxLength": 35,
"readOnly": true
},
"TELF1": {
"type": "string",
"maxLength": 16,
"readOnly": true
}
}
}
}
},
"401": {
"description": "no basic auth provided"
}
}
}
},
"/x-ntx-validate": {
"get": {
"operationId": "validateConnection",
"x-ntx-visibilty": "internal",
"responses": {
"200": {
"description": "OK"
},
"default": {
"description": "Operation Failed."
}
}
}
}
},
"securityDefinitions": {
"basic": {
"type": "basic",
"x-ntx-connection-validation": {
"operationId": "validateConnection"
},
"x-ntx-connection-properties": {
"type": "object",
"required": [
"x-ntx-gateway-username",
"x-ntx-gateway-password",
"x-ntx-gateway-id",
"x-ntx-gateway-xtension-baseurl",
"username",
"password"
],
"properties": {
"x-ntx-gateway-username": {
"type": "string",
"title": "Active Directory username"
},
"x-ntx-gateway-password": {
"type": "string",
"title": "Active Directory password",
"format": "password"
},
"x-ntx-gateway-id": {
"type": "string",
"title": "Select Nintex Gateway"
},
"x-ntx-gateway-xtension-baseurl": {
"type": "string",
"title": "yunIO service URL",
"description": "Base URL of the yunIO service, including HTTPS.",
"pattern": "^(https?:\/\/[^\/?#]+)(?:[\/]|\/.+|)$"
},
"username": {
"type": "string",
"title": "yunIO username"
},
"password": {
"type": "string",
"title": "yunIO password",
"format": "password"
}
}
}
}
},
"x-ntx-render-version": 2
}
Create the connection
Step 1: Add your Xtension
Import the OpenAPI Specification you created into Nintex Automation Cloud:
- Open your Nintex Automation Cloud tenancy.
- Click Xtensions in the dashboard to open the Xtensions page.
- Click in the Private connector list.
- Click Choose a file. Navigate to the OpenAPI Specification on your computer.
- Wait for Nintex Automation Cloud to validate the file.
- Click Next.
- Click Next.
Nintex Automation Cloud detects the basic authentication security template.
- Edit the Name of the Xtension, which becomes the name of the action group in the Workflow designer.
- Edit the Description of the Xtension. This appears in the Private connector list in the Xtensions page.
- Select or upload an icon for the Xtension. This is displayed for each action or event in the Workflow designer.
- Click Publish.
Step 2: Create a new connection
- Click Connections in the dashboard to open the Connections page.
- Click in the Connector list.
- Select the yunIO connector you created.
- Click Next.
- Configure the connection:
- In the Nintex Gateway field, select your Nintex Gateway integration.
- In the Connection name field, type a short but descriptive name to identify this connection.
- In the yunIO service URL field, type the base URL of your yunIO service, including the HTTPS.
- In the yunIO username field, type your yunIO username.
- In the yunIO password field, type your yunIO password.
- In the Active Directory username field, type the username you use in your organization's Active Directory service.
- In the Active Directory password field, type the password you use in your organization's Active Directory service.
- Click Connect.