# Actions

Actions are the things your agent can do — reply to customers, tag tickets, assign to team members, look up information, and more. You configure which actions are available, and your agent uses them when appropriate based on its [instructions](https://docs.eesel.ai/configure-your-agent/instructions).

## How actions work

Your agent doesn't blindly execute actions. It reads the incoming message, considers its instructions and knowledge, and decides which actions to take:

```
 ┌────────────┐     ┌──────────────────────────┐     ┌──────────────┐
 │ Incoming    │     │      Agent decides:       │     │   Results:   │
 │ ticket:     │────▶│                           │────▶│              │
 │ "Where's    │     │  1. Search order status   │     │  Reply sent  │
 │  my order?" │     │  2. Reply with tracking   │     │  to customer │
 │             │     │  3. Tag as "order-status"  │     │              │
 └────────────┘     └──────────────────────────┘     └──────────────┘
```

## Setting up actions

1. Open your agent workspace
2. Go to **Settings > Actions**
3. Click **Add Action**
4. Select the action type
5. Configure options (including [Human in the Loop](https://docs.eesel.ai/configure-your-agent/human-in-the-loop) if desired)
6. Save

## Available actions by integration

### Helpdesk actions

These actions are available when you connect a helpdesk integration (Zendesk, Freshdesk, Intercom, Gorgias, Jira):

#### Responding to customers

| Action                  | Description                            | Available on                          |
| ----------------------- | -------------------------------------- | ------------------------------------- |
| **Leave Public Reply**  | Send a response the customer sees      | Zendesk, Freshdesk, Intercom, Gorgias |
| **Leave Draft Reply**   | Create a draft for your team to review | Zendesk, Freshdesk, Intercom, Gorgias |
| **Leave Internal Note** | Add a note only your team sees         | Zendesk, Freshdesk, Intercom, Gorgias |
| **Comment on Issue**    | Add a comment to a Jira issue          | Jira                                  |

#### Ticket management

| Action              | Description                               | Available on                                |
| ------------------- | ----------------------------------------- | ------------------------------------------- |
| **Tag Ticket**      | Add tags for categorization               | Zendesk, Freshdesk, Intercom, Gorgias       |
| **Assign Ticket**   | Route to a specific team member           | Zendesk, Freshdesk, Intercom, Gorgias, Jira |
| **Assign to Group** | Route to a team queue                     | Zendesk, Freshdesk                          |
| **Close Ticket**    | Mark as resolved                          | Zendesk, Freshdesk, Intercom, Gorgias       |
| **Create Ticket**   | Open a new ticket                         | Zendesk, Freshdesk, Gorgias                 |
| **Update Ticket**   | Change status, priority, or custom fields | Zendesk, Freshdesk, Intercom                |
| **Label Issue**     | Add labels to a Jira issue                | Jira                                        |

#### Information lookup

| Action                | Description                                | Available on                       |
| --------------------- | ------------------------------------------ | ---------------------------------- |
| **Read Ticket**       | Read full ticket with conversation history | Zendesk, Freshdesk, Intercom       |
| **Search Tickets**    | Search past tickets                        | Zendesk, Freshdesk, Intercom, Jira |
| **List Tickets**      | List tickets with filters                  | Zendesk, Freshdesk, Intercom       |
| **Get User by Email** | Look up user details                       | Zendesk, Intercom                  |
| **Get Organization**  | Retrieve organization info                 | Zendesk                            |
| **Get Ticket Fields** | Read custom field values                   | Zendesk, Intercom                  |

### Shopify actions

| Action                        | Description                             |
| ----------------------------- | --------------------------------------- |
| **Get Order History**         | Look up a customer's orders by email    |
| **Get Order by ID**           | Get detailed order info                 |
| **Get Customer by Email**     | Look up customer profile                |
| **Search Products**           | Search the product catalog              |
| **Get Products**              | Retrieve product details                |
| **Get Product Variants**      | Get size, color, SKU, price, inventory  |
| **Get Order Fulfillment**     | Check shipping and tracking status      |
| **Create Return**             | Initiate a product return               |
| **Refund Order**              | Process a refund                        |
| **Cancel Order**              | Cancel an unfulfilled order             |
| **Generate Product Carousel** | Create a visual product display in chat |

### Slack actions

| Action           | Description                       |
| ---------------- | --------------------------------- |
| **Send Message** | Send a message to a Slack channel |

### Gmail actions

| Action                 | Description                              |
| ---------------------- | ---------------------------------------- |
| **Search Emails**      | Search emails using Gmail syntax         |
| **Read Email**         | Read a full email by ID                  |
| **Send Email**         | Send an email with optional CC/BCC       |
| **Get Email from URL** | Extract an email thread from a Gmail URL |

### Zendesk Messenger actions

| Action                      | Description                                  |
| --------------------------- | -------------------------------------------- |
| **Send Messenger Reply**    | Reply in the Zendesk Messaging Widget        |
| **Transfer to Human Agent** | Hand off a Messenger conversation to a human |

## Tips for configuring actions

**Start with fewer actions.** Give your agent only the actions it needs. Too many options can lead to confusion.

**Match actions to instructions.** If you give your agent a "Close Ticket" action, make sure your instructions explain when to use it.

**Use draft replies first.** When starting out, use "Leave Draft Reply" instead of "Leave Public Reply" until you trust the agent's judgment.

**Enable HITL for sensitive actions.** Turn on [Human in the Loop](https://docs.eesel.ai/configure-your-agent/human-in-the-loop) for actions with significant impact (refunds, ticket closure, public replies).

**Describe actions in your instructions.** Explicitly tell your agent when to use each action. For example: "After resolving a simple how-to question, tag the ticket and close it."
