Create workflow definitions

When you go to the Sitefinity CMS administrative backend Administration -> Workflow menu, and define a workflow, you are configuring the properties of a workflow definition object.  You can do the same thing using the Workflow API, for example when you need to load a different workflow for different items, without this workflow being already created. To create a workflow definition, you need to specify its Title, Scope, Levels of approval, and all additional properties that determine the workflow behavior.

The following sample demonstrates creating two workflow definitions:

  • A 1-step approval workflow called “1-step workflow for Bloggers”, where users that are assigned to the Backend users role can approve content

    and

  • A 2-step approval workflow called "2-step workflow for Restricted Users", where users that are assigned to the Designers role can approve content, and users that belong to the Editorsrole can publish it

Was this article helpful?