Actions
Actions in Thena workflows are the tasks that are performed when a workflow is triggered and its conditions are met. This guide explains how to set up and manage actions effectively.What are actions?
Actions are the operations that a workflow performs to automate tasks. They can modify tickets, send notifications, update records, or integrate with external systems.Types of actions
Thena supports several types of actions:Ticket actions
- Update ticket: Modify ticket fields, status, priority, etc.
- Add comment: Add internal or public comments to a ticket.
- Add tags: Add or remove tags from a ticket.
- Assign ticket: Assign a ticket to an agent or team.
- Create ticket: Create a new related ticket.
- Close ticket: Close a ticket with a specific resolution.
- Merge tickets: Combine duplicate tickets.
Notification actions
- Send email: Send an email to specified recipients.
- Send SMS: Send an SMS message.
- Send push notification: Send a push notification to mobile devices.
- Send Slack message: Post a message to a Slack channel.
- Send MS Teams message: Post a message to a Microsoft Teams channel.
User actions
- Create user: Create a new user account.
- Update user: Modify user properties or permissions.
- Deactivate user: Temporarily disable a user account.
- Add to group: Add a user to a group.
Data actions
- Set variable: Set a workflow variable value.
- Increment counter: Increase a numeric value.
- Calculate value: Perform a calculation and store the result.
- Transform data: Convert data from one format to another.
Integration actions
- API call: Make an HTTP request to an external API.
- Webhook: Send data to a webhook endpoint.
- Run script: Execute a custom JavaScript script.
- Database query: Perform a database operation.
Creating actions
To add actions to your workflow:- Navigate to the Workflows section in your Thena dashboard.
- Open the workflow you want to modify.
- Click the “Actions” section.
- Click “Add Action” to create a new action.
- Select the type of action you want to create.
- Configure the action settings.
- Save your action configuration.
Action configuration
Each action type has specific configuration options:Basic actions
For basic actions, you can specify:- The target of the action (ticket, user, etc.).
- The operation to perform.
- The values to set or update.
- Any additional options.
Advanced actions
For advanced actions, you can specify:- Custom scripts or API endpoints.
- Request parameters and headers.
- Authentication details.
- Response handling.
- Error handling.
Action sequences
You can create sequences of actions that execute in order:- Add multiple actions to your workflow.
- Arrange them in the desired execution order.
- Configure dependencies between actions.
- Set up conditional branching for different action paths.
Action variables
Actions can use variables from various sources:- Trigger data: Information from the triggering event.
- Workflow variables: Values set within the workflow.
- System variables: Global values like current time or user.
- Custom variables: User-defined values.
- Click the variable picker icon in the action configuration.
- Select the variable you want to use.
- The variable will be inserted as a placeholder.
- At runtime, the placeholder will be replaced with the actual value.
Action templates
Thena provides templates for common actions:- In the action configuration, click “Templates.”
- Browse available templates.
- Select a template that matches your needs.
- Customize the template as needed.
- Save your customized action.
Testing actions
Before activating a workflow, you should test its actions:- In the workflow editor, click the “Test” button.
- Select the action you want to test.
- Provide any necessary test data.
- Run the test to verify the action works as expected.
- Review the test results.
- Make adjustments if needed.
Action examples
Here are some common action examples:Example 1: Escalate high priority ticket
Example 2: Auto-respond after hours
Best practices
- Start with simple actions and build complexity gradually.
- Use variables to make actions dynamic and reusable.
- Test actions thoroughly before deploying them.
- Document complex actions for future reference.
- Monitor action performance and errors.
Troubleshooting
If an action fails, you can:- Check the workflow execution logs.
- Verify that all required data is available.
- Test the action independently.
- Check for permission issues.
- Verify external system availability for integration actions.