# Web Chat

ClearFeed allows customers to create tickets by initiating conversations through a chat widget embedded on your website. This guide explains how web chat-based ticket creation works in ClearFeed.

{% hint style="info" %}
**ClearFeed Tickets Only:** This method is only available for **ClearFeed's native ticketing system**. For external ticketing systems (Zendesk, Jira, etc.), refer to your [integration-specific documentation](https://github.com/clearfeed/new-docs/blob/main/how-it-works/creating-or-linking-tickets/integrations/task-and-ticketing-systems.md).
{% endhint %}

## How Web Chat Ticketing Works

When a customer initiates a chat on your website, ClearFeed automatically:

1. **Creates a ticket** from the conversation
2. **Posts the chat messages** to your configured Triage Slack channel
3. **Syncs replies bidirectionally** - Team replies in Slack appear in the chat widget in real-time
4. **Sends email notifications** - If the customer goes offline, responses are sent via email
5. **Maintains conversation history** - Customers can view and reinitiate previous conversations

**Benefits:**

* Customers get instant support without leaving your website
* Your team manages everything in Slack
* Real-time bidirectional communication
* Automatic fallback to email for offline customers
* Full conversation history maintained

## Prerequisites

{% hint style="warning" %}
**Email Setup Required:** Web Chat requires email integration to be configured first, as email is used to notify customers when they go offline. Set up email before configuring web chat.
{% endhint %}

**Setup Steps:**

1. [Configure email integration](https://docs.clearfeed.ai/clearfeed-help-center/sources/email) first
2. Then [set up the web chat widget](https://docs.clearfeed.ai/clearfeed-help-center/sources/web-chat)

## Creating Tickets via Web Chat

### For Customers

Customers create tickets by using the chat widget on your website:

1. Customer clicks the **chat widget icon** on your website
2. Types their message or question
3. Sends the message
4. A ticket is automatically created in ClearFeed
5. Customer receives responses in real-time in the chat widget
6. Can view previous conversations and reinitiate them

**What the customer sees:**

* Real-time responses from your team
* Conversation history for reference
* Email notifications if they go offline
* Seamless chat experience without leaving your site

### For Responders

When a customer initiates a chat:

1. A new ticket appears in your **Triage Slack channel**
2. The chat message is posted as a new request
3. Team members can respond directly in the Slack thread
4. Responses are instantly sent to the customer via the chat widget
5. If customer goes offline, responses are automatically sent via email

**Responding to chat tickets:**

* Reply in the Slack thread - customer sees it in real-time
* Add internal notes for team collaboration
* Convert chat to tasks if needed
* Full conversation context available

## Email Notification Behavior

Web chat includes intelligent email notifications to ensure customers don't miss messages:

### When Customer is Offline

* Agent replies are **immediately sent via email**
* Email includes the full response
* Customer can reply via email to continue the conversation

### When Customer is Online

* ClearFeed waits **15 minutes** before sending email
* If customer replies during this period, **email is not sent**
* If customer doesn't respond within 15 minutes, a **consolidated email** with agent replies and a link to the conversation is sent

{% hint style="info" %}
Note:

* The default waiting period is **15 minutes**. To change this duration, contact the [ClearFeed Support team](mailto:support@clearfeed.ai).
* By default, all outgoing emails are sent from custom email address configured in your account.
  * Emails sent using the custom email address will not be threaded in the recipient’s inbox.
  * Each outgoing email always includes the last 5 messages from the conversation as context.
    {% endhint %}

## FAQs

1. **What happens if the customer closes the chat?**

   **Answer:** The conversation is saved and they can reinitiate it later. If an agent responds while they're offline, the response is sent via email.
2. **Can multiple agents respond to the same chat?**

   **Answer:** Yes, all agents with access to the Triage Channel can see and respond to chat tickets. We recommend coordinating to avoid duplicate responses.
3. **How do customers access their previous chats?**

   **Answer:** When they open the chat widget, they see a list of their previous conversations and can click to reinitiate any of them.
4. **Can I set operating hours for the chat widget?**

   **Answer:** Yes, you can configure operating hours in the Web Chat settings. Outside these hours, the widget can display a custom message or hide entirely.
5. **How is the 15-minute email delay customizable?**

   **Answer:** Contact [ClearFeed Support](mailto:support@clearfeed.ai) to adjust the waiting period before sending consolidated emails to online customers.
