cs-icon.svg

Add Workflows and Stages

Contentstack allows you to create workflows for your stack. However, before you get started with setting up workflows, it’s important to note that:

  • Only the stack owner, admin, and users assigned “Developer” roles can create and manage workflows.
  • Content managers and users with custom roles cannot view workflow settings. But they can use workflows in entries and view and manage their tasks.
  • You can create multiple workflows within a stack. Workflows can be created for all or specific content types. A content type can be associated with more than one workflow, as long as each workflow is associated with a distinct branch.

To create a workflow in your stack, log in to your Contentstack account and perform the following steps:

  1. Navigate to workflows

    1. Go to your stack, navigate to the “Settings” icon (press “S”) on the left navigation panel.
    2. Select Workflows (press “alt + F” for Windows OS, and “option + F” for Mac OS).
    3. On the Workflow Settings page, you will see two tabs: Workflows and Publish Rules. In the Workflows tab, click on the + New Workflow button.Add_workflows_and_stages.png

      This opens up a new window where you can define your workflow and its stages as discussed in the next steps.
  2. Enter workflow details

    On the workflow creation page, enter the following details.

    1. Workflow name (mandatory): Provide a suitable name for the workflow
    2. Description (optional): Provide a description of the workflow.
    3. Scope: Select the content type(s) for which this workflow should be applicable. These are shown in the following screenshot:
      1. Branch(es) (mandatory): Select either all or specific branch(es) for which this workflow should be applicable.
      2. All Content Types: Lets you apply the workflow for all the content types and its entries.
      3. Specific Content Type(s): Lets you select the content types for which this workflow will be applicable.
        Selecting this option allows you to select content types from the Select Content Type window drop-down menu. Select the required content types by checkmarking them.
        You can choose multiple content types to which you want to apply the workflow settings.
        image.pngOnce you select the content types (and if the workflow is enabled), the entries of these content types will have a Workflow section on the right sidebar.

        Note: A content type can be associated with more than one workflow, as long as each workflow is associated with a distinct branch.

  3. Add workflow stages

    To add workflow stages, perform the following steps:

    1. Click on the Add stage button.

      Add_Workflows_and_Stages_3_highlighted.png

    2. In the Workflow Stages section, provide a suitable Stage name (mandatory) and Description (optional). You can also choose a color label for your stage. Please ensure that the color labels and names of the stages are unique.Add_Workflows_and_Stages_4_no_highlight.png

    Note: You can add a maximum of 20 stages in a workflow.

  4. Add stage transition and access rules

    Every stage comes with a set of stage transition and access rules. The transition rules define the conditions that are applicable when you move an entry from one workflow stage to another on the entry page. In addition, the stage access rules allow you to control who can edit an entry at a specific stage of the workflow.

    Add_Workflows_and_Stages_5_no_highlight.png

    There are three stage transition and access rules that you can configure for every stage:

    1. Next available stage: This defines the stage of your workflow that will be available when you move the entry from one stage to another. This is useful when you want the entries to go through certain stages, without skipping essential stages.

      Select one of the following options:
      1. All stages: It is the default option. Select this option if you want the users to be able to move the entry from current stage to any other available stages.
      2. Specific stage(s): Select this option if you want users to move an entry from current stage to a specific stage(s) of your workflow.

        Tip: While selecting specific stages, you will be able to see or select only the stages that you have already created in your workflow. This means that while creating your first stage, you will not see any stage when you choose the Specific stages option. In that case, you will need first to create other stages, and return here to select specific stages.

    2. Users/roles who can move from this stage to next available stages: This option gives you greater control over the usage of your content workflow. It lets you control who can move the entry from its current stage to the stages that you add under the Next available stages option.

      Select one of the following options:
      1. All users/roles: It is the default option. Select this option if you want any of the existing user(s) to move an entry from its current stage to the next available stage.
      2. Specific user(s)/role(s): Select this option to allow only specific users, or users with only specific roles, to move the entry from its current stage to the next available stages.

      Note: If you add specific users, other users will not be able to move the entry stage.

    3. Users/roles who can edit the entry in this stage: This option determines which users can edit an entry when it is at a specific stage of your workflow. By setting this rule, you can avoid unwanted modifications at specific stages and facilitate efficiency across the content lifecycle.

      Note: The entry is available for editing, by default, in the first stage that you create in your workflow.

      Select one of the following options:
      1. All users/roles: It is the default option. Select this option if you want to provide all users edit access over the entry in the current workflow stage.
      2. No users: Select this option if you want to restrict all users from accessing an entry when it has been moved to the current stage of your workflow.

        Note: The workflow superusers, organization owners, and stack owners/admins are exceptions to this. They will be able to edit the entry.

      3. Current stage user(s): Select this option if you want to allow users who have stage transition rights to edit the entry in the current stage of your workflow.

        Note: Although only specific users are able to edit the entry in the current stage, other users with stage transition rights will still be able to move the entry to the next available stage.

  5. Add workflow superusers

    Once you have added stages and defined transition and access rules, add the workflow super users by clicking on the drop-down menu.

    1. Superusers of the workflow can move the entry from one stage to any stage and edit or delete the entry, without any restrictions. The stage transition and access rules are not applicable to superusers.
      However, this freedom and flexibility is available only for entry stage transitions of the content types associated with the workflow. Also, superusers cannot edit or manage workflow settings, unless they are an admin, owner or user with a developer role.

      Note: The Organization owner and the stack owner/admin are superusers by default.

    2. To add superusers, click on the field and select the required users you want to add. You can add multiple users.

    Note: However, while you can add multiple users, note that you cannot add roles in this section

    Add_Workflows_and_Stages_6_highlighted.png 
    1. Enable workflow

      To enable workflow, check the Enable workflow box as shown below:

      Add_Workflows_and_Stages_7_highlighted.png


      Now, the workflow option will be available in the Status bar on the right for all the entries of the content types associated with this workflow.
    2. Save workflow

      Click on Save to save the workflow.

    API Reference

    To create a workflow and add stages to it via API, refer to the Create a workflow API request.

    Was this article helpful?
    ^