Skip to main content

Cycle

These steps take you through placing a registered agent you use in chat on a step, checking that it sweeps on the schedule you set, and stopping it.

Introduction​

What you place on a cycle's steps are agents that an administrator registered and enabled in the admin console (the same agents used in chat). Unlike a workflow, no contract or certification is needed. Before you begin, check the following.

What to checkWhy
The registered agent you want to place is enabled in the admin consoleOnly enabled agents are listed
The agent is built to exit its process after processingIf it does not exit, the next sweep keeps being skipped (Your First Agent)
If the agent has secret environment variables, an administrator has set “Environment variables users cannot override (deny list)”So that users cannot swap where things are sent (Settings Guide)

When you create a project, a cycle comes with two steps already in place. This Quickstart places one registered agent on “Step 1” and turns off “Step 2”, which it does not use. While there is an enabled step with no agent placed, you cannot apply.

Work on a computer, with the browser window wide.

Step 1: Create a project​

  1. Open “Projects” on the left, choose “Projects” at the top, and press “New project”
  2. Choose “Cycle” as the type. In the Marketplace edition, “Workflow” is selected at first, so switch it
  3. Enter a name and press “Create”

Once it is created, the editor opens straight away.

Step 2: Place a registered agent on a step​

  1. Under “Editing tools” on the left, press “Add Agent”. The list switches to the list of registered agents
  2. Select the agent you want to place, and press “1. Step 1” under “Place on a step” in “Agent details” on the right. “Agent placed” appears

When you place a registered agent for the first time, it is saved to the project on the spot.

  1. Select “Step 2” in the diagram in the middle, open “Details” under “Step settings” on the right, and turn off “Enabled”

Step 3: Enter environment variables (only when needed)​

Enter them only when there are values you want to pass to the agent on this step.

  1. In the diagram in the middle, select the agent placed on “Step 1”. The heading on the right becomes “Agent on this step”
  2. Under “Basic settings” > “Environment variables”, press “Add variable” and enter a name and value. To change a value already registered for the agent, press “Override” on that row
  3. Press “Save”. “Environment variables saved” appears

Names the administrator has blocked from change, and names registered as secrets, cannot be changed (Agent Guide).

Step 4: Set the sweep schedule​

  1. Under “Agent on this step” on the right > “Trigger” > “Sweep schedule”, turn on “Enable sweeping”. The “Interval” becomes every 15 minutes

While any placement has no schedule set, you cannot apply.

Step 5: Check and apply​

  1. Press “Check settings” at the top of the editor, make sure it shows “OK”, and close it. If “Step 2: place an agent” appears, check that you turned off Step 2 in item 3 of Step 2
  2. Press “Apply changes”, then “Apply” in “Review changes to apply”

Step 6: Wait for the first sweep​

  1. Go back to the project screen with “Back to the project”

A cycle has neither “Start case” nor “Run now”. Sweeps start on the schedule. With every 15 minutes, the first sweep starts within about 15 minutes of applying. It may take a few more minutes before the agent starts working.

While the previous sweep is still running, the next sweep is skipped. If one round of processing takes the agent 15 minutes or more, lengthen the interval.

Step 7: Look at the result​

  1. Open the “Execution history” tab. Rows showing “Sweep” in the “Started by” column are listed
  2. Select the run time on the row you want; the run record for that execution opens

A result of “Run ended (completion not measured)” is normal. It means the agent exited normally but did not report whether it did its job. It is counted as neither a success nor a failure. Check what it did in that execution's conversation (Record Guide).

To stop an execution that is running, press “Stop” in its run record.

Step 8: Stop it​

  1. Press “Pause” at the top of the project screen, then “Pause” in “Pause project”

Until you stop it, the sweep carries on every 15 minutes. To run it again, press “Resume”.