GETTING STARTED AUTOMATION

Automation rules can be set up that periodically process the sending of an mydigitalstructure request to any endpoint or previously run advanced search (via more ID).

The returned information can then be:

  • if HTML, sent to a network group or contact person group.  Enabling the classsic email alerts to a group of users.

  • if XML/JSON, posted to another URL - eg pusher.com, twitter.com or facebook.com for broadcasting or any other webservice
  • if based on more ID with contactperson within the results, sent to each of the contact people within the results.

The automation service works with the advanced search service - allowing the creation of highly customised alert scenarios, via the selection and filtering available within the this service.

Rules can run once a day, every time, on every day, every weekday or a specific day (eg Monday)

The automation process runs every 15 minutes - your rule will be run to the closest 15 minute slot.

The automation process hands the task of the actually sending the email to the message scheduling service, ie as used by the NEWS methods.

All rules default to status equal to 2 (disabled) - this means the scheduler will ignore them, but you can use the SETUP_AUTOMATION_RUN method to test them - once all tested OK then the rule status can be set to 1 (enabled). 

A maximum run count can be sent, after which the rule is automatically set to expired.  Useful run once rules ie if you set the schedule type equal to "every time" (9), then the rule will run once on the next automation run.


SET UP STEPS

To see existing rules:

/ondemand/setup/?method=SETUP_AUTOMATION_SEARCH

To remove a rule:

/ondemand/setup/?method=SETUP_AUTOMATION_MANAGE&remove=1&id=[id]

To add a rule:

/ondemand/setup/?method=SETUP_AUTOMATION_MANAGE 

To update a rule:

/ondemand/setup/?method=SETUP_AUTOMATION_MANAGE&id=[id]


TESTING AN RULE

To test a rule you can use:

/ondemand/setup/?method=SETUP_AUTOMATION_RUN&id=[id]

As default, this will send all the emails to the user running this method, you can override they by setting &testuser=[list of user ids]

At the bottom of the email message will be a list of the ids, in [] brackets, that it will go when sent as live (enabled).

If you want the emails to go to actual recipients that set &aslive=1.

 

METHODS

SETUP_AUTOMATION_SEARCH

SETUP_AUTOMATION_MANAGE

SETUP_AUTOMATION_RUN

JS/JQUERY EXAMPLE

/jscripts/1blankspace.automation.001.js