This site has moved to the integrated Appfire documentation and information site for our apps.

From February 2024 this site is no longer updated.

Take a look here! If you have any questions please email support@appfire.com

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 11 Next »

Sending an email to @document_user_reviewers@ when the page reaches the named state Published

In this example, the trigger listens for the change of state event to the state named Published.

The action sends an email to the users who have been added as values for the workflow parameter @document_user_reviewers@.

"triggers":
[
  {
    "event":"on-expire",
    "actions":[
      {
        "action":"send-email",
        "recipients":[
            "@document_user_reviewers@",
            "@watchers",
            "@creator",
            "@lastUpdatedBy"
        ],
        "notification":{
          	"subject":"${content.title} has expired",
          	"title":"${content.title} has expired",
          	"body":"Hello, ${content.link} in the ${content.space} space has expired and needs to be reviewed"
        }
      },
      {
        "action":"set-message",
        	"type":"info",
        	"title":"Expired",
        	"body":"The page has expired",
        	"tags":"state",
        	"mode":"autoClose"
      }
    ]
  }
]

If adding the JSON trigger using workflow builder there is no need to include the opening "triggers": JSON markup notation, since it will be added by workflow builder.

event

on-change-state

  • condition added - trigger will only listen for change of workflow state to named state

condition

state:Published

  • state condition for the trigger event

action

send-email

  • email sent to users who are added as values for the workflow parameter @document_user_reviewers@

action

set-message

  • on-screen info type message notification when viewing the content stating content has expired that will auto close after 10s

0

  • No labels