How to Call a Connector Function using Triggers
  • 03 May 2023
  • 4 Minutes to read
  • Contributors

How to Call a Connector Function using Triggers

Article Summary


In order to access information from an MES or other external system, Tulip uses Connectors

Once the Connector Functions have been built, they can be initiated within an app via Triggers.

This means that when an operator presses a specific button within the Tulip Player, or uses a specific connected device like a barcode scanner, you can retrieve or store data in an external system.

Here's how the data will travel through Tulip to your system of choice:

  1. Specify the Connector Function that should run within the Trigger
  2. Specify the inputs for the connector function (if any are needed). These are usually Variables from an app
  3. If there are outputs from the connector function, specify which Variable should store theses values.

Here's a visual of the pathway:

Variable (or static value) in app --> Inputs to Connector Function  --> Connector function runs --> Outputs --> Other Variable in app

This can be achieved by following the steps described below:

Create The Trigger

1- Click on the "+" sign beside Triggers under the Step Tab of the Context Pane.

2- Fill in a name for the new Trigger in the Trigger Editor.

3- Select When the trigger should run.

Add the "Run Connector Function" Trigger Action

4- Select a Condition that will determine if the Trigger should run in the If section.

5- Add New Action by filling the section under “Then”:

  • Select "Run Connector Function"
  • Select the connector you wish to run
  • Select the desired data input to the function (e.g a barcode scan, from a variable or even a static value)
  • Select the Variable where you would like to store the outputs of the function (the variable will be an array or object depending on the connector function)

Here's an example:

  • "Run Connector Function" connector: "Server Assembly DB" "Get_Configuration"
  • configuration: "Static Value" "text"
  • and save result as: "Variable" "config_information"

In case the data received from the connector function contains several variables, Tulip will save each data input as a separate property within an object and you’ll be able to access each property separately.

Further Reading

Did you find what you were looking for?

You can also head to to post your question or see if others have faced a similar question!

Was this article helpful?