Trigger
The Trigger is the first component in every workflow. It determines how and when the workflow runs. Without a trigger, a workflow cannot execute.
Vince Platform supports three trigger types, plus webhooks for starting a workflow from an external system:
| Type | Description |
|---|---|
| Manual | A user starts the workflow by clicking Run |
| Schedule | The workflow runs automatically at defined time intervals |
| Event | The workflow runs automatically when a specific table action occurs |
| Webhook | An external system starts the workflow by calling a URL |
Choosing a trigger type
Ask who or what should start the workflow:
- Should a person start it, perhaps filling in a few values first? Use Manual.
- Should it run by itself at set times, such as a nightly data sync or a weekly report? Use Schedule.
- Should it react when a row in a table is added, changed or deleted, for example sending a notification when an order is created? Use Event.
- Should another system decide when it runs, for example when an order system reports a new order? Use Webhook.
A webhook is an additional way to start a workflow. It does not replace the workflow's Manual, Schedule or Event setting.
Every workflow can also be started manually or by an API call
Whatever trigger you choose, every workflow can always be:
- started manually with Run in the workflow list, for example to test it, and
- called through the API, so another system or another workflow can use it as a small service (a "micro service"): send a request, get the result back. See Call the workflow synchronously and Give it a human-readable URL with a Custom API endpoint for a worked example.
The run form with input fields is mainly a VXL Live feature today: its fields come from a workflow's M3 API step and its M3 Filter or Generic Filter step (see Manual Trigger). Other workflows can still be run manually, but you can't define input fields for them, so a workflow that needs input values is best started by an API call, a webhook or an event, which pass the values in the request or the event.