One of the essential parts in the Mobsted automatization system is Triggers.

This is logical endpoint in the process of creating automatic process running.

What is Trigger?

Trigger is the mechanism that is the initiator to perform one or several Operations upon the occurrence of predetermined conditions. In order to run Trigger you should have Operations to be set up first.

In Mobsted PWA maker the condition on which the Trigger occurs is determined in Smart Filters and can react to the actions within Events or Objects.

Important! Before we create the Trigger, you must have already set up the API Provider, API methods, API keys, Operations and Filter.

For example: using Mobsted-built beauty salon App, one of your customers signed up to the master in 5 days from now (today date 1/1/2018, appointment date and time is 1/5/2018 3:00PM). The Event for 1/5/2018 3:00PM is created. The master, for whatever reason, cannot accept the client and changes the status of this Event to "Cancel Recording." An Event with this status gets into the pre-configured Smart Filter, and the Trigger performs the Operation - Send an SMS message to the client with the following text: "We apologize, but today your master will not be able to accept you. In the near future, the administrator will contact you."

How to create Trigger?

  • Go to the Objects or the Backend of your App
  • Go to the created Filter Settings
  • Navigate to the Triggers tab
  • Click Create New Trigger

Fields that you need to fill in the pop up opened:

  • Trigger name - the name of your Trigger
  • Trigger Scope - select what the Trigger will respond(react) to - Objects or Events. If you select Objects, the trigger will run on the already available objects OR on objects that have fallen into the Filter condition.
  • Trigger mode - could be Manual or Automatic. In the Manual mode you would need to press the corresponding button for the one time Trigger run. It is good to be used when testing if your Trigger was set up correctly. Automatic mode is used as a primary mode of executing the Operations. в свою очередь режим automatic следует использовать как основной режим для автоматического выполнения ряда необходимых Операций
  • On the right handside select the Operation from the dropdown menu and click Add Operation. You can also create the new Operation.
  • Click Save Changes and your Trigger is ready!

Manual and Automatic modes

Now let's take a closer look at the Trigger modes.

Manual mode

  • Select on what type of Filter entries you want to perform automatic actions (Operations)
    • All existing records: records that are already in the system and that fall under the Filter conditions.
    • New records, since last execution: All the records that would appear later in the system. If you select this option, you can run the Trigger instantly by clicking Execute now.

Automatic mode

  • All existing data: run trigger on all the data you have.
    • Schedule - set up the schedule for the Trigger execution.
    • Select the Number of Executions
      • No limit
      • Enter number of executions
      • Until date
  • On new data, appearing: could be executed instantly or scheduled.

To activate the changes press Start automatic mode.

Additional general info

The trigger will be executed in accordance with the configured Schedule and the selected number of operations until the Object or Event meets the conditions of the Filter, as soon as the Object or Events ceases to satisfy the filter conditions the operation of the Trigger is terminated.

If the Object or Event again satisfies the conditions of the Filter (those are in the Filter), the Trigger in relation relaunches with the initial state.

How did we do?