Citrix Secure Developer Spaces™

Custom Actions

Custom Actions let you automate routine platform maintenance. You define a rule made of three parts — an action to run, the conditions that decide which workspaces or users it applies to, and when it runs. A common example is deleting workspaces that have been inactive for a long time.

Find this setting at Settings > General > Custom Actions.

Custom actions settings page

How a custom action is built

Every custom action combines three parts.

Action — what runs

Action What it does
Update Workspace Applies an update to each matching workspace, such as an image update.
Delete Workspace Deletes each matching workspace.
Notify User Sends an in-platform notification with a message you write to each matching user.

Condition — which workspaces or users it applies to

Add one or more conditions to target the action. Available conditions include:

  • Organization: Limit to workspaces in specific organizations.
  • Project: Limit to workspaces in specific projects.
  • User: Limit to workspaces owned by specific users.
  • Inactive Workspace: Match workspaces that haven’t been used for a set number of days.
  • After and Before: Limit the action to a time window by setting a start date, an end date, or both.

When — how the action is scheduled

The When field controls the schedule. It offers three options:

Option Behavior
Once Runs one time, at the date and time you set.
Time Period Runs on a repeating schedule, such as every 30 days.
When Condition Met Runs continuously in the background and applies the action whenever the conditions are met. This option appears only after you add at least one condition.

“When Condition Met” versus “Time Period”

This is the key choice for a maintenance rule like deleting inactive workspaces, so it’s worth understanding how each option behaves.

When Condition Met evaluates your conditions on a recurring background cycle, roughly every 15 minutes. Each cycle, it finds everything that currently matches and applies the action. It doesn’t wait for a scheduled date. As soon as a workspace crosses your inactivity threshold, it’s picked up in the next cycle.

Time Period runs on the fixed interval you set — for example, every 30 days. The conditions only decide which workspaces are affected when that scheduled run happens. Anything that becomes a match between two scheduled runs waits until the next run.

For a rule like “delete a workspace when it’s been inactive for 365 days,” When Condition Met is the right choice. The action checks continuously and deletes each workspace shortly after it passes 365 days of inactivity — not on a separate schedule you’d have to keep in sync.

Note:

With When Condition Met, the action doesn’t run “once a day until the condition is met.” It re-evaluates on a short background cycle (about every 15 minutes) and acts as soon as something matches. Because a deleted workspace no longer exists, it isn’t matched again — each workspace is deleted once.

Example: delete workspaces inactive for 365 days

  1. Go to Settings > General > Custom Actions and start a new action.
  2. For the action, select Delete Workspace.
  3. Add a condition, select Inactive Workspace, and set the period to 365 days.
  4. For When, select When Condition Met.
  5. Save the action.

The platform now checks continuously. Any workspace that reaches 365 days without use is deleted automatically within the next evaluation cycle.

Note:

Inactivity is measured from a workspace’s last recorded use. A workspace that has never been opened isn’t matched by the Inactive Workspace condition.