In the Workflows section, you can create scheduled workflows that will run automatically at specific intervals without manual intervention.
To create a scheduled workflow:
- In the Workflows Overview page, click Add.
- Select New Workflow from the dropdown.
- In the Create Workflow dialog, select the Workflow type as Schedule and click Next.
- Next, in the Workflow Details section, enter the Workflow Name.
Tip: Enter a unique descriptive name that explains the Workflow’s purpose clearly.
- In the Description section, you can add more details about the workflow.
- Click Done.
If you wish to change the workflow type, you can use the Previous button.
This will take you to the workflow builder where basic data such as workflow name and type are already populated along with the schedule card. You can define the schedule and add your conditions and actions here.
Once you start making changes in the workflow Canvas, you will see a floating panel at the bottom of the page alerting you regarding unsaved changes. Once you’ve defined the triggers and actions as needed, click Save changes to save the configurations. If any nodes or fields contain errors or missing configuration details, the workflow cannot be saved and an error message will display. Resolve all flagged issues before attempting to save again.
- Click the Schedule card to view the Add Schedule panel on the right.
- Select Schedule Type: Choose how often the workflow should execute.
- Run Once: The workflow runs exactly one time at the specified date and time.
- Recurring: The workflow runs at regular intervals (for example: daily, weekly, or monthly).
- To have the workflow run once:
- Select a valid date.
- Select a start time.
- Define the Timezone
Ensure your start time is set at least a few minutes into the future relative to your current timezone to ensure successful deployment.
- To have the workflow run at regular intervals:
- Frequency: Select how often you want the workflow to run.
- Run every: Select the specific interval within the chosen frequency. For example, if Frequency is set to Daily, selecting 1 day will trigger the workflow every single day. Selecting 2 days will trigger it every other day.
- Time: Select the time
- Timezone: Define the Timezone.
Be mindful of high-frequency schedules (like Hourly). Ensure your workflow logic is optimized to complete before the next scheduled run triggers.
- Defining Workflow Actions: Once the trigger condition is added, click + to add an action node. You can select the Action type and define the actions (the specific tasks to execute) for the workflow. See Defining Workflow Actions to learn more.
- You can choose to define actions or use flows.
- Actions are individual operations performed on your directory or resources. You can either add Custom Actions or use JumpCloud API actions. See JumpCloud Workflows Public API & DSL Guide to learn more.
- Flows allow you to move beyond simple linear automation. You can use them to add complex decision-making logic and efficiency into your workflow. You can either use Loops or If-else flows or a combination of both.
- To add more actions, click +.
- You can choose to define actions or use flows.
- Choosing Execution Role (Run as): Next, you must identify the role that has the permission to perform the actions you’ve added in the Workflow.
- On the top pane, click Select next to Run As.
- On the Choose Execution Role dialog, select the narrowest role from the dropdown.
- Once you’ve defined the triggers and actions as needed, click Save changes in the unsaved changes floating panel to save the configurations.
Your workflow will be saved and enabled by default. You can use the toggle to disable it if needed.
The workflow runs as per the schedule you defined during configuration. You can verify the workflow execution details in the Execution History tab.