# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
This site has an agentic ask interface you may use to query the documentation dynamically by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.zipchat.ai/index.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

---

# What is Zipchat AI

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FUQRgMHQOSAnFxduNheN3%2F1.png?alt=media&amp;token=35bfd61f-9f49-4efa-b76c-73c467ee2bfc" alt=""><figcaption><p>AI Chatbot for Ecommerce</p></figcaption></figure>

### **What Is Zipchat AI**

**Zipchat AI** is an **AI Agent for eCommerce** — a next-generation system that helps **Shopify and online stores** sell more, support faster, and communicate smarter.\
It combines an **AI Chatbot**, **AI Sales Assistant**, and **WhatsApp Marketing Agent** into one platform that works automatically across your website and WhatsApp.

***

#### **Why Zipchat AI Exists**

Most eCommerce stores lose sales because customers leave before buying or can’t get quick answers.\
Traditional chatbots fail because they reply with scripted, generic messages that don’t actually help.

**Zipchat AI** was created to solve this.\
It acts like a **real sales agent powered by AI** — understanding your products, store data, and customer behavior to give **personalized, real-time conversations** that guide visitors to checkout.

***

#### **The Core Missions of Zipchat AI**

**🤑 1. Sell More**

Zipchat detects buying intent and starts conversations automatically.\
It answers pre-sale questions, suggests the right products, and helps visitors complete their purchase — turning traffic into revenue.

**🤝 2. Support Smarter**

It handles 24/7 support on both your **website chat** and **WhatsApp**, instantly resolving common issues like order tracking, returns, or FAQs.\
This keeps customers happy while reducing support workload.

**📊 3. Learn and Improve**

Every interaction teaches the AI more about your audience.\
It identifies what customers ask most, what stops them from buying, and what products convert best — giving you **actionable insights** to improve your store and marketing.

***

#### **The Zipchat AI Difference**

With Zipchat, you don’t just add a chatbot.\
You deploy a **fully trained AI Sales Agent** that:

* Works across chat and WhatsApp automatically
* Learns from your catalog, FAQs, and support data
* Delivers **1-to-1 customer experiences at scale**
* Helps brands **increase conversions and reduce cart abandonment**

***

**Zipchat AI** turns your eCommerce store into a living, learning sales system — one that sells, supports, and grows smarter every day.


# WhatsApp

This section contains everything you need to know about the Zipchat x WhatsApp Integration.

### Why WhatsApp <a href="#why-whatsapp" id="why-whatsapp"></a>

WhatsApp is a service and marketing channel with incredible potential; it’s the most used messaging app in Europe, LATAM, India, and it’s growing fast in the United States

Main reasons to use WA:

* Open rate of marketing messages: 85%
* Click-through-rate: 15%
* Automatic collection of the customer’s Name, Surname and Phone Number
* 24 hours to keep the conversation going, while if someone texts you on your website, as soon as they close the browser you cannot reach to them
* You are always in your customers pocket, one conversation away
* Most importantly - customers EXPECT to speak with you on WA


# Add a Payment Method to your WhatsApp Business Manager

**Why this matters**

Starting October 1, 2026, Meta requires every business to have a payment method on file in WhatsApp Business Manager. From that date, all messages, including service messages, are billed by Meta. Without a valid payment method, your WhatsApp channel will stop working, and so will the WhatsApp features you use in Zipchat. Full details on the new pricing are available on Meta's [WhatsApp Business Platform pricing page](https://developers.facebook.com/documentation/business-messaging/whatsapp/pricing).

**What you need**

* Admin access to your Meta Business Suite
* A Visa or Mastercard debit or credit card

**Steps**

1. Go to [Meta Business Suite](https://business.facebook.com/) and log in.
2. In the left-hand menu, scroll down and click **All Tools**.
3. Scroll to **Billing and Payments** and select **Payment Methods**.
4. If you manage more than one account, select the correct **WhatsApp Business account**.
5. Click the button to **add a payment method** and choose your currency.
6. Enter your card details and save.
7. If not automatically set, click on the 3-dots menu on the card and click on **Set as default**.
8. Go back to **Zipchat** → **Chat settings** → **WhatsApp** card → **Add payment method** -> **I added a payment method**.

**Video Guide**

{% embed url="<https://www.loom.com/share/549af76ca9ee491694ee714f39ab48c7>" %}


# Product Full DEMO

{% embed url="<https://youtu.be/xVaVE2S-SSY?si=SlREvkHYddMHBJsw>" %}


# 3 Minutes Interactive DEMO

{% embed url="<https://app.arcade.software/share/er7u8hcxN30TlFJQyBfH>" %}


# Why Choose Zipchat AI?

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2Fj3Y6l0qs3W99qszTxo0T%2FScreenshot%202024-11-23%20at%2013.09.10.png?alt=media&amp;token=2f5a80f0-eded-40d3-b0c7-a2c0ba732513" alt=""><figcaption></figcaption></figure>

Zipchat AI isn’t just another chatbot – it’s your secret weapon for growing your e-commerce business. Here’s why it’s a must-have for any online store:

***

### 1. **Turn Visitors into Buyers 🤑**

Zipchat helps you convert curious browsers into paying customers by answering questions, offering recommendations, and addressing concerns in real time. It’s proven to reduce cart abandonment and boost conversions – with users seeing up to 5x more sales from hesitant shoppers.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FV069t1fXoDogKXW0YHl5%2F2.webp?alt=media&amp;token=38b45b61-f29c-4dd3-a924-6f9b215d69c6" alt=""><figcaption></figcaption></figure>

***

### 2. **Proactively Engages Shoppers 😎**

Unlike traditional chatbots, Zipchat doesn’t sit back and wait. It starts the conversation, offering help or nudging customers to act based on their behavior. For example, if someone lingers on a product page, it might suggest similar items or explain benefits, keeping them engaged.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FX7jIPUUx5aegZ2lx6Hfn%2F4.webp?alt=media&amp;token=29b785f6-97e8-4115-9d80-65938fcfe312" alt=""><figcaption></figcaption></figure>

***

### 3. **Always On, Always Ready 😈**

Your customers shop at all hours, and Zipchat is ready 24/7. Whether it’s answering a question about a product, helping track an order, or solving a problem, Zipchat ensures customers always get the support they need – no waiting, no frustration.

***

### 4. **Works Seamlessly with Shopify 🛍️**

If you’re on Shopify, you’re in luck. Zipchat syncs directly with your store’s catalog, giving customers real-time info about products, pricing, or availability. It’s a smooth setup, too – no plugins, no hassle.

Not on Shopify? Absolutely not problem. You can copy/paste a simple line of code and Zipchat is ready to be activated on your store.

***

### 5. **Drives More Sales 📈**

Zipchat doesn’t just chat – it sells. Its Proactive Chat feature sends targeted messages at key moments, like offering a discount when someone hesitates at checkout. These gentle nudges can turn “maybe” into “yes” faster than you think.

Versatility is at our core, build whatever logic you like with Zipchat.

***

### 6. **Speaks Your Customers’ Language 🤟**

Zipchat supports 95+ languages, so it’s perfect for today businesses.  Whether your audience is in Paris, Tokyo, or São Paulo, Zipchat makes sure they feel understood and valued.

Selling only to one country? Consider this. Thanks to globalization, expats are everywhere. Make sure to speak to them too.

***

### 7. **Gives You Data That Matters 👨‍💻**

What are your customers asking? What’s stopping them from buying? Zipchat doesn’t just handle chats – it tracks trends and reveals insights that help you improve your website, marketing, and sales strategies.

***

### 8. **Quick to Set Up, Easy to Customize 🍳**

No tech wizardry required! You can have Zipchat running in minutes. Match it to your brand’s colors, style, and tone. Add custom chat triggers and watch it fit perfectly into your business.

***

### 9. **Grows with Your Business 🚀**

From small startups to bustling enterprises, Zipchat scales with you. Whether you need it to handle a few chats a day or thousands during a Black Friday rush, it’s built to keep up without breaking a sweat.

***

### 10. **Boosts ROI from Day One ✅**

Most users start seeing sales directly from Zipchat during their free trial. It’s not just a tool; it’s an investment that pays for itself – fast.

***

### Ready to level up your e-commerce game?

Zipchat AI is the perfect blend of smart technology and customer-first service, designed to help you sell more, stress less, and grow faster. Don’t let your visitors slip away – let Zipchat turn them into loyal customers today.&#x20;


# AppSumo Hub

AppSumo License: Redeem, Activate & Get Started

Welcome, Sumo-ling! 👋

You just grabbed Zipchat AI on AppSumo. Great choice. This guide walks you through every step to redeem your license, create your account, and launch your first AI agent. The whole process takes about 3 minutes.

***

### Step 1: Find Your Zipchat AI Purchase on AppSumo

Log in to your [AppSumo account](https://zipchat.click/appsumo-deal) and head to **Products**.

You can get there in two ways:

* Click **Products** in the left sidebar, or
* Click your profile icon in the top-right corner and select **Products** from the dropdown menu.

You'll see **Zipchat AI (License Tier 1)** listed under your active products.

![Find Zipchat AI in your AppSumo Products page](https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FieYVCWYa6DTr56sWsNbt%2FXnapper-2026-02-22-10.41.01.jpg?alt=media\&token=11701f09-2244-43ec-bba7-c944d7125c93)

***

### Step 2: Open the Activation Page

From the Products page, click **"Activate now"** next to your Zipchat AI purchase.

This takes you to the **Activate your purchase** page for Zipchat AI.

> ⏰ **Important:** You must activate your license before the deadline shown (e.g., March 21, 2026). After that date, the license expires and can no longer be activated.

![Click Activate now to begin](https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FGqo2Ee5WLJl2B7cZNhfJ%2FXnapper-2026-02-22-10.41.55.jpg?alt=media\&token=07c4009d-82d0-47e5-979b-e6ffa6a88697)

***

### Step 3: Choose Add-Ons (Optional)

Before activating, you'll see an **Available add-ons** section. These are completely optional. You can skip them and activate with just your base license.

The available add-ons include:

* **Remove "Powered by Zipchat" branding** for +$99 (one-time)
* **Website deployments** at $125 per 25 extra website deployments (up to 100)
* **Extra monthly pages** at $50 per 10,000 extra pages (up to 40,000)

> ⚠️ Add-ons are **non-refundable**, so only purchase them if you're sure you need them. You can always add them later.

If you don't need any add-ons, just ignore this section.

![Available add-ons section](https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FyLBG7L6Uu6qGYLExZ1Uz%2FXnapper-2026-02-22-10.43.06.jpg?alt=media\&token=2c306037-a4b1-4e2f-8667-ee5abbc035fb)

***

### Step 4: Click "Activate Now"

Once you're ready, click the yellow **"Activate now"** button on the activation page.

A popup will appear with an important message:

> **Before you activate:** Please make sure you're **logged out of all existing accounts on the Zipchat AI website**. This ensures your AppSumo license is correctly attached to the right account and prevents activation issues. 👀

If you've never used Zipchat before, you're good to go. Just click **"Activate"**.

If you already have a Zipchat account, open a new tab, go to [app.zipchat.ai](https://app.zipchat.ai/), log out first, then come back and click **"Activate"**.

> **Note:** you cannot activate an AppSumo licence on an account or store previosly activated on Zipchat. Since the deal is limited and for new client only, you need a new account and a new store/site.

![Before you activate: log out warning](https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FVb75KkCZZ91yfxLwrfqZ%2FXnapper-2026-02-22-10.42.12.jpg?alt=media\&token=b8cd1f54-e771-4d8a-8591-5c07ba84b6ee)

***

### Step 5: Allow AppSumo to Connect with Zipchat AI

After clicking Activate, a permissions dialog will appear asking you to let **Zipchat AI read your AppSumo license key**.

This is standard and safe. It simply allows Zipchat to verify your purchase and set up your account with the correct plan.

Click **"Allow"** to continue.

![Allow Zipchat AI to access your AppSumo license](https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2Fnfb8OKxtrqcFRKvO09pZ%2FXnapper-2026-02-22-10.44.37.jpg?alt=media\&token=33bb8609-e01e-42c7-831f-c7f4f1e2c9fa)

***

### Step 6: Create Your Zipchat AI Account

You'll land on the **Zipchat + AppSumo** signup page.

Fill in:

* **Email** : Use the email you want for your Zipchat account (you'll need to confirm it).
* **Password** : Minimum 8 characters (12 recommended for best security).
* **Confirm Password** : Re-enter the same password.

Then click **"Sign up"**.

Your AppSumo license will be automatically linked to this new account. No codes or keys to enter.

![Create your Zipchat AI account](https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F0rw5tNPW42Aq04lsIWZ9%2FXnapper-2026-02-22-10.45.12.jpg?alt=media\&token=9989fa3f-8141-4d0e-bcaf-fbc2777933f9)

***

### Step 7: Create Your First AI Agent

After signing up, you'll be taken to your **Zipchat dashboard**.

Click the **"Create agent"** button on the right side of the screen.

![Click Create agent on the dashboard](https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FZox7c3AagjLVWjUnODKF%2FXnapper-2026-02-22-10.46.08.jpg?alt=media\&token=320aa1a6-1d53-47b9-ae8e-62cabb3b40b4)

A dialog will appear asking for your **website URL**. Enter the full URL of your online store (e.g., `https://yourwebsite.com`) and click **"Create"**.

Zipchat will immediately start crawling your website to build the AI's knowledge base, learning about your products, pages, and content so it can start helping your customers right away.

![Enter your website URL to create your AI agent](https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2Fi3Hdtp1KMBKnJvPu0gy4%2FXnapper-2026-02-22-10.46.20.jpg?alt=media\&token=ff44361d-55a1-4df0-a1aa-38010d531591)

***

### 🎉 That's It. You're Live!

Your AI agent is now being created and trained on your website data. From here, you can:

* [**Customize your chat widget**](https://docs.zipchat.ai/installation-and-setup/chat-settings/channels/bubble-chat-edit-design) to match your brand
* [**Train your AI agent**](https://docs.zipchat.ai/installation-and-setup/ai-training/knowledge-base) with additional knowledge (PDFs, FAQs, custom instructions)
* **Install the chat script** on your website, **Account > Chat Settings > Scripts & Integrations**
* **Test your chatbot** to make sure everything works perfectly

For a complete walkthrough of all features, check out the [**Product Full Demo**](https://docs.zipchat.ai/product-full-demo) or the [**3-Minute Interactive Demo**](https://docs.zipchat.ai/3-minutes-interactive-demo).

***

### Managing Your AppSumo License

You can manage your Zipchat AI license anytime from your [AppSumo Products page](https://appsumo.com/account/products/).

Click the **"Select"** dropdown next to your Zipchat AI purchase to access these options:

* **Redemption information** : View details about your license and activation status
* **View invoice** : Download your purchase receipt
* **Product details** : See the full product listing page
* **Refund** : Request a refund (see below)

![Manage your license from the Select dropdown](https://claude.ai/chat/screenshot-9-dropdown.png)

***

#### How to Purchase Add-Ons After Activation

If you skipped add-ons during activation and want to grab them later, here's how:

1. Go to your [AppSumo Products page](https://appsumo.com/account/products/).
2. Click **"Select"** next to Zipchat AI.
3. Select **"Redemption information"** or visit the activation page.
4. Scroll down to **"Available add-ons"**.
5. Select the add-ons you want and complete the purchase.

Add-ons are linked to your license tier and will be automatically activated in your Zipchat account.

> Remember: Add-ons are **non-refundable**, so make sure you need them before purchasing.

***

#### How to Request a Refund

Your AppSumo purchase is backed by a **60-day money-back guarantee**. If Zipchat isn't the right fit, here's how to request a refund:

1. Go to your [AppSumo Products page](https://appsumo.com/account/products/).
2. Click **"Select"** next to Zipchat AI.
3. Select **"Refund"** from the dropdown.
4. Follow the prompts to complete your refund request.

You can also visit the [AppSumo Help Center](https://help.appsumo.com/) for more information about refund policies and timelines.

> **Note:** Refunds are eligible through the date shown on your activation page (e.g., "Eligible through March 21, 2026"). Add-ons purchased separately are non-refundable.

***

### Need Help?

If you run into any issues during activation or setup:

* **Chat with us** on the bottom-right of [zipchat.ai](https://zipchat.ai/) or inside the app
* **Email us** at <support@zipchat.ai>
* **Contact Zipchat AI** from your AppSumo activation page
* **Contact AppSumo Support** for billing or license issues
* **Browse the docs** right here at [docs.zipchat.ai](https://docs.zipchat.ai/)

Welcome aboard. We're excited to have you! 🚀


# Trial/Installation

👉 If you are on Shopify, [follow this procedure.](/installation-and-setup/trial-installation/for-shopify-users)

👉 If you are on any other CMS (Woocommerce, Magento, Wp, Bigcommerce, custom, etc), [follow this procedure.](/installation-and-setup/trial-installation/for-non-shopify-platforms)


# For Shopify Users

Go to <https://apps.shopify.com/zipchat>&#x20;

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FkJjVGAbjEJsLZj7gTBCh%2FScreenshot%202024-08-23%20at%2017.00.57.png?alt=media&amp;token=69a0bde3-28a3-4b84-9865-cf3ec07d7420" alt=""><figcaption></figcaption></figure>

* Click on Install.
* Follow the steps to create an account.
* Accept the terms and conditions of Shopify.
* Start a trial by choosing the plan that best suites your needs (*you can cancel/downgrade/upgrade anytime, don't worry)*.

Once you have installed the Shopify App, you will be redirected to the [Dashboard](/installation-and-setup/dashboard) you need to proceed with the training [AI Training](/installation-and-setup/ai-training).


# For Non-Shopify Platforms

If you are not using Shopify, you can rely on this section. You can visit [Zipchat.ai ](https://zipchat.ai/)

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FZJo1jvAms3Zi1pCOYYJy%2FScreenshot%202024-11-23%20at%2013.32.32.png?alt=media&amp;token=11c016c8-ffba-4ca4-b00c-e71524488c86" alt=""><figcaption></figcaption></figure>

You can also start a trial directly [from this link.](https://app.zipchat.ai/users/sign_up)

The next step is filling the form with your email address.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F7LghZWbUoR7zOFH8izni%2FScreenshot%202024-11-23%20at%2013.33.13.png?alt=media&amp;token=78598ecc-1304-4deb-8314-0c281543567b" alt=""><figcaption></figcaption></figure>

You will receive a code via email.

Enter the code.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FpvvfsbXWEOW7CoyLdG0C%2FScreenshot%202024-11-23%20at%2013.34.09.png?alt=media&amp;token=bd7435fb-f2a7-4733-b045-084a8863afbb" alt=""><figcaption></figcaption></figure>

Fill the form asking basic questions about you and your store.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FwKngadxHpxTLqTkgxfwy%2FScreenshot%202024-11-23%20at%2013.35.31.png?alt=media&amp;token=d4ece30c-75d5-49b8-a007-6525492b0540" alt=""><figcaption></figcaption></figure>

Select the CMS you use. If you choose Shopify, you will be redirected to the Shopify installation process that [you can find here.](/installation-and-setup/trial-installation/for-shopify-users)

Otherwise, just choose your CMS and enter the URL of your store. Zipchat will start to crawl your site to build the Knowledge Base.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FmKh8RTWBd9Lz1jVDQ5f2%2FScreenshot%202024-11-23%20at%2013.35.59.png?alt=media&amp;token=accd601b-d38b-44a2-9d47-372dc76cd5e6" alt=""><figcaption></figcaption></figure>

During the next step, you need to select the plan you want to try.

Generally speaking, most people start with the Growth Plan because it unlocks all the features, included the email forward (talking about it here).

Need help choosing the right plan for you?&#x20;

* Ask in the bottom right corner chat, our team will help you choose.
* Or, [schedule a demo with our team here](https://zipchat.ai/simulation).

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FM0n1GEqpWIZ93N6rIxHR%2FScreenshot%202024-11-23%20at%2013.36.37.png?alt=media&amp;token=6b2b96fd-c919-4f23-8193-97c99a1c9354" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
IMPORTANT:&#x20;

* *Cancel/downgrade/upgrade anytime, don't worry.*
* *You have 7-Day trial + 30 Days Money Guarantee, so no risks on your side, enjoy.*
  {% endhint %}

Once the trial is started, you will be redirected to your [Dashboard](/installation-and-setup/dashboard).

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2Fty7xHHXL9e7kZQ45oL0a%2FScreenshot%202024-11-23%20at%2017.12.23.png?alt=media&amp;token=d87d25ec-c2c3-49f5-a3c6-de176f09e401" alt=""><figcaption></figcaption></figure>

From there, you can head to the  [AI Training](/installation-and-setup/ai-training) section.


# Onboarding

There are different ways to assure yourself the best 0 to 1 possible, depending on your preferences.

* Read all this documentation.
* Watch this onboarding video you can find here (COMING SOON).
* [Schedule a call with our team](https://cal.com/alessandrovalenti/zipchat-app-onboarding?overlayCalendar=true) and have them help you set Zipchat the right way.


# Dashboard

The Zipchat AI Dashboard is your command center for tracking how well your chatbot is performing and how it’s contributing to your business. It’s designed to give you quick, actionable insights into key metrics so you can optimize and grow. Here’s what you’ll find:

***

### Key Metrics at a Glance

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FtShBGnObcFBFTCNfX27G%2FScreenshot%202024-11-23%20at%2017.26.37.png?alt=media&amp;token=78348bef-1752-4cc4-9a38-8e26ec70bf14" alt=""><figcaption></figcaption></figure>

1. **Sales including a conversation**\
   See exactly how much revenue your chatbot has helped generate. This metric shows the direct impact of Zipchat on your bottom line.
2. **Total Orders**\
   Track how many orders came from customers who interacted with your chatbot. It’s a clear indicator of how Zipchat drives sales.
3. **Chat-to-Sale Conversion Rate**\
   This percentage shows how many chats turn into purchases. A higher rate means your chatbot is doing its job: converting conversations into sales.
4. **Average Order Value (AOV)**\
   Discover the average spend of customers who chat with Zipchat. A high AOV? That means your chatbot is not just selling—it’s upselling and cross-selling too.
5. **Chats Started**\
   This metric counts how many times visitors engage with Zipchat. It tells you how often customers find the chatbot useful or appealing.
6. **Total Replies sent by Zipchat**\
   See the total number of messages sent by your chatbot. This helps you gauge its activity level and how much it’s handling for you.

***

### Customer Feedback Metrics

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FZubiTSRKg6joj0B79Ao1%2FScreenshot%202024-11-23%20at%2017.27.09.png?alt=media&amp;token=f8f7c592-8a9f-455e-aea7-cac8698312f9" alt=""><figcaption></figcaption></figure>

7. **Great Replies**\
   The number of replies customers loved. It’s a sign your chatbot is providing helpful and satisfying answers.
8. **Good Replies**\
   Replies that didn’t receive ratings—neutral but successful interactions.
9. **Bad Replies**\
   Tracks responses rated negatively by customers. Use this to spot improvement areas for your chatbot.

***

### Engagement Insights

10. **Customers mostly start chats from these pages**\
    Find out where on your site most chats begin. This highlights key pages that drive engagement, like product pages or checkout.

***

#### Why the Dashboard Matters

The dashboard isn’t just numbers—it’s a tool for action. Use it to:

* **Track performance**: See how much Zipchat is boosting your sales and engagement.
* **Identify opportunities**: Spot the top-performing pages or areas where your chatbot can improve.
* **Optimize customer experience**: Use feedback to refine your chatbot’s responses and increase customer satisfaction.

With real-time data and easy-to-understand insights, the Zipchat dashboard helps you stay in control, make smarter decisions, and maximize your chatbot’s potential. It’s your shortcut to more sales, happier customers, and a stronger business. 🚀


# Conversations

The **Conversations** section in Zipchat AI is where you track, analyze, and improve every interaction your chatbot has with customers. Think of it as your toolkit for delivering better experiences, boosting sales, and making sure your chatbot performs at its best.

***

### What You Can Do in the Conversations Section

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FHDpHmudiZtg8Sxqc4oTj%2FScreenshot%202024-11-23%20at%2017.30.13.png?alt=media&amp;token=f3f1f9eb-38a4-4098-a6ae-076a3179eebc" alt=""><figcaption></figcaption></figure>

1. **Monitor Chats Live**\
   Watch conversations as they happen. See how your chatbot handles customer questions and jump in if needed to guide the chat or provide extra support.
2. **Track Chat-to-Sale Conversions** *(Shopify Only)*\
   Find out exactly which chats led to sales. See how much revenue your chatbot is driving and identify the conversations that seal the deal.
3. **Know Where Chats Start**\
   Every chat is tagged with the page it started from—whether it’s a product page, checkout, or FAQ. This gives you valuable context about the customer’s intent and helps you refine your website or chatbot for better engagement.
4. **Rate and Refine Responses**\
   Customers can rate replies as "good" or "bad." Use this feedback to spot what’s working and what needs improvement. It’s a direct way to understand how well your chatbot is meeting customer needs.
5. **Make Real-Time Corrections**\
   Noticed an answer that’s off? Correct it right away. This feature lets you train the AI on the fly, helping your chatbot learn from mistakes and improve over time. The result? Smarter, more accurate replies that align with your brand’s voice.

***

#### Why It’s Important

The Conversations section isn’t just about tracking chats—it’s about creating better customer experiences and driving results. Here’s how:

* **Improve Customer Satisfaction**: Monitor and tweak chats to ensure visitors feel heard and supported.
* **Boost Sales**: Understand what’s working in sales-focused conversations and replicate it with corrections.
* **Optimize Performance**: Use feedback and corrections to make your chatbot smarter and more reliable every day.

***

#### Make Every Interaction Count

With real-time monitoring, feedback tools, and the ability to fix and refine responses, the Conversations section puts you in control of your chatbot’s performance. It’s your go-to resource for ensuring your AI isn’t just chatting—it’s solving problems, closing sales, and leaving customers happy. 🚀


# Taking Over Chats

In case you feel like you need to take over a chat, both from the Web Chat and WhatsApp campaigns you can easily do it from the Conversation tab.

You select the chat you want to take over and you click on the top right corner button "Take Over".

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FLXoxElh4HkcSdXpyEaKk%2FScreenshot%202025-01-23%20at%2018.01.48.png?alt=media&amp;token=6a0e596f-707b-4e72-b6bb-88e11648a7e8" alt=""><figcaption></figcaption></figure>

It will allow you to send messages to your customers (both on Web and WhatsApp).

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FMgHBHPHHsnTh9PcqBQ04%2FScreenshot%202025-01-23%20at%2018.02.30.png?alt=media&amp;token=a93950b3-443c-4e22-a255-29905763df20" alt=""><figcaption></figcaption></figure>

As soon as you want the AI to take over again, you just click on "Enable AI Replies".

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FAR7y8NYNQTToP4NMdgjM%2FScreenshot%202025-01-23%20at%2018.03.10.png?alt=media&amp;token=658cd5d9-cd1f-4eb7-8031-74fa7080317b" alt=""><figcaption></figcaption></figure>


# Contacts

Zipchat Contacts are leads or customer details collected through conversations initiated on your chat widget. These contacts are categorized into **Emails** and **Phone Numbers**, depending on the data collected during the interaction. Here's a detailed overview:

* **Emails:** Customers who provide their email addresses during chat interactions.
* **Phone Numbers:** Customers who have messaged the Whatsapp number connected to your Zipchat account or you have uploaded (coming soon).

You can access these details directly from the **Contacts** section in the dashboard.


# Emails

The **Emails tab** in the **Contacts** section in Zipchat AI helps you see the collected email addresses from visitors who engage with your chatbot. These leads can fuel your marketing campaigns, giving you a direct line to customers who’ve already shown interest in your products or services.&#x20;

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FlZtn4esqLY3QuCKbky2o%2FScreenshot%202025-01-18%20at%2015.54.41.png?alt=media&amp;token=dca4001c-be51-4e7e-96fb-c15e6e4092d1" alt=""><figcaption></figcaption></figure>

### Key Features

1. **Effortless Email Collection**\
   Prompt visitors to share their email addresses during chats. Build a growing list of leads from people who are already engaged with your brand.
2. **Export Leads Easily**\
   Download all collected emails into a CSV file, ready to import into your CRM, email marketing platform, or other tools.
3. **Zapier Integration**\
   Seamlessly connect Zipchat to over 2,000 apps via Zapier. For instance, automatically send leads to tools like Klaviyo or your CRM, so they’re instantly ready for follow-ups and campaigns.
4. **On/Off Toggle for Lead Collection**\
   Choose whether to collect emails or focus solely on conversation. Turn the feature on when you want to grow your email list or off for a more casual interaction.
5. **Leads Overview**\
   See all the email addresses collected, along with visitors who skipped entering their emails. Use this to refine your approach and improve your lead collection strategy.
6. **Track Abandoned Chats**\
   Get insights into visitors who didn’t finish the chat. Use this information to tweak how you request emails and reduce drop-offs.

To set it up correctly, go to the [Bubble Chat: Edit design](/installation-and-setup/chat-settings/channels/bubble-chat-edit-design).

***

### Why It Matters

Collecting emails isn’t just about growing your list—it’s about building meaningful connections with customers. With the Leads section, you can:

* **Boost Engagement**: Keep the conversation going after visitors leave your site.
* **Automate Follow-Ups**: Send leads directly into your sales and marketing tools.
* **Respect Privacy**: Let customers choose whether to share their email or receive marketing communications.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FF8wgRhG0j7ijPBOiQ7mv%2FScreenshot%202024-11-23%20at%2017.37.32.png?alt=media&amp;token=c2caadd2-3506-4c94-bbcd-f91bf2a5e083" alt=""><figcaption></figcaption></figure>

### Build Smarter, More Effective Email Lists

The Leads section in Zipchat AI helps you gather high-quality leads effortlessly, while tools like Zapier ensure they’re instantly actionable. By customizing the process and respecting customer preferences, you can create a seamless experience that turns engaged visitors into loyal customers. 🚀


# Phone Numbers

The **Phone Numbers** tab displays all the leads who have engaged with the WhatsApp number connected to Zipchat. It includes details like the phone number, marketing preferences, the number of conversations, and the creation and last conversation dates.&#x20;

You can use the collected phone numbers to send targeted WhatsApp marketing campaigns, allowing for personalized communication and enhanced engagement with your audience. Additionally, you can download the data as a CSV file for further analysis or use in marketing tools.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FlZtn4esqLY3QuCKbky2o%2FScreenshot%202025-01-18%20at%2015.54.41.png?alt=media&amp;token=dca4001c-be51-4e7e-96fb-c15e6e4092d1" alt=""><figcaption></figcaption></figure>


# Segments

Segments are group of phone numbers you can upload to run WhatsApp Marketing Campaigns.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FcOduINhQ89pM6vvjh0cb%2FScreenshot%202025-01-23%20at%2017.46.48.png?alt=media&amp;token=78855d4a-2cf6-4837-8904-a335d6fd7d13" alt=""><figcaption></figcaption></figure>

For example:

* All your customers
* All your cart abandon
* Customer who bought a specific product
* People who attended an online/offline event
* People who are considered VIP
* Any kind of group you wish

You will be able to use these segments for AI WhatsApp Marketing campaigns from [WhatsApp Marketing](/installation-and-setup/campaigns/whatsapp-marketing).


# Campaigns

The **Campaigns** tab allows you to manage and launch two types of campaigns to engage with your audience effectively:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F3qcwhEt7NK0eeZBRQGLM%2FScreenshot%202025-01-18%20at%2016.00.34.png?alt=media&amp;token=48ab002b-43a2-48ba-be03-e09c0ac6e8e0" alt="WhatsApp marketing and proactive chat campaigns inside Zipchat AI"><figcaption></figcaption></figure>

**1. In-Site Proactive Chat**

This feature enables you to send proactive messages to website visitors based on specific rules, such as time spent on a page or specific user actions.

* You can prioritize campaigns by assigning them a ranking (e.g., Pricing Chat has a higher priority than Default).
* Options include previewing, editing, or deleting campaigns.
* Proactive chat helps you capture leads and guide users towards conversion by initiating timely and relevant interactions.

**2. WhatsApp Marketing**

The WhatsApp Marketing section enables you to send personalized messages directly to your collected phone number leads.

* Campaigns can be categorized as **One-off** (single occurrence) or Ongoing (coming soon).
* You can view the status of each campaign, such as:
  * **Ready to send:** Campaign is set up and awaiting dispatch.
  * **Sent:** Campaign has already been delivered.

Both campaign types can be created and managed from this tab to ensure seamless customer communication and improved engagement. Use the "Create Campaign" button to set up new proactive chats or WhatsApp marketing messages.


# Proactive Chat

Proactive Chat in Zipchat AI is like having a savvy assistant on your website, always ready to strike up the right conversation at the right moment. With custom pop-up messages tailored to specific pages or products, it’s a powerful tool to grab attention and guide visitors toward action.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FLykZwRcSUN36bwTPr8J5%2FScreenshot%202024-11-23%20at%2017.40.12.png?alt=media&amp;token=63a1918a-d05e-471d-9d5b-dc28d41d5477" alt=""><figcaption></figcaption></figure>

***

### What Makes Proactive Chat Special

1. **Tailored Messaging**\
   Create custom messages for different parts of your website. For example:
   * A friendly “Welcome!” on your homepage.
   * Specific prompts on product pages, like *"Have questions about {{product\_title}}? Let us help!"*
   * Attention-grabbing offers like *"Use COUPON10 for 10% off your first purchase!"*
2. **Priority Settings**\
   Decide which messages take priority. For instance, show a product-specific prompt over a generic message to make the experience more relevant for your visitors.
3. **Dynamic Engagement**\
   When visitors click on the pop-up, it opens the chat window with a pre-set follow-up message. This could offer more details about a product, share a discount code, or highlight a glowing customer review.

***

### Examples of Proactive Chat in Action

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F3csuIcpYjB4w4dZtGrBP%2FScreenshot%202024-11-23%20at%2017.46.23.png?alt=media&amp;token=49edabba-acdc-420a-b0e4-207ef192df15" alt=""><figcaption></figcaption></figure>

* **On a Product Page**:\
  *"Need help deciding on {{product\_title}}? Ask away!"*
* **On a Landing Page**:\
  *"Hi! I'm here to answer any questions about our new collection."*
* **For Promotions**:\
  *"Grab your 15% OFF with code WELCOME15!"*
* **For Special Offers**:\
  *"Looking for deals? Click here to save!"*

***

### Why Proactive Chat Works

* **Drives Conversions**: Engaging visitors at key moments increases the chance they’ll take action, like making a purchase or asking for more info.
* **Personalized Experience**: Tailored messages make visitors feel like the site understands their needs.
* **Easy Setup**: No advanced skills required—just a few clicks, and your chatbot becomes a proactive sales assistant.

The Advanced Setup feature in Zipchat AI lets you fine-tune your Proactive Chat messages to engage visitors exactly where, when, and how you want. With this powerful customization, you can deliver relevant, well-timed interactions that grab attention and drive conversions.

***

### How It Works

**Target Your Audience**

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FSu4HNJVHNHtxIO83T4Ae%2FScreenshot%202024-11-23%20at%2017.45.03.png?alt=media&amp;token=9f156227-c31c-42a9-902a-9ac5b69eb389" alt=""><figcaption></figcaption></figure>

Decide exactly where your Proactive Chat messages appear:

* **All Pages**: Make the message visible across your entire website.
* **Specific Pages**: Target particular URLs, like a landing page or checkout.
* **All Product Pages**: Reach visitors exploring your catalog.
* **Specific Product Pages**: Highlight deals or assistance for individual items.

**NOTE:** You can exclude Pages: Keep messages off non-relevant areas like the contact page or FAQ.

***

### **Time Your Message**

Engage visitors at the perfect moment with two flexible triggers:

1. **Time-Based Trigger**\
   Set a timer to display the message after visitors have been on the page for a specific duration.\
   Example: *Show the message 5 seconds after they land.*
2. **Scroll-Based Trigger**\
   Trigger the message based on how far a visitor has scrolled down the page.\
   Example: *Display the message when they’ve scrolled 50% of the page.*

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FqROQCAzZMhUg8mvTWSVD%2FScreenshot%202024-11-23%20at%2017.47.08.png?alt=media&amp;token=1fcb72fc-1119-4b66-9683-feea72f691bf" alt=""><figcaption></figcaption></figure>

***

### **Craft the Perfect Message**

Zipchat offers two types of messages to engage visitors seamlessly:

1. **Pop-Up Message**\
   A small, attention-grabbing message appears just above the chat bubble.\
   Example: *"Hi, is there anything I can help you with?"*
2. **Follow-Up Conversation Message**\
   When visitors click the popup, this message appears in the chat.\
   Example: *"Hello! Let me know how I can help. You can ask me anything you want."*

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FcdIvu6fGJKlgE1JOODPb%2FScreenshot%202024-11-23%20at%2017.47.54.png?alt=media&amp;token=653e59eb-d4cb-4d07-b36f-0751a27af5f1" alt=""><figcaption></figcaption></figure>

***

### **Preview and Activate**

* **Preview Your Message**: See how the popup and follow-up look before launching to ensure everything aligns with your goals and brand.
* **Activate the Message**: Once you're satisfied, turn it on. The message will appear based on the conditions you’ve set.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FYMGB17gbal89oWILozSX%2FScreenshot%202024-11-23%20at%2017.48.22.png?alt=media&amp;token=aba7b407-f404-4387-8404-cfa6b5236f1e" alt=""><figcaption></figcaption></figure>

***

### Example Setup

* **Name (Visible to You)**: *“Product Page Promo”*
* **Target Audience**: Specific product pages featuring top-selling items.
* **Trigger**: After 10 seconds or 50% scroll on the page.
* **Pop-Up Message**: *“Need help deciding on {{product\_title}}? Click here to ask!”*
* **Conversation Message**: *“Hi! I’m here to help you with {{product\_title}}. Feel free to ask any questions or let me know how I can assist!”*

***

### Make Proactive Chat Your Secret Weapon

Zipchat AI’s Proactive Chat helps you turn passive visitors into engaged customers by starting the right conversations. Whether it’s answering product questions, promoting offers, or simply saying “Hi,” this feature makes your chatbot smarter, more engaging, and better at boosting your sales.&#x20;


# WhatsApp Marketing

The **WhatsApp Campaign** feature in Zipchat allows you to engage with your contacts directly via WhatsApp for retargeting, upselling, and collecting reviews & feedbacks. Follow these steps to create and manage an AI WhatsApp campaign:

(NOTE: The first video is a wrap-up. Below you will find the full guide step-by-step, it's worth reading at least once.)

{% embed url="<https://www.loom.com/share/2d338da4c0e74a329f5448c4e1216372?sid=3cff13f8-6742-44a8-9acb-1dbd92977630>" %}

***

## Step 1: Phone Number

{% embed url="<https://www.loom.com/share/48dd24f398d34360ac060d9ca4717b83?sid=a15d05be-0986-43f2-82aa-80cdd95bfc18>" %}

* You need a phone number that isn’t used currently in Whatsapp, WhatsApp Business or another app.
  * If your phone number is already used, you need to delete your WhatsApp account or buy a phone number.
* You can buy a US or UK phone number from [YourBusinessNumber](https://yourbusinessnumber.com/?via=a47691) or another online provider/telecom.

***

## Step 2: Meta Account Setup & Connect phone number

{% embed url="<https://www.loom.com/share/156a18056de64454a3d635c33d7ad7a1?sid=15ef1e25-0b14-4f1d-9aaa-30fea75bd7f0>" %}

***

## Step 3: Test Whatsapp

{% embed url="<https://www.loom.com/share/38f2d9bbdec649f4b495599a2e612cd1?sid=c347a28a-e763-4edf-b85f-0bffdf2c9151>" %}

**URL FOR TEST:** <https://wa.me/\\[YOURNUMBER>]

***

## Step 4: Connect a payment method to Whatsapp

{% embed url="<https://www.loom.com/share/be0004cfd6e24a4ababf1472cbc6f593?sid=6e18d3f6-4223-44ad-be5d-d2751ca6e8c8>" %}

Current whatsapp pricing: <https://business.whatsapp.com/products/platform-pricing>

***

## Step 5: What you can do with WhatsApp Marketing

Add a new high performing marketing channel, on auto-pilot:

👉 **Email:** 15-25% Open Rate, avg. $20+ return per $1 spent 👉 **SMS:** 80-90% Open Rate, avg. $10+ return per $1 spent 😍 **WhatsApp Marketing:** 90%+ Open Rate, avg. $25+ return per $1 spent

😈 AI **WhatsApp Marketing:** 95%+ Open Rate, avg. $40+ return per $1 spent

### How does AI WhatsApp change the game forever? Welcome to conversational marketing on steroids.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FEhnXljXMvt2MXfiYfPkj%2FScreenshot%202025-01-21%20at%2009.38.02.png?alt=media&amp;token=c4869b9d-0fa1-43e0-9c54-efedff8abfeb" alt=""><figcaption></figcaption></figure>

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FowBwWDHEupKIfDTJpf5Z%2FScreenshot%202025-01-23%20at%2017.43.53.png?alt=media&amp;token=28cf2329-a30c-4cc9-8753-86a05a503c4f" alt=""><figcaption></figcaption></figure>

Basically AI WhatsApp Marketing allows you to send broadcast messages that feel natural and 1to1 human written.

This level of “cozyness” stimulate high open rates and incredible reply rates, something that doesn’t happen with traditional WhatsApp, Email and SMS campaigns.

By replying, users start a conversation with you.

This conversation is entirely manage by the AI, following your campaign prompt (you have a 10,000 characters prompt for each campaign you send out). Possibilities are endless and limited only by your marketing creativity.

***

## Step 6: Define an Audience

In this step you have to think about what segment of users to target.

The right way to think here, is to understand what’s the Goal of this first campaign.

* Generate sales?
* Get reviews?
* Whatever a conversation on WhatsApp can lead to for you…

Think about what audience would resonate most with your campaign goal. If your objective is **generating sales**, focus on segments like:

* **Past Buyers:** Customers who bought from you before but haven’t returned recently.
* **Abandoned Cart Users:** People who added T-Shirts to their cart but didn’t check out.
* **Engaged Customers:** Users who frequently interact with your website or WhatsApp messages.

If your goal is to **gather reviews**, consider targeting:

* **Recent Purchasers:** Customers who received their orders and may have positive feedback.
* **Loyal Customers:** Those who’ve bought multiple times and are likely advocates for your brand.

***(You can upload your segment lists from*** [Segments](/installation-and-setup/contacts/segments)***.)***

For example. Let’s say you are a cosmetics Brand. We are in May, and you have 1,000 people who bought the anti-cellulite cream in April. As a general assumption, you can consider that these 1,000 people suffer from cellulite problem and that during summer they will want to fight it as much as they can.

You can then prepare a “summer bundle”, a box with 3-anti cellulite creams + some other complimentary product.

Instead of selling each cream at $59, you can bundle it at $119.

**🎯 Campaign goal:** convert previous buyers into repeat buyers promoting a $119 bundle.

👥  **Audience:** 1,000 people who bought an anti-cellulite cream in April.

***

## Step 7: Think about your Prompt

Now that you have though about your audience, selected the segment (list of numbers) and thought about the promotion you want to drive traffic to, you need to setup the campaign.

**Note: during this Beta phase just share the list with the team. Later, you will be able to upload it directly through your account.**

Go to the “Campaigns” section and click on create campaigns.

### **1. Accessing the Campaign Creation Menu**

1. Navigate to the **Campaigns** tab in the Zipchat dashboard.
2. Click the **Create Campaign** button.
3. In the pop-up window, select **WhatsApp Campaign** and click **Create**.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FwLycg5MVjZeljctxp4gh%2FScreenshot%202025-01-18%20at%2016.32.44.png?alt=media&amp;token=694eebd5-0f9d-49ac-b6ff-9c19ba4c8f40" alt=""><figcaption></figcaption></figure>

Choose a name for the campaign.

Choose a segment for the campaign ( [Segments](/installation-and-setup/contacts/segments)).

Choose an “opening message”. Since as per the example at Step 6 we are selling an anti-cellulite bundle + bonus to people who bought an anti-cellulite cream during the previous month, we can create a first message like:

> Hi 👋, it’s Marina from \[BRAND NAME]. I just wanted to checking in and see how the anti-cellulite cream you bought from us last month is doing on you? Are you happy with it?
>
> By the way, planning any beach vacation soon? I’m going to Mallorca mid-July.

The above message doesn’t feel spammy, it builds a trust and a relationship and it’s a good hook to start talking.

You can write an “unsubscribe instruction”, for example:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2Fzsl9Mjxp2GVGgB0VIVzo%2FScreenshot%202025-01-21%20at%2010.03.49.png?alt=media&amp;token=586f7040-4ed9-4b94-9172-acc6ed140a82" alt=""><figcaption></figcaption></figure>

At this point you need to write the campaign prompt. With experience and time you will do this in a couple minutes, or you will have your ready to go templates.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FYWaiSUHr3DdRCY1vIHYK%2FScreenshot%202025-01-21%20at%2010.04.02.png?alt=media&amp;token=b9644670-2053-4a33-9ff1-7bcdc599c8ba" alt=""><figcaption></figcaption></figure>

Personally, I’d prompt the campaign that way:

> You are Marina from \[BRAND NAME]. You're gentle and use cool emojis professionally and empathetically to create an engaging and friendly experience for the customer you are talking to.
>
> You are a beauty consultant and you really care about your client being beautiful and feeling great.
>
> Your goal is to sell the anti-cellulite bundle which include:
>
> * 3 anti-cellulite creams, valued at $59 each ($177 total value)
> * 1 bonus cream, valued at $39
> * Total bundle value of: $216
>
> For a staggering: $119 promotion, valid only for 24 hours. The promotion is available at this link: [www.brand.com/bundle](http://www.brand.com/bundle)
>
> Starting Message we send first (just to give you context): ”Hi 👋, it’s Marina from \[BRAND NAME]. I just wanted to checking in and see how the anti-cellulite cream you bought from us last month is doing on you? Are you happy with it?
>
> By the way, planning any beach vacation soon? I’m going to Mallorca mid-July.”
>
> Scenario 1: They haven’t used it yet, or just started Your goal here is to understand why with emphatic questions. Then, you can keep following the conversation understanding their goals with the cream and if they are traveling somewhere. As soon as the conversation is “hot” to promote the bundle, explain you have an offer going on, explain and link the bundle, explaining that it has been created to provide a summer long stock of product so the results can be visible and consistent.
>
> Scenario 2: They are using it, they like it That’s the best scenario. You can ask about whether they are using it for a general goal or if they have a specific vacation they want to “look” perfect for. As soon as the conversation is “hot” to promote the bundle, explain you have an offer going on, explain and link the bundle, explaining that it has been created to provide a summer long stock of product so the results can be visible and consistent.
>
> Scenario 3: They are using it, they don’t like it Try to understand why they don’t like it by asking questions, waiting for a reply and then asking more questions. You might find out the reason rely in results not being immediate. Explain, empathically, that results take some time and recommend to use the product with consistency. Ask about their goal and whether they need to get to a certain results by a certain date, maybe for a vacation. As soon as the conversation is “hot” to promote the bundle, explain you have an offer going on, explain and link the bundle, explaining that it has been created to provide a summer long stock of product so the results can be visible and consistent.
>
> \[Scenario X: You can add as many ideas as you can come up with]
>
> Key Notes:
>
> * Always ask relevant and emphatic questions, you must make the prospect feeling like she is talking to a real human, not an AI.
> * Keep the tone warm and professional with a touch of dopamine-boosting emojis.
> * Tailor responses to align with the prospect's expressed interest and goal, while gently pushing toward the bundle.
> * If the prospect is not interested, thank them for their time and say you're there if they need help with anything related with beauty, that as a beauty consultant it will be your pleasure to help.
> * If customer responds with STOP, tell them you'll remove them from the list.

For reference: the above prompt is only “3,230 characters”. The limit is 10,000. You can add much more context and play with it.

***

## Step 8: Draft the Campaign

As soon are you are ready, just click on “Save Draft” in the bottom right corner.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FtecLpP7yGY6OaFgdcqcl%2FScreenshot%202025-01-21%20at%2010.19.32.png?alt=media&amp;token=9715a5d3-847b-4160-b573-778ade95281a" alt=""><figcaption></figcaption></figure>

***

## Step 9: Test & Send the Campaign

Once you save the draft, Meta will need to approve the campaign. You will see a "Pending Approval" at the top of the campaign.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F52yRpLoWvDd92rimB5D5%2FScreenshot%202025-01-18%20at%2016.36.25.png?alt=media&amp;token=124c68e9-4931-42a0-93dc-b88984d3748b" alt=""><figcaption></figcaption></figure>

* From this page you an:
  * **Delete:** Delete the campaign.
  * **Edit Campaign:** Edit the settings of the campaign.
  * **Test:** Test the conversation and understand whether you should update/change the prompt.

Meanwhile, by clicking on the top-right button, “test”, you can open the internal simulator and play with the chat to see whether your prompt is well structured.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F6Pjc9DYjBPgSdL9O71yO%2FScreenshot%202025-01-21%20at%2010.22.29.png?alt=media&amp;token=dede22da-ecd3-4ccc-95aa-8d55179caf7f" alt=""><figcaption></figcaption></figure>

Once the campaign is approved by Meta (usually a few minutes, sometimes up to 60’), you will see the “ready to send tag” next to the title.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FjM25OjWeut4kd0lJwuoA%2FScreenshot%202025-01-21%20at%2010.23.17.png?alt=media&amp;token=0fb94c4c-c61f-45b2-925d-f15ee085d1c5" alt=""><figcaption></figcaption></figure>

Just click the “send campaign” on the top right and the campaign will be sent.

***

## Step 10: Meta Costs

All interactions initiated through the WhatsApp campaign, including customer replies, will be displayed in the **Conversations** tab. This allows you to monitor and manage ongoing chats effectively, taking them over if necessary, ensuring a seamless customer engagement process.

By leveraging the AI WhatsApp Campaign feature, you can maintain personalized communication and build stronger relationships with your audience.


# AI Training

The **AI Training** feature in Zipchat helps you refine your chatbot's performance, ensuring it gets better at understanding and responding to customer queries. By tailoring the AI to align with your brand’s tone, products, and industry knowledge, you can create a chatbot that feels like a natural extension of your team.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FsyBJbkkzeceud0OnZT2m%2FScreenshot%202024-11-23%20at%2017.50.47.png?alt=media&amp;token=2ec1037e-5178-468e-a1b9-a6892f511755" alt=""><figcaption></figcaption></figure>

### Key Features

1. **Train with Additional Context**\
   Provide resources like:
   * **PDFs**: Upload product guides, FAQs, or manuals.
   * **Links**: Add website pages or external articles.
   * **👉** [**More details here**](/installation-and-setup/ai-training/knowledge-base)&#x20;
2. **Correct Inaccurate Responses**\
   If the AI gives an off-the-mark reply, you can step in and correct it. These corrections help the chatbot learn and improve over time, making future interactions more accurate and helpful.
3. **Feedback Loop**\
   Every interaction contributes to a feedback system. Monitor customer ratings on AI responses ("good" or "bad") and use this input to fine-tune its performance.
4. **Brand Alignment**\
   Customize responses to match your brand’s tone and language. Whether your style is casual and friendly or professional and precise, you can shape the chatbot to speak just like your team.

***

### Why AI Training Matters

* **Better Customer Experience**: Tailored responses build trust and show customers you understand their needs.
* **Increased Accuracy**: As the AI learns from corrections and added context, it can handle more complex questions confidently.
* **Consistency**: Ensure every customer interaction reflects your brand’s values and messaging.

***

### How It Works

1. **Upload Resources**\
   Add key documents or links to train the AI on specific topics.
2. **Review Chat History**\
   Look at past interactions to identify responses that need improvement.
3. **Make Corrections**\
   Adjust the AI’s reply to align with your standards. For example, correct product details or refine explanations.
4. **Monitor Progress**\
   Track how well the AI performs over time using feedback and chat success metrics.


# Knowledge Base

The **Knowledge Base** is where Zipchat AI gets the information it uses to answer customer questions. It starts by automatically crawling your website to gather key details like product descriptions, FAQs, and other content. You’ll see all your website URLs already listed in this section. But you can do so much more to make the AI smarter and more effective.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FID8Dwdh97oH16rrpzfaE%2FScreenshot%202024-11-23%20at%2017.56.31.png?alt=media&amp;token=fb766cd7-0082-4220-a5f8-aea280e8d545" alt=""><figcaption></figcaption></figure>

***

### How to Expand and Update Your Knowledge Base

1. **Automatic Crawling**
   * Zipchat scans all your site pages and adds them to the Knowledge Base.
   * It pulls details like product info and policies directly from your site, ensuring the chatbot stays up to date.
2. **Add Extra Information**\
   Boost the AI’s ability to handle complex questions by manually adding these formats:
   * **Single Page**: Paste a URL for an updated page, subdomain, or external site. The AI will crawl it immediately.
   * **Multiple Pages**: Provide the main URL, and Zipchat will scan all linked pages. Perfect for capturing related content in one go.
   * **PDF Uploads**: Upload guides, charts, or manuals to give the AI detailed, searchable information. Example: A sizing guide or warranty details.
   * **Blank Text**: Add specific content directly into the Knowledge Base. Only the text is indexed, so make it concise and relevant.
   * **CSV with Links**: Can’t crawl certain pages? Upload a list of URLs in CSV format to include them manually.
   * **Sitemap (XML)**: Upload your XML sitemap for efficient and comprehensive crawling of your entire site structure.

***

### Why It Matters

* **Enhanced Accuracy**: By adding and updating content, the chatbot provides precise answers to even the most detailed customer inquiries.
* **Better Engagement**: A well-rounded Knowledge Base helps your chatbot engage visitors with confidence, whether it’s recommending a product or answering a tricky question.
* **Always Up-to-Date**: Regular updates ensure the AI reflects your latest offerings, promotions, or policy changes.

***

### How to Make the Most of It

1. **Add Specific Pages**\
   Include newly updated product pages, promotional pages, or subdomains not automatically captured.
2. **Upload Supporting Documents**\
   PDFs like product manuals, comparison charts, or step-by-step guides help the AI handle specific or technical questions.
3. **Use Blank Text for FAQs**\
   Quickly add answers to new FAQs or specific instructions for seasonal campaigns.
4. **Regularly Update**\
   Keep your knowledge base fresh by revisiting it after website changes or new launches.

***

### Deliver Smarter, Faster Support

A robust Knowledge Base transforms Zipchat AI into a highly effective assistant that not only answers questions but also resolves issues with precision. By combining automatic website crawling with custom additions like PDFs and URLs, you can ensure your chatbot is equipped to provide an exceptional customer experience—every time. 🚀


# Chat Corrections

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FyjuZbBdG8QvC5dt7hNzq%2FScreenshot%202024-11-23%20at%2017.58.03.png?alt=media&amp;token=fda05e6f-275a-4e52-aa02-ae3de02846be" alt=""><figcaption></figcaption></figure>

Corrections give you the opportunity to provide additional training to your AI agent regarding specific questions that are not answered in your knowledge base.

***

### How corrections work

Corrections work by building additional Q\&A entries on top of what you already have on your website knowledge.

Whenever you create a correction, a new entry is added to the knowledge base in a Question and Answer format, for example

> *Q: Do you ship to Australia*\
> *A: Yes, we ship to Australia via DHL in 3-5 days*

The next time someone asks something about shipping to Australia, Zipchat will see the Q\&A you just created.

### When to use corrections

Corrections should be used when you're adding missing information to the knowledge base. They work great to improve a response that relies on the knowledge of the AI agent ( instead of its behaviour or actions )

### When corrections don't work

There are two major limitations of corrections

#### Trying to modify the AI agent's behaviour

Corrections are only loaded when Zipchat does an "information search", but don't work for other AI tools like "Order tracking", "Escalate conversation", etc..

If you're trying to teach Zipchat how they should behave when someone asks for their order information ( for example ), that won't work - Zipchat won't even look for information.

Instead, you should modify the additional instructions of the AI agent from AI training / Prompt & Tools

As a rule of thumb:

* Use corrections when you want to change what Zipchat knows
* Use prompting/instructions when you want to change what Zipchat does

#### Conflicting information

You may create a correction, but if there's conflicting information on your website ( or in another correction ), the AI agent might be confused&#x20;

If you're making corrections but not getting an improved response, it's a good idea to check

* Your existing corrections -> are there other corrections that say the opposite?
* Check if some of your web pages have outdated info

***

### Why Chat Corrections Matter

1. **Smarter Over Time**\
   Every correction you make teaches the AI something new. Over time, these adjustments create a feedback loop, making your chatbot more accurate and aligned with your business goals.
2. **Tailored to Your Business**\
   No two businesses are the same, and generic responses don’t always work. Chat Corrections let you tweak answers to match your tone, provide detailed information, or fix inaccuracies—making the chatbot feel like a true extension of your team.
3. **Better Customer Experience**\
   By refining responses, your customers get the most accurate and helpful information. This leads to happier customers, more conversions, and repeat business.
4. **Quick and Easy Adjustments**\
   No waiting for tech updates or support help. You can make changes in real-time, saving time and staying agile as your business evolves.

***

### How to Use Chat Corrections

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FvGu6gkpLXIIYSDCzMDl8%2FScreenshot%202024-11-23%20at%2018.00.44.png?alt=media&amp;token=4982fd6d-d36d-49df-b666-3343805efb31" alt=""><figcaption></figcaption></figure>

1. **Monitor Chats Regularly**\
   Review conversations to spot any inaccurate or off-brand responses. You can do it from [Conversations](/installation-and-setup/conversations).
2. **Provide Instant Feedback**\
   When you find a mistake or want to improve a reply, correct it directly. Update the content or language to better fit your needs.
3. **Set Expiry Dates** *(Optional)*\
   For time-sensitive corrections, like promotions or out-of-stock updates, you can set an expiry date. The AI will "forget" the correction once it’s no longer relevant.
4. **Manage All Corrections**\
   From the corrections section, view all your adjustments. Edit, delete, or set/remove expiry dates easily to keep everything up to date.

***

### Take Charge of Your Chatbot

With Chat Corrections, you can make your Zipchat AI smarter, faster, and better every day. Fine-tune its responses to match your brand, enhance customer interactions, and deliver a truly superior experience—all with a tool that’s simple to use and incredibly powerful. 🚀


# Prompt & tools

Page location: AI Training / Prompt & Tools

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2Fi82rCINbJfetXNM2l0H0%2Fimage.png?alt=media&amp;token=fb9ec29b-f2f7-45cf-8cd1-99f99d46c5b5" alt=""><figcaption></figcaption></figure>

Zipchat allows you to fully control how your AI behaves by combining global prompts, additional instructions, and tool-specific prompting.

This layered approach lets you fine-tune tone, goals, escalation behavior, and how actions are performed.

This page explains how each part works and how they interact.

***

### Overview: How Zipchat AI Is Configured

Zipchat AI behavior is defined through four main layers:

1. Core Prompt – global personality, tone, and rules
2. Contact Info – what to do when human support is needed
3. Additional Instructions – sales flows, positioning, and advanced logic
4. Tools & Tool-Specific Instructions – how and when actions are performed

Each layer builds on top of the previous one.

***

### Core Prompt (Base Behavior)

The Core Prompt defines Zipchat’s overall behavior and applies to all Zipchat bots. This is the base behaviour of a good e-commerce agent and and it handles most things out of the box.

***

### Contact Info

The Contact Info field defines what Zipchat should do when a customer wants to talk to a human.

Zipchat uses this information when:

* A visitor explicitly asks for human support
* A conversation is escalated via the Escalation tool

This typically includes:

* A support email address
* Instructions on how to proceed if live help is required

Inside it, you can write down instructions on how to be contacted in free-form text.

***

### Additional Instructions (Behavior & Sales Logic)

Additional Instructions are layered on top of the Core Prompt and are ideal for defining how Zipchat should operate in practice.

Use this section to:

* Set tone of voice ( use of emojies, specific words, etc )
* Define pre-sales questions
* Tell Zipchat how to handle sepcific cases

#### Example use cases

* "Before suggestinng a product, ask X, Y & Z"
* "Be cringey and sneak as many dad jokes as possible when replying"
* "Whenever a customer asks about X, do Y"

> Think of Additional Instructions as your business playbook

***

### Tools & Tool-Specific Prompting

Zipchat can perform actions using Tools (for example: Knowledge Search, Escalation, Order Lookup, etc.).

Each tool can be:

* Enabled or disabled
* Activated per channel
* Configured with its own prompting

#### Tool Core Prompt

Every tool has a Tool Core Prompt that defines:

* When the tool should be used
* The basic conditions for triggering it

#### Tool Additional Instructions

Each tool also supports Additional Instructions, allowing you to customize:

* How the AI explains the action to the customer
* Extra guardrails or conditions
* Tool-specific behavior without affecting other tools

<br>

#### Why this matters

Tool instructions allow fine-grained control.

Examples:

* Ask clarifying questions before escalating to human support
* Escalate only if the user is asking about this topic
* Create discounts if the customer says the product is too expensive

***

### List of available tools

* Knowledge Search
* [Escalate conversation ( Forward request ) ](/installation-and-setup/ai-training/prompt-and-tools/forward-request)
* [Order lookup](/installation-and-setup/ai-training/prompt-and-tools/order-tracking)
* Create discounts ( Shopify only )&#x20;
* Skip Conversation

***

### Best Practices

* Keep Core Prompts clear and high-level
* Use Additional Instructions for business logic
* Use Tool Instructions for precise control
* Avoid overly long prompts—clarity beats verbosity
* Test changes using Test Chat after updates


# Order Tracking

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F7rUQpu32Jda1Mi7M8fWO%2FScreenshot%202024-11-23%20at%2018.17.19.png?alt=media&amp;token=94bd4359-3a45-4557-82fd-56b5181f6cca" alt=""><figcaption></figcaption></figure>

The **Order Tracking** feature streamlines customer inquiries by providing real-time updates on order statuses.

* **Shopify Integration**: Instantly retrieves order details using the customer’s email and order number directly from your Shopify store.
* **Seamless Experience**: Customers get accurate updates without leaving the chat, enhancing convenience and satisfaction.
* **Support Automation**: Handles tracking inquiries automatically, saving your support team time while keeping customers informed.

This tool ensures a smooth, hassle-free experience, boosting customer satisfaction and loyalty. 🚀


# Shopify: Write custom shipping notes

### Why you should set up the `additional_shipping_information` metafield

When you use Zipchat, one of its key features is: it **automatically** checks an order’s shipping status in Shopify and communicates to the customer what’s happening.

\
But sometimes an order isn’t shipped yet **and** Shopify there's no status update. In these cases, without any extra information the customer is left in the dark.

\
By adding a custom metafield like `custom.additional_shipping_information`, you can proactively add a human-readable note (for example: “Shipment delayed because of X, expected to ship on Y”), and Zipchat can detect it and show it to the customer instead of showing “no update.”<br>

In short:

* This provides better transparency and customer experience.
* It reduces support tickets (“Where is my order?”) because you’re telling customers the reason and expected timeline.
* It enables Zipchat to function more intelligently — fallback from “no shipping status” into “custom note exists → show that note.”

***

### How to set up the `additional_shipping_information` metafield in Shopify, for use by Zipchat

#### 1. Create the metafield definition

1. In your Shopify Admin go to **Settings → Custom data (or Metafields & Metaobjects)**.&#x20;
2. Select the resource you want this metafield to apply to — in this case: **Orders** (since you want the note attached to an order).
3. Click **Add definition** (to create a new custom metafield) because you’re storing data that isn’t captured by Shopify by default.&#x20;
4. Fill in the fields:
   * **Name**:  `Additional Shipping Information` - *if you pick a different name, make sure you update the key to be correct*
   * **Namespace and key**: Set namespace = `custom`  and key = `additional_shipping_information`. When combined this results in `custom.additional_shipping_information`. **This is important** because your Zipchat integration will look precisely for this key.
   * **Content type**: Type: One >  *Multi-line text field*&#x20;
   * Optionally: add a description like “Enter shipping-delay or shipping-note for Zipchat to display to customer when order hasn’t shipped yet.”
5. Save the definition.

#### 2. Populate the metafield value for a given order

1. Go to your Shopify Admin → Orders → open the specific order that **has not yet shipped** (or you anticipate a delay).
2. Within that order record, scroll down till you find the **Metafields** section (sometimes you might need to expand “Show more” or scroll to bottom).
3. Locate the metafield you just defined: `custom.additional_shipping_information`.
4. Enter the shipping-note value, e.g.:

   > “Shipment delayed because of X; the order is expected to ship on Y.”
5. Save the order.

#### 3. Zipchat reads the metafield and performs its logic

* When Zipchat queries Shopify for the order status, if it detects that `custom.additional_shipping_information` has a value, Zipchat will present that value to the customer (e.g., “Your order is delayed: Shipment delayed because of X; expected on Y”).
* If there is no value in that metafield, Zipchat will fall back to the normal status-update route (or maybe say “no update yet”).<br>

***

### Quick reference table for merchants

| Item                  | Value/Setting                                                                  |
| --------------------- | ------------------------------------------------------------------------------ |
| Definition name       | `additional_shipping_information`.                                             |
| Namespace + key       | `custom.additional_shipping_information`                                       |
| Resource (applies to) | Order                                                                          |
| Content type          | Multi-line text (or single line if simpler)                                    |
| Purpose               | Enter shipping delay note or expected ship date when no shipping update exists |
| Outcome               | Zipchat shows the note to the customer as fallback when no shipped status      |

***

### Connect your ERP or custom apps

Because the metafield is created by you, this allows other apps to also write inside of it. This can be useful if you want to automatically add shipping notes like "expected shipment", etc


# Forward Request

Escalation ensures your customers always receive the right level of support, even when the AI cannot fully resolve a request. When a visitor asks for human assistance or the AI detects a complex issue, the conversation is forwarded to your support team. This prevents frustration, improves customer experience, and allows you to automatically create support tickets in platforms like Zendesk for proper tracking and follow up.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FDJbxmzjrsIixlH0FlldT%2FScreenshot%202024-11-23%20at%2018.22.33.png?alt=media&amp;token=dd1bdde6-67bf-4992-9e51-eb3da6096eb0" alt=""><figcaption></figcaption></figure>

**To configure this feature:**

1. Go to your **Zipchat Dashboard** and navigate to **AI Training**.
2. Open the **Prompt and Tools** sub-tab, scroll down to the **Tools** section, and activate **Escalate Conversations**.
3. Once activated, choose how you want to receive escalation notifications:
   * **In-app only**: You will see escalated conversations inside the **Conversations** tab, marked with a red diamond and red exclamation point.
   * **In-app + Email notifications**: Toggle this option on and specify the email address where escalated conversations should be sent.
4. If you are using Zendesk, enter the same email address connected to your Zendesk account. Escalated chats will then be forwarded to that inbox and appear as regular tickets inside Zendesk.
5. Use the **Additional Instructions** section to define special escalation behavior. For example, you can instruct the AI to escalate conversations when certain topics are mentioned, or to avoid answering specific subjects and instead forward those chats directly to human support.
6. Save your configuration and test the flow to ensure escalations are delivered through your selected notification method.


# Test your Chatbot

The **Test Your Chatbot** feature in Zipchat AI gives you the tools to evaluate and refine your chatbot’s performance in a controlled environment. By testing its responses to a variety of scenarios, you can ensure your chatbot meets customer expectations, aligns with your brand, and delivers top-notch interactions from day one.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FhiBYmwKrPQTAoQ5j03Zd%2FScreenshot%202024-11-23%20at%2018.05.24.png?alt=media&amp;token=fff8daf9-1daa-4ff1-a63a-5f10169eccaa" alt=""><figcaption></figcaption></figure>

### Why Testing Your Chatbot Matters

1. **Fine-Tune Custom Instructions**\
   Test how well your chatbot follows the instructions you’ve set. Does it greet customers the way you want? Does it provide detailed answers or use the right tone? Testing lets you adjust these settings until everything is just right.
2. **Optimize the Knowledge Base**\
   See how effectively the chatbot uses the resources in your Knowledge Base, such as PDFs, links, or text entries. If the AI struggles to retrieve the correct information, it might be time to update or refine your content.
3. **Catch and Fix Errors**\
   Spot inaccuracies, misunderstandings, or gaps in knowledge before the chatbot interacts with real customers. This proactive approach ensures a smoother experience when you go live.
4. **Build Confidence in Your AI**\
   By thoroughly testing your chatbot, you can deploy it with peace of mind, knowing it’s prepared to handle customer queries effectively and enhance your brand’s reputation.

***

### How to Use the Test Your Chatbot Tool

1. **Simulate Customer Queries**\
   Test a wide range of scenarios:
   * Common questions (e.g., “What’s your return policy?”)
   * Complex scenarios (e.g., “How does this product compare to \[another product]?”)
   * Edge cases (e.g., vague or confusing questions)
2. **Review AI Responses**\
   Analyze the chatbot’s replies for:
   * Accuracy: Is the information correct?
   * Relevance: Does the response answer the question?
   * Tone: Does it match your brand’s voice?
3. **Refine and Improve**\
   Based on your observations:
   * Adjust the **Custom Instructions** to improve tone and behavior.
   * Update the **Knowledge Base** with missing or clearer information.
   * Correct replies.
   * Remove irrelevant data that could confuse the AI.
4. **Iterate as Needed**\
   Testing is an ongoing process. Keep refining and testing until the chatbot consistently meets your expectations.

***

### Example Scenarios to Test

* **Customer Welcome**: *“Hi there! How can I help you today?”*
  * Check if the chatbot’s tone feels inviting and helpful.
* **Product Details**: *“Can you tell me more about \[Product Name]?”*
  * Verify if the AI retrieves accurate and detailed information.
* **Policy Inquiries**: *“What’s your return policy?”*
  * Ensure the AI provides a clear and correct explanation.
* **Handling Unknowns**: *“Can you do X?”*
  * Confirm it responds gracefully when it can’t help, such as: *“I’d love to help, but that’s outside my scope. Let me guide you to the right resource.”*

***

### The Benefits of Testing

* **Flawless Interactions**: Spot and resolve issues before they impact your customers.
* **Customer Satisfaction**: A well-tested chatbot delivers accurate, helpful, and professional responses, improving the customer experience.
* **Stronger Brand Presence**: Confidently launch an AI that aligns with your brand’s tone and values.

***

### Launch with Confidence

The **Test Your Chatbot** feature is your safety net, ensuring your chatbot is polished, professional, and ready to impress. With thorough testing, you can deliver a seamless customer experience that drives satisfaction and conversions—right from the start. 🚀


# Chat Settings

The **Chat Settings** section in Zipchat AI lets you tailor every aspect of your chatbot to suit your business. From its appearance to its functionality, you’re in control, ensuring your chatbot delivers the perfect customer experience.&#x20;

From this section you can setup the different:

* Channels
* Configurations
* Integrations


# Channels

In this section you can find the different channels Zipchat AI integrates with.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FcWCSULbV148h38I8JdkZ%2FScreenshot%202025-01-18%20at%2016.16.58.png?alt=media&amp;token=96e0f912-58ef-4430-9cbb-21eef03e7b7b" alt=""><figcaption></figcaption></figure>

**1. Chat Bubble**

**Shopify App Integration**

* **Status:** Displays the current connection status of your Shopify store with Zipchat. If permissions are missing, you’ll see a warning and can reconnect by clicking the **Reconnect** button.
* **Edit look & feel:** Use this option to modify the design of the chat bubble to match your brand.
* **Activation/Deactivation:** You can easily enable or disable the chat bubble using the provided  button.

**Installation**

* **Theme App Embed for Shopify (Recommended):**
  * App embeds are the preferred way to include floating elements like the chat bubble on your Shopify store.
  * To enable:
    1. Click the provided link or navigate to **Shopify > Online Store > Themes > Customize > App Embeds**.
    2. Enable the **Zipchat Bubble**.
    3. Save your theme.
* **JavaScript Code Installation:**&#x20;
  * For manual setup, a JavaScript snippet is provided. Copy and paste it into the `<head>` section of your store’s HTML to install the chat bubble.

***

**2. WhatsApp Integration**

* **Status:** Shows whether the WhatsApp feature is connected and active.
* **Connected Number:** Displays the linked WhatsApp number for customer communication.
* **Connect/Disconnect Option:** Allows you to link and unlink the WhatsApp account if necessary.

***

**3. Link to Chat**

* This feature provides a standalone chat page link that can be shared with customers.
* **Usage:**
  * Use the provided URL to direct customers to an independent chat interface.
  * Great for sharing via email, SMS, or other communication channels.

***

**4. Embedded Chat**

* Provides an iframe code to embed the chat directly into a webpage.
* **Usage:**
  * Embed the chat widget without requiring users to click a chat bubble.
  * Simply paste the iframe code into your HTML to display the chat interface seamlessly.

***

This section gives you full control over how Zipchat integrates with your website and external communication channels, ensuring smooth setup and operation for both you and your customers.


# Instagram Channel Prerequisites

In order to have the Instagram channel working on Zipchat, your brand needs:

* a Facebook page
* a Professional Instagram account - **personal Instagram accounts are not supported**
* Facebook page **connected with** the Professional Instagram account

The following message means your agent is missing one of the prerequisites above:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F7dUFFwwIoYDzosrcFMIW%2FScreenshot%202026-02-25%20at%2015.23.10.png?alt=media&amp;token=94b3123e-c7ef-4251-8cf2-19c04454e478" alt=""><figcaption></figcaption></figure>

### Professional Instagram Account

Your Instagram account must be a professional account (Creator or Business). If your brand is currently using a personal account, no worries - you’ll just need to switch it to a professional profile before enabling the Instagram channel on Zipchat.

See [official Instagram docs](https://help.instagram.com/502981923235522) on how to set up a professional account.

### Connecting your Facebook Page with the Instagram Account

1. Visit <https://business.facebook.com/> on a browser.
2. Ensure you have the proper Business Portfolio selected on the left-hand side menu.
3. Go to "Accounts" -> "Pages" and select the Facebook page of your brand:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FCC4ZKpoCUFc8nzqqKgCw%2Fconnecting-instagram-account.png?alt=media&amp;token=bc925e79-94c7-4418-b770-14b33aff9be6" alt=""><figcaption></figcaption></figure>

4. Click "Connect assets" and pick "Instagram account":

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FyMQlenOvGjgCe80LpeXM%2Fconnecting-instagram-account2.png?alt=media&amp;token=06f870cf-a1bc-4e7d-8709-82a1c80923e4" alt=""><figcaption></figcaption></figure>

5. Login with your Professional Instagram account:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FZom4RJcSTg5tH1LTvbBY%2Fconnecting-instagram-account3.png?alt=media&amp;token=93562354-677a-437a-8c3c-2d55311bc8c8" alt=""><figcaption></figcaption></figure>

6. Allow access to Instagram messages in inbox:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FHvFEBaKu45Ti0Hhi3lYj%2Fconnecting-instagram-account4.png?alt=media&amp;token=997de1c9-c2dc-4e4e-b961-a565c7465249" alt=""><figcaption></figcaption></figure>

7. Click "Done" to finish:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FjuF76sxbtmxyNuPwLpze%2FScreenshot%202026-02-25%20at%2012.36.17.png?alt=media&amp;token=0b51050a-2107-4db4-a72e-8fc7bf145df2" alt=""><figcaption></figcaption></figure>

8. Go back to the "Chat settings" page on Zipchat, click "Confirm setup" and authorize your Facebook page/Instagram account again:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F7dUFFwwIoYDzosrcFMIW%2FScreenshot%202026-02-25%20at%2015.23.10.png?alt=media&amp;token=94b3123e-c7ef-4251-8cf2-19c04454e478" alt=""><figcaption></figcaption></figure>

9. If everything is all right you should see following status after refreshing the page:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FNGfVKdPkBl9PegcgrMzv%2FScreenshot%202026-02-25%20at%2013.32.30.png?alt=media&amp;token=95846bfa-9499-46fa-bdc4-75edf1c5100f" alt=""><figcaption></figcaption></figure>

In case you still see "Action required" after refreshing the page it means there is something missing. Go back and review the steps above.


# WhatsApp Agent: Start Guide

## Why WhatsApp

WhatsApp is a service and marketing channel with incredible potential; it’s the most used messaging app in Europe, LATAM, India, and it’s growing fast in the United States

Main reasons to use WA:

* Open rate of marketing messages: 85%
* Click-through-rate: 15%
* Automatic collection of the customer’s Name, Surname and Phone Number
* 24 hours to keep the conversation going, while if someone texts you on your website, as soon as they close the browser you cannot reach to them
* You are always in your customers pocket, one conversation away
* Most importantly - customers EXPECT to speak with you on WA

## Start Guide: Prerequisites

### 1️⃣ Get a phone number

To connect Zipchat & WhatsApp, you need a phone number; you can use an existing phone numbe or buy a new one.

**USING AN EXISTING PHONE NUMBER**

If you decide to use an existing phone number, you need to cancel your existing WhatsApp or WhatsApp Business Account first. If you don’t do it, you won’t be able to complete the integration. [You can cancel your account following this guide.](https://faq.whatsapp.com/2138577903196467/?cms_platform=android)

⚠️ If you cancel your account, you will loose all the existing conversations with your customers. Conversations cannot be transferred from one account to another.

While a lot of customers have no problems in cancelling their existing account, if you don’t want to do so or don’t want to loose all the conversations, you can always buy a new phone number.

**BUYING A NEW PHONE NUMBER**

You can buy any phone number you want, from a virtual or phisical provider. You can also buy a number from [Yourbusinessnumber.com](http://Yourbusinessnumber.com) , a good provider (not associated with Zipchat) that allows you to buy a number in only a couple of minutes.

&#x20;👉🏻 Pro tip: many virtual providers only offer phone numbers with UK or US country code, and that’s actually not a problem. Once your number is connected to Zipchat, you can request Meta to approve your display name and your customers won’t see your phone number but your company name, even if they don’t have you registered as a contact.

### 2️⃣ Facebook Business Verification

To fully use the WhatsApp API via ZipChat, your Facebook Business must be verified. Without verification, access is limited to a 30‑day trial period.

&#x20;⚠️ Facebook Business Verification is different from verifying a Facebook Business Page.

**Steps to Verify Your Business**

1. Log in to your **Facebook Business Manager** (or create one if needed).
2. Go to **Business Settings**.
3. Scroll to **Security Center**.
4. Click **Start Verification** — there are four main steps.
5. Enter your **business information** (e.g. name, address, phone).
6. Facebook may suggest matching businesses — select yours, then click **Next**.
7. Confirm your details.
8. Choose a **verification method** (e.g. document upload or phone).
9. Enter the **verification code** received.
10. Submit and wait for confirmation.

### 3️⃣ Prepare WhatsApp Assets

To offer your customers the best experience, please prepare the following assets:

* A profile image (ideally, your logo) in square format, max 5mb
* A business description (max 256 letters) to add in your profile
* Your company address to add in your profile

### 🎉 Great! You can now integrate WA & Zipchat

Now that you have completed all these steps, you can now integrate WhatsApp & Zipchat.

[**Complete the integration by yourself, following this guide (it takes only 5 minutes 🕑)**](https://www.notion.so/WhatsApp-Setup-of-the-Agent-Marketing-Campaigns-28271caef48b800da72de217662f447f?pvs=21)


# Bubble Chat: Edit design

Zipchat AI gives you complete control over your chatbot’s appearance and interaction style. By aligning the chatbot’s design with your website’s branding and tailoring its functionality, you create a seamless and engaging user experience that encourages customer interaction.

You can edit your bubble chat design by going to Channels / Bubble Chat / Edit

***

#### Key Customization Options

**1. AI Agent Personalization**

* **Name of Your AI Agent**: Set a relatable name and role for your chatbot.\
  Example: *Luca from \[BRAND NAME] | Online.*
* **Avatar**: Upload an avatar or photo to give your chatbot a human touch.\
  *Tip*: Use a friendly and approachable image to build trust.

***

**2. Welcome Message**

* Create a warm, inviting first impression with a custom message.\
  Example:\
  *"Welcome to \[BRAND NAME] 😎! I'm Luca, how can I help you today?"*

***

**3. Predefined Messages (Chat Starters)**

* Add quick-action buttons to guide users into specific conversations.\
  Examples:
  * *"Product Recommendation"*
  * *"Order Tracking"*
  * *"Gift Ideas"*
* These messages make it easier for customers to engage without typing, improving efficiency and interaction rates.

***

**4. Placeholder Message**

* Set a placeholder in the input field to guide users on what to type.\
  Example: *"Write a message."*

***

**5. Chat Widget Customization**

* **Color**: Choose a widget color that matches your website’s theme.\
  Example: *Hex Code: #000000* (for a sleek black look).
* **Icon:** Choose *Modern*, *Classic*, or upload a *Custom* icon.
* **Bubble Size**: Adjust the chat bubble to "Large" for better visibility.
* **Bubble Position**: Place the bubble where it’s most accessible—default to "Bottom Right" but fine-tune its position with precise left/right and up/down settings.

***

**6. Lead Collection Popup**

* **Title and Subtitle**: Personalize the prompt for email collection.\
  Example:
  * *Title*: "Leave your email for a 10% discount"
  * *Subtitle*: "You will receive the coupon code immediately"
* **Buttons**:
  * *Send Label*: "Send message"
  * *Skip Label*: "Skip" (for users who prefer not to share their email).
* **Placeholder Text**: Guide visitors with text like *"Email address."*

***

**7. Marketing Consent**

* Enable or disable the marketing consent option based on your strategy.
* Customize the message:\
  Example: *"I agree to receive marketing emails."*

***

8. **Chat Bubble Position**

* **Chat bubble button size**: Choose from "**Small**", "**Medium**", or "**Large**" to control the overall size of your chat widget.
* **Chat bubble button position**: Select from four corner positions: "**Bottom Center**" (default), "**Bottom Right**", **Bottom Left**", "**Top Right**", or "**Top Left**" to determine where your chat widget appears on the page.
* **Move Left/Right**: Fine-tune the horizontal position with pixel precision (**0-100px**) to adjust the bubble's distance from the selected corner.
* **Move Up/Down**: Fine-tune the vertical position with pixel precision (**0-100px**) to adjust the bubble's distance from the selected corner.
* **Z-index**: Control the stacking order of your chat widget on the page - higher values (like **1000**) place it above other elements, while lower values place it behind them. The default value of **999** works well for most websites, but increase it if your widget is being hidden behind other page elements.

***

### Example Setup

* **AI Name**: *Luca from \[BRAND NAME] | Online.*
* **Avatar**: A friendly photo of Luca with a smile.
* **Welcome Message**:\
  *"Hi there! I'm Luca, here to help. Ask me anything about our products or services."*
* **Predefined Messages**:
  * *"Track My Order"*
  * *"Need Product Info"*
  * *"Chat About Discounts."*
* **Widget Color**: Match your brand’s primary color (e.g., #FF5722 for orange).
* **Position**: Bottom right, 20px from the edges.

***

### Create a Chatbot Your Customers Will Love

With Zipchat’s **Look & Feel** options, you can build a chatbot that not only looks professional but also feels approachable and easy to use. From branding to functionality, every detail is in your hands to ensure your chatbot enhances your website’s user experience and drives customer engagement. 🚀


# WhatsApp: Handle display name rejections

When setting up your Official WhatsApp Business Account, your chosen display name is reviewed by Meta. Sometimes, display names are rejected. This guide explains why that might happen, and walks you through the exact steps to appeal the rejection.

### Common Reasons for Display Name Rejection

Here are the most frequent reasons Meta may reject your requested display name:

1. Mismatch with Business Name: The display name must closely match your business's legal name, brand, or online presence (e.g., website or social media).
2. Use of Special Characters or Emojis: Display names should avoid excessive punctuation, emojis, or symbols.
3. Generic or Vague Names: Meta does not accept overly broad names like "Customer Service" or "Info Desk".
4. Impersonation Risk: Names resembling other well-known brands or public entities are rejected.
5. Unverified Business: Your Business Manager account must be fully verified for Meta to approve a display name.
6. Website URL in the display name: Meta does not accept things like [ABC.com](http://abc.com)

## How to Appeal a Rejected Display Name

If you believe your display name should be accepted, you can appeal the decision directly to Meta. Follow these steps:

#### Step 1: Go to Meta Business Support

Visit[ https://business.facebook.com/direct-support/](https://business.facebook.com/direct-support/)

#### Step 2: Start a New Request

* Click on "Ask a Question"

#### Step 3: Select the Topic

* Choose "Dev: Phone Number & Registration"

<figure><img src="https://lh7-rt.googleusercontent.com/docsz/AD_4nXdTVv5iPPoo8z_XP4U_P0EgTWLjnzX4X1NO79lT18KtEnJpX82hOwWj--M3oIAiPZJ58f8JTYtz0sZq4cuPnl8hwLRKDJrTSaNJwmR83Q4QpkXu_fG1CA_tLld3a5oLUEDha9Y2?key=5XVMDCPL0Zlx6lS8qeEVkQ" alt=""><figcaption></figcaption></figure>

#### Step 4: Fill in the Request Details

You’ll need to complete a brief form. Make sure to insert the following information:

* Request Type: Select "Appeal display name rejection"
* Title: Provide a clear title (e.g., Appeal for Rejected WhatsApp Display Name – \[Your Business Name])
* Whatsapp Account ID: Please select your phone number
* Description: Use a professional tone. Here’s a sample message you can customize:\ <br>

**Example Message**

Title: Appeal for Rejected WhatsApp Display Name – Acme Ltd.

Description:

Hello Meta Support,

We recently submitted a display name request for our Official WhatsApp Business Account and received a rejection. The name submitted was “Acme Ltd.”, which is our registered business name and appears consistently across our website (<https://acme.com>), social media profiles, and legal documentation.

We believe this display name complies with Meta’s display name guidelines, as it accurately represents our business identity.

Kindly review this appeal and let us know if any additional clarification is required.

Thank you,\
\[Your Name]\
\[Your Role]

<figure><img src="https://lh7-rt.googleusercontent.com/docsz/AD_4nXdr2bAQ_d0b7yeraykzgEv3UsKLSNrP369LpYNMCkhVLWCxsONqgHKWZ6EGZx6JYmLrtN29590fsrjOhAOeOxupNQdTY2MtLnVJ3N0AIyRP0x6p5alBPLlJF8QSfdZMkITVWHwlSw?key=5XVMDCPL0Zlx6lS8qeEVkQ" alt=""><figcaption></figcaption></figure>

Once submitted, Meta will review your request and respond via email or within the support inbox on your Business Manager.

**Final Tips**

* Double-check that your display name matches your public brand presence.
* Make sure your Business Manager account is fully verified before appealing.
* Be clear, concise, and professional in your appeal message.

If you have any questions or need assistance crafting your appeal, feel free to contact our Zipchat.ai support team—we’re here to help!

### What to Do If Your Appeal Is Rejected Again

If your appeal is not approved and you believe the rejection is still incorrect, you can escalate the issue further. Here’s how:

1. Go back to[ https://business.facebook.com/direct-support/](https://business.facebook.com/direct-support/)
2. Click "Ask a Question"
3. This time, select "WaBiz: Escalation Support"

In the new ticket, explain that your initial display name request was rejected and your appeal was denied, but you would like to escalate the matter for further review. Provide all supporting evidence again, and clearly state why your display name should be accepted.


# Email: connecting Zipchat to your Inbox

With ZipChat, you can empower your AI agent to manage customer support emails directly. Follow this step-by-step guide to set up the integration and start responding to emails automatically.

### Step 1: Set Up the Email Functionality

Go to your Chat Settings, and under the Email section, click on Activate.\
Once inside, you’ll see two sections:

* Receiving Emails
* Sending Emails

#### Receiving Emails

To enable your AI to receive emails, you first need to connect your existing support inbox to ZipChat. Here’s how:

1. In the Receiving Emails section, you’ll find a unique ZipChat email address.
2. Set up a forwarding rule from your current support email to this ZipChat address.

Forwarding instructions vary depending on your provider.\
In the Chat Settings > Email Setup, you’ll find specific guides for:

* Shopify Email
* Gmail
* Microsoft Outlook
* cPanel

Once forwarding is set up, any email sent to your support address will be automatically routed to ZipChat, where the AI can process and respond.

#### Sending Emails

By default, replies from the AI are sent from your ZipChat email address. However, to ensure the best deliverability and avoid spam filters, we recommend connecting your own custom domain.

Here’s how:

1. Go to Chat Settings > Setup, under the Send Emails section.
2. Click on Add Domain and enter your domain.
3. Once added, click again on Add Domain to confirm.
4. Then click Verify to start the DNS configuration process.

The DNS setup steps depend on your provider.\
We provide specific instructions for:

* Shopify
* GoDaddy
* Namecheap
* Cloudflare

Once DNS records are correctly configured, your AI will send emails directly from your custom domain.

***

If you have any questions or need assistance at any point, don’t hesitate to reach out to us at <support@zipchat.ai>.

<br>


# Zendesk: Connecting Zipchat to Your Zendesk Account

Let Zipchat answer your customers inside Zendesk — both email tickets and the Web Widget — and hand off cleanly to your human team when needed.

Zipchat works inside Zendesk as a teammate: it answers your customers and escalates to your human agents when needed. It can handle two surfaces, **independently or together**:

* **Email & other ticket sources** — Zipchat replies to email, web form and API tickets as a Zendesk agent you choose.
* **Zendesk Web Widget (Messaging)** — Zipchat answers the chat bubble on your site.

You connect with your Zendesk login (OAuth): no API tokens to create or paste.

> ⚠️ **Using Zendesk's built-in AI agent?** Disable it before connecting Zipchat, or customers will get duplicate responses. Admin Center → **AI → AI agents**; for each active agent open **Settings → Brand and channels** and uncheck **Messaging**, **Email**, and **Web form**, then publish.

***

### What you'll need

* A **Zendesk administrator** to authorize Zipchat.
* A **Zendesk agent for Zipchat's replies**. A dedicated agent (e.g. **Zipchat Bot**, with a plus-alias such as `support+zipchat@yourdomain.com`) works best. Light agents, chat-only agents and contributors can't reply.
* Optional: **Zendesk Suite Professional or above**, for Web Widget conversations.

***

### Part 1 — Connect Zendesk

#### Step 1 — Authorize Zipchat

1. In Zipchat, open **Channels** and click **Turn on** on the Zendesk card.
2. Enter your **Zendesk address** — your subdomain (e.g. `your-company`) or your Zendesk URL. Always use your *account* address, the one you log in at, even if you use several brands.
3. Click **Connect Zendesk**, sign in to Zendesk as an administrator, and click **Allow**.

#### Step 2 — Choose who replies

Back in Zipchat, pick the agent under **Reply as** and click **Continue**. Customers see this agent's name on Zipchat's replies; Zipchat also writes internal notes as this agent and is assigned new tickets through it. You can change it later in the Zendesk settings.

#### Step 3 — Ticket routing (automatic)

Zipchat adds a webhook and two triggers whose names start with **Zipchat** to your Zendesk account (Admin Center → **Apps and integrations**). From then on:

* New email, web form and API tickets are assigned to your **Reply as** agent and answered by Zipchat.
* Customer replies on tickets still assigned to that agent are answered too.
* Agent replies, internal notes and assignment-only updates don't trigger Zipchat. Reassign a ticket to a person and Zipchat stops replying on it.

> 💡 Already route tickets with your own rules, or connecting a second store on the same Zendesk account? See *Multiple stores* below — Zipchat leaves existing routing alone.

#### Step 4 — Install the handoff skill

In Zipchat, open **Prompt and Skills** and install **"Zendesk: escalate to human"** from the gallery. It needs no credentials: it uses your Zendesk connection. When a customer asks for a person, Zipchat adds a private internal note summarizing the request and unassigns the ticket for your team.

#### Step 5 — Test the email path

Send an email to your support address from a customer email address and verify: the ticket is assigned to your Reply as agent, Zipchat replies within \~15 seconds, and asking for a person unassigns the ticket with an internal summary note.

***

### Part 2 — Web Widget (optional)

Requires Zendesk Suite Professional or above, with Messaging enabled. You can do this in the setup wizard (**Handle Web Widget chats**) or later in the Zendesk settings (**Web Widget** tab).

#### Step 6 — Create the Conversations integration

> ⚠️ **One per Zendesk account — ever.** If another of your stores is already connected to this Zendesk account, skip this step and reuse that integration's shared secret (see *Multiple stores* below). Zendesk rejects a second integration with the same webhook endpoint, and one integration serves all your brands.

1. Admin Center → **Apps and integrations → Conversations integrations → Create integration**.
2. Name it e.g. **Zipchat widget**.
3. Webhook endpoint: the **Conversations webhook URL** shown in Zipchat.
4. Subscribe to **Conversation created** and **Conversation message**.
5. Copy the **Shared secret**.

#### Step 7 — Create a Conversations API key

1. Admin Center → **Apps and integrations → APIs → Conversations API → Create API key** (an account-level key, not one inside the integration).
2. Copy the **App ID**, **Key ID** (starts with `app_`) and **Secret key** — the secret is shown only once.

#### Step 8 — Save in Zipchat

Paste the **Integration shared secret**, **App ID**, **Key ID** and **Secret key**, then click **Save and register switchboard** (in the Zendesk settings, saving registers it). This makes Zipchat the default responder for new widget conversations and hands conversations to Agent Workspace when a customer asks for a person.

The handoff skill from Step 4 also covers the widget: on widget conversations Zipchat asks once for the customer's email and adds it to the internal note.

#### Step 9 — Test the widget

Open the widget preview (Admin Center → **Channels → Messaging** → your widget → **Test it now**) and verify: the welcome message appears, replies render formatting (bold, links, bullets), and asking for a person hands the conversation to Agent Workspace and leaves an unassigned messaging ticket with a summary note.

***

### Already connected with an API token?

For each store (about a minute each):

1. In Zipchat, open **Channels** and click **Settings** on the Zendesk card.
2. On the **Tickets** tab, in the **Zendesk account** section, click **Switch to OAuth**.
3. Sign in to Zendesk as an administrator and click **Allow**.
4. Back in Zipchat, check **Reply as** in the same section. Zipchat keeps the same agent when that agent can reply publicly; if another agent is shown, choose yours and click **Save**.

Your ticket routing and Web Widget setup stay as they are. Keep your API token until Zipchat support confirms your handoff skill no longer needs it.

***

### Multiple stores on one Zendesk account

If you run several stores (Zendesk **brands**) in a single Zendesk account, connect **one Zipchat chat per store**, each authorized separately in Step 1:

| Setting                                                | Per store?                                                                                                                                                                                                                                                                     |
| ------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Zendesk address                                        | **Same** on every store (the account address — never a brand subdomain)                                                                                                                                                                                                        |
| Zendesk brand                                          | **Different** — choose each store's brand in the Zendesk settings, so its support email and **Test channel** use that brand's address                                                                                                                                          |
| Ticket routing                                         | Automatic for the **first** store only. For each further store, the **Ticket routing** section shows a **Webhook URL**, **Bearer token** and **JSON payload template**: create one webhook per store and triggers like Zipchat's, with a **Brand Is → (your brand)** condition |
| Conversations App ID / Key ID / Secret / shared secret | **Same** on every store — one API key, one integration                                                                                                                                                                                                                         |
| Conversations integration in Zendesk                   | **One for the whole account** — never create a second one                                                                                                                                                                                                                      |
| Brand widget integration ID                            | **Different** — this is what routes each brand to its store                                                                                                                                                                                                                    |
| Handoff skill                                          | Install **"Zendesk: escalate to human"** on every store                                                                                                                                                                                                                        |

**Widget routing setup:**

1. Each brand needs its own Web Widget (Admin Center → **Channels → Messaging → Add channel → Web Widget** — Zendesk allows one widget per brand).
2. Connect every store in Zipchat with the same Conversations credentials (Part 2, skipping Step 6 after the first store).
3. In any store's Zendesk settings, open the **Web Widget** tab and click **List brand widgets**. You'll see each brand's widget with its ID.
4. Paste each widget's ID into the matching store's **Brand widget integration ID**. **Map every store, including the first one you connected.**

How routing behaves:

* A widget conversation goes to the store mapped to that widget.
* If a widget isn't mapped to any store, the conversation falls back to a store with an **empty** Brand widget integration ID (if one exists) — otherwise Zipchat stays silent rather than answering as the wrong brand.

> 💡 The widget IDs from **List brand widgets** are *not* the "Integration ID" shown on your Conversations integration page in Admin Center — that one identifies the shared Zipchat integration, not a brand widget.

***

### Disconnecting

In Zipchat, open **Channels**, click **Settings** on the Zendesk card, and click **Disconnect** at the top of the page. Zipchat hands the Web Widget back to Zendesk (Agent Workspace becomes the default responder again) and disables the webhook and triggers it created. Routing you set up yourself, the Conversations integration and the API key stay in Zendesk — remove them manually if you no longer need them. To stop only the widget, use **Disconnect Web Widget** in the **Web Widget** tab. You can also revoke Zipchat's access in Zendesk at any time.

***

### Troubleshooting

| Issue                                                  | Fix                                                                                                                                                          |
| ------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| "Ticket routing isn't set up"                          | Click **Retry ticket setup**; if Zendesk permissions changed, **Reconnect Zendesk** as an administrator                                                      |
| Zendesk settings show **Reconnect required**           | Zipchat's access was revoked or expired — click **Reconnect Zendesk** in the **Zendesk account** section and approve again                                   |
| No reply to new tickets                                | Check the ticket came in by email, web form or API and is assigned to your Reply as agent                                                                    |
| Zipchat stopped replying after a human took the ticket | Intentional — Zipchat only handles tickets assigned to its agent                                                                                             |
| Raw HTML in widget replies, or the widget is silent    | The switchboard isn't registered — the **Web Widget** tab shows a warning; fix the reason Zendesk gave and click **Try again**                               |
| Can't create a second Conversations integration        | Don't — reuse the first one's shared secret on every store (see *Multiple stores*)                                                                           |
| One brand's widget is silent                           | That widget isn't mapped to any store and no store has an empty mapping — check **List brand widgets** and the **Brand widget integration ID** on each store |
| The wrong store's bot answers a brand's widget         | That brand's widget is unmapped and falling back to the store with an empty mapping — map every store explicitly                                             |
| Widget mapping rejected as "already taken"             | Another of your stores is already mapped to that widget — each widget can route to only one store                                                            |


# Configuration

The **Configurator** is your control center for managing advanced chatbot features. Use it to:

* Enable **order tracking** for real-time updates.
* Activate **collection forms** to capture customer emails.
* Activate **forward requests** for seamless customer support.
* Add contact information.
* Define crawling settings.
* Activate Spam Filter.

With the Configurator, you can customize your chatbot’s capabilities to align with your business needs, enhancing both customer interactions and your overall strategy. 🚀


# Contact Information

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F5NZGOs75w74fwNdEuL0K%2FScreenshot%202024-11-23%20at%2018.25.27.png?alt=media&amp;token=78b6c4fc-76fb-4b45-92dd-6592afb37a0f" alt=""><figcaption></figcaption></figure>

The **Contact Information** section in Zipchat AI allows merchants to enter their preferred contact details, ensuring that visitors have multiple ways to get in touch when they need further assistance. This section is crucial for businesses that want to offer clear and accessible communication channels to their customers.

When a visitor requests to speak directly with your business, the chatbot will use the information provided in this section to guide them on how to connect with you. You can include various types of contact methods, tailored to how you prefer to be reached.

**Examples of Contact Information You Can Provide:**

* **Contact Form:**\
  "*If you want to get in touch, feel free to use our contact form at* [*example.com/contact*](http://example.com/contact)*.*"
* **Phone Number:**\
  "*If you'd like to connect, just give us a call at (555) 123-4567.*"
* **Email Address:**\
  "*To reach out, simply drop us an email at <contact@example.com>.*"
* **Direct Chat (Discord):**\
  "*For direct chat, join our Discord server at* [*discord.gg/example*](http://discord.gg/example)*.*"
* **Social Media:**\
  "*You can also find us on Twitter @example if you'd like to contact us*."

The **Contact Information** section lets you provide customers with multiple ways to reach you, ensuring clear and accessible communication channels. When a visitor asks to connect directly, Zipchat will guide them using the details you provide.

***

### What You Can Include

1. **Contact Form**\
   Example: *"Use our contact form at example.com/contact to reach us anytime."*
2. **Phone Number**\
   Example: *"Call us at (555) 123-4567 for immediate assistance."*
3. **Email Address**\
   Example: *"Drop us an email at <contact@example.com>, and we’ll get back to you shortly."*
4. **Direct Chat (Discord)**\
   Example: *"Chat with us directly on Discord at discord.gg/example."*
5. **Social Media**\
   Example: *"Find us on Twitter @example to connect with us."*

***

### Why It’s Important

* **Flexible Communication**: Offer customers their preferred way to connect, whether by email, phone, or social media.
* **Build Trust**: Transparent contact options show you’re accessible and committed to customer care.
* **Enhanced Experience**: Customers feel supported knowing help is just a call, message, or form away.


# Crawling Settings

The **Crawling Settings** section gives you precise control over how Zipchat AI processes your website content. By customizing these settings, you ensure the AI focuses on relevant data, improving its responses and creating a better user experience.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FFN7a9pGYPTooA7PJD9c6%2FScreenshot%202024-11-23%20at%2018.28.16.png?alt=media&amp;token=2c9a4932-8efc-476e-9d22-8fbb81c00fba" alt=""><figcaption></figcaption></figure>

### Customization Options

**1. Manage Out-of-Stock Products**

* **Include/Exclude Out-of-Stock Products**\
  Choose whether to crawl and index out-of-stock products. Excluding them prevents the AI from suggesting unavailable items, improving customer satisfaction.
* **Out-of-Stock Keyphrase**\
  Identify the keyphrase or HTML element unique to out-of-stock items, like *"Out of Stock"*. Zipchat uses this to accurately skip these pages.

**2. Ignore Irrelevant Page Elements**

* **Add or Remove Elements**\
  Specify parts of your website, like footers, headers, or banners, that the AI should skip when crawling. This ensures it focuses on meaningful content.
* **Use CSS Selectors**\
  Pinpoint elements to ignore using simple CSS syntax:
  * **Tags**: `header` or `footer`
  * **Classes**: `[class*="footer"]`
  * **IDs**: `[id*="promo-banner"]`

**3. Default Ignored Elements**

Zipchat may preconfigure certain elements to be ignored, such as:

* **Footers**: `[id*="footer"]` or `[class*="footer"]`
* **Headers or Navigation Bars**

You can adjust these defaults to better suit your site’s layout.

***

### Why Crawling Settings Matter

1. **Improved Relevance**: Focuses the AI on essential content, ensuring responses are accurate and useful.
2. **Better Shopping Experience**: Avoids suggesting out-of-stock products, reducing customer frustration.
3. **Efficient Performance**: Ignoring unnecessary elements speeds up crawling and enhances AI processing.

***

### Example Use Case

* **Out-of-Stock Products**: Exclude pages with the banner *"Currently Unavailable"*.
* **Ignore Elements**: Skip promotional banners and footers to keep responses clean and focused.

***

### Optimize Your AI for Success

Fine-tuning the **Crawling Settings** ensures that Zipchat AI gathers the most relevant information from your website. By focusing on what matters and ignoring distractions, you create a smarter, more efficient chatbot that delivers exceptional customer support and boosts satisfaction. 🚀


# Spam Filter

The **Spam Filter** in Zipchat AI helps manage the flow of messages, preventing disruptive behavior and ensuring interactions remain meaningful and user-friendly.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FsPiZMiQSj483kQRGKhDg%2FScreenshot%202024-11-23%20at%2018.31.17.png?alt=media&amp;token=f43d4d2f-4cd9-4a0e-bbfb-150a0acd83d2" alt=""><figcaption></figcaption></figure>

### How It Works

1. **Rate Limit (Max Replies per User)**
   * Control the maximum number of messages a user can send within a set time frame.
   * Prevent spamming or overwhelming the chatbot with irrelevant queries.
2. **Unlimited Option**
   * Allow unrestricted messaging if high-volume interactions are encouraged.
3. **Time Period Setting**
   * Define the time frame for the rate limit, such as per minute or per hour, to tailor chat pacing.
4. **Custom Message for Limits**
   * Notify users who exceed the limit with a polite message. Example:\
     *"Sorry, you're sending messages too quickly. Please try again shortly."*

***

### Why Use the Spam Filter?

* **Maintain Chat Quality**: Ensure conversations stay on-topic and productive.
* **Protect the AI**: Prevent the chatbot from being overwhelmed by excessive messages from competitors and/or spammers.
* **Improve User Experience**: Encourage thoughtful communication with polite notifications.


# Integrations

Zipchat AI integrates seamlessly with your existing systems to enhance functionality and streamline workflows. Whether you’re connecting to CRMs, marketing platforms, or custom APIs, Zipchat ensures smooth data flow and automation, helping you provide a more efficient and engaging customer experience. 🚀


# Zapier

The **Zapier Integration** connects Zipchat AI with over 2,000 apps, including Klaviyo, Shopify, Salesforce, and HubSpot, enabling seamless automation for your marketing, sales, and customer management processes.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F2X0goe4ViaOqHjolgCuT%2FScreenshot%202024-11-23%20at%2018.35.47.png?alt=media&amp;token=9845100f-8abf-42ad-9e6d-39f0515ab8fd" alt=""><figcaption></figcaption></figure>

### How to Set Up Zapier with Zipchat

1. **Create or Log In to Zapier**
   * New to Zapier? [Create an account.](https://zapier.com/)&#x20;
   * Already have one? Log in to start automating.
2. **Install the Zipchat App**
   * Install the Zipchat app on Zapier via [the provided link](https://zapier.com/developer/public-invite/209372/4e4df354198f48a9804bc3dbadb67494) to enable data flow between Zipchat and other apps.
3. **Authenticate with Credentials**
   * Enter the credentials from your Zipchat account to securely link it with Zapier and allow data transfer.

***

### Use Cases for Zapier Integration

1. **Lead Collection to CRM**
   * **Scenario**: Automatically send leads collected by Zipchat to your CRM (e.g., Salesforce).
   * **Workflow Example**:
     * Zipchat captures a lead.
     * Zapier adds it to your CRM, assigns it to a sales rep, and triggers a follow-up email campaign.
2. **Marketing Automation**
   * **Scenario**: Push customer preferences and contact details to your marketing platform (e.g., Klaviyo, Mailchimp).
   * **Workflow Example**:
     * Zipchat captures interest in a product category.
     * Zapier sends this data to Klaviyo, triggering a personalized email campaign for that category.

The only information that Zipchat can currently send to Zapier regards the customer's phone number, name and email address. We do not currently support the exchange of any other type of preference / information.


# Custom Order Tracking API integration

Easily connect your custom tracking system to Zipchat by following these steps:

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FrXFBGPqmXzh8OlCrDowD%2FScreenshot%202024-11-23%20at%2018.39.17.png?alt=media&amp;token=9d71a3a6-255b-4448-bf9c-4bcb6546bc66" alt=""><figcaption></figcaption></figure>

### How to Set Up Custom Order Tracking

1. **Share API Documentation**
   * Forward your [**Custom Order Tracking API documentation**](https://zipchat.notion.site/Custom-Order-Tracking-API-315c99c7ffe84f198d5bd99e35121b81?pvs=4) to your developer to enable integration with Zipchat.
2. **Implement the Endpoint**
   * Have your developer create an API endpoint in your system that Zipchat can call to check order statuses.
3. **Add the Endpoint and API Key**
   * Input the **API endpoint URL** and **API key** into Zipchat’s configuration settings to establish a secure connection.
4. **Provide Order Format**
   * Specify an example order format for testing.
5. **Enable Order Tracking**
   * Activate the order tracking feature from the **Chat Settings** or **Configuration** section.
6. **Test the Setup**
   * Use the **Test Chat** tool and ask, *"Where is my order?"* to verify the integration.

***

### Key Components

* **API Key**: A unique key to authenticate Zipchat with your internal system.
* **Order Tracking API Endpoint**: The custom API endpoint your system provides for retrieving order details.

{% hint style="info" %}
You can also find [this guide on Notion](https://zipchat.notion.site/Custom-Order-Tracking-API-315c99c7ffe84f198d5bd99e35121b81).
{% endhint %}

## About the API

* The custom order tracking API endpoint allows you to provide Zipchat's AI agent with access to your order database so it can help customers with their order status and tracking information.
* Whenever a customer asks about order tracking, Zipchat will collect their order info and email.
* Once the agent has the right information, it will call the custom endpoint provided by you, expect to receive context, and generate a reply based on the context that you provided.

## Prerequisites

In order to connect the custom endpoint to your chat, we'll need the following things from you:

* Endpoint URL
* API key
* Order number format (used so Zipchat knows what to look for, e.g., "#1001", "5555", etc.) - this should be a number that the customer has access to so they can provide it

This guide is for developers implementing the response handling for the Order Lookup Service. Your system will receive GET requests and should respond according to the specifications below.

## **Implementation**

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FFY0RpBvxjksPtOofR7Mw%2FScreenshot%202024-11-23%20at%2018.37.54.png?alt=media&amp;token=45690515-b1db-471c-a763-1cde2737aae2" alt=""><figcaption></figcaption></figure>

### **Incoming Request**

You will receive GET requests with the following characteristics:

* Endpoint: \[Your endpoint URL]
* Authentication: \[ Your API Key ] in `x-api-key` header
* Query Parameters:
  * `order_id`: string (required)
  * `customer_email`: string (required)

### **Authentication**

Validate the API key provided in the `x-api-key` header. If invalid or missing, return a 401 Unauthorized response.

### **Responses**

#### 1. Found Order (Status 200 OK)

When an order is found, respond with:

* Status: 200 OK
* Content-Type: application/json
* Body:

  ```json

  {
    "context": "string",
    "tracking_url": "string"
  }

  ```

#### **Context Field**

The context field is crucial for guiding an AI agent's response to the customer. It should:

* Provide clear, concise information about the order status
* Include relevant order details
* Optionally include policy information

Examples:

* "Order 123 found. It includes 1 x Product X, 2x Product Y. Not shipped yet, normally ships in two days."
* "Order 456 is on its way, can be followed via the provided tracking link."
* "Order 789 found but not shipped. Contact support for further assistance."

### **Tracking URL Field**

If available, provide a URL where the customer can track their order. If not applicable, this field can be null or omitted.

#### **2. Order Not Found (Status 404 Not Found)**

When an order is not found, respond with:

* Status: 404 Not Found
* Content-Type: application/json
* Body:

  ```json

  {
    "context": "string"
  }

  ```

#### **Context Field for Not Found**

Provide information about the order not being found and suggest next steps.

Examples:

* "No order found with the provided details."
* "Order not found - please double-check your order number."
* "Order not found - contact support for further assistance."

#### **3. Unauthorized Access (Status 401 Unauthorized)**

When the API key is invalid or missing:

* Status: 401 Unauthorized
* No body required

### **Implementation Notes**

1. Ensure all responses use the correct Content-Type header: `application/json`.
2. The context field is critical for customer communication. Make it informative yet concise.
3. ‼️ **Important**: For maximum flexibility, we will not include status information into the AI Agent context - always include information if an order was found or not in the context

### Testing

* You can use Postman to send the described request while developing
* Afterwards you can send us details about the endpoint and we’ll validate everything works

### **Timeouts**

* All requests have a 5 second timeout rule. If no response is received within 5 seconds, the Agent will respond that it couldn’t check the order status at this point.

### **Support**

For any questions about this implementation, please contact <ruslan@zipchat.ai>


# Backend API

The Backend API lets you programmatically access your Zipchat conversation data and manage your AI's configuration. Sync conversations with your CRM, reply to customers, and manage rules and skills.

The Backend API lets you programmatically access your Zipchat conversation data and manage your AI's configuration. Use it to sync conversations with your CRM, build custom analytics dashboards, take over conversations from the AI, reply to customers, and manage rules, custom tools (skills), and variables — all from your own systems.

### Getting Started

1. Go to **Settings > Integrations** in your Zipchat dashboard
2. Click **Enable** on the Backend API card
3. Copy your API key (prefixed with `zc-`) — store it securely, it is only shown once

### Authentication

Include your API key as a Bearer token in the `Authorization` header:

```
Authorization: Bearer zc-your_api_key_here
```

All requests must be authenticated. Unauthenticated or invalid requests return `401 Unauthorized`.

The API accepts two kinds of token, interchangeably, on every endpoint:

#### Chat-level tokens (`zc-`)

Scoped to a single chat. Generated per chat in **Settings > Integrations > Backend API**. A chat token only authenticates requests whose `:chat_id` matches the chat it belongs to — any other `chat_id` returns `401`.

#### User-level tokens (`zcu-`)

Personal to a user and work against **any chat that user can access** (chats they own or are a member of). Generate or regenerate one under **Account > Settings** (`/account/settings/edit`). Use the same `Authorization: Bearer zcu-...` header. A user token used against a `chat_id` the user cannot access returns `401` and never reveals whether that chat exists.

Both token types can call every endpoint below. Two caveats for user tokens:

* **Role model**: configuration writes (updating the prompt, creating/updating/deleting rules, custom tools and variables) follow the same permissions as the dashboard. A `member`-role (read-only) user's token receives `403 Forbidden` on those endpoints but can still use all read and conversation endpoints.
* **Revocation**: user tokens authenticate independently of the chat's Backend API integration — disabling that integration revokes only the chat-level `zc-` key. To cut off a user token, revoke it in that user's Account > Settings, or remove the user from the chat.

Tokens are environment-specific: a token generated in production only works against production, and vice versa for staging/local environments.

### Base URL

```
https://app.zipchat.ai/api/integrations/backend_api/v1
```

### Endpoints

#### List Chats

```
GET /chats
```

Lists the chats reachable with your credential, so clients can discover chat ids. With a **user token** this returns every chat the user can access; with a **chat token** it returns only that token's chat.

**Parameters**

| Parameter  | Type    | Default | Description                |
| ---------- | ------- | ------- | -------------------------- |
| `page`     | integer | `1`     | Page number                |
| `per_page` | integer | `50`    | Items per page (max `100`) |

**Response**

```json
{
  "chats": [
    {
      "id": 1,
      "name": "Acme Store AI",
      "domain": "acme-store.com",
      "created_at": "2026-01-15T10:30:00Z"
    }
  ],
  "pagination": {
    "page": 1,
    "per_page": 50,
    "total_count": 1,
    "total_pages": 1,
    "has_next_page": false
  }
}
```

***

#### List Conversations

```
GET /chats/:chat_id/conversations
```

Returns a paginated list of non-empty conversations for the given chat, including archived conversations. Results are ordered by last message time descending, then ID descending.

**Parameters**

| Parameter               | Type    | Default | Description                                                                                                                                  |
| ----------------------- | ------- | ------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| `page`                  | integer | `1`     | Page number                                                                                                                                  |
| `per_page`              | integer | `50`    | Items per page (max `100`)                                                                                                                   |
| `last_message_at_since` | string  | —       | ISO 8601 timestamp. Only return conversations with `last_message_at >=` this time. Does not detect status-only changes.                      |
| `updated_at_since`      | string  | —       | ISO 8601 timestamp. Only return conversations with `updated_at >=` this time, including archive, escalation, purchase and sentiment changes. |

**Response**

```json
{
  "conversations": [
    {
      "id": 12345,
      "chat_id": 1,
      "current_url": "https://example.com/products/blue-tee",
      "start_link": "https://example.com/products/red-tee",
      "created_at": "2026-01-15T10:30:00Z",
      "updated_at": "2026-01-15T10:45:00.123456Z",
      "archived": false,
      "last_message_at": "2026-01-15T10:45:00Z",
      "channel": "web",
      "manual_reply_mode": false,
      "last_escalated_at": null,
      "last_escalation_resolved_at": null,
      "assignee": null,
      "share_url": "https://app.zipchat.ai/chats/1/conversations/12345",
      "lead": {
        "id": 100,
        "full_name": "John Doe",
        "email": "john@example.com",
        "phone_number": "+1234567890",
        "email_marketing_consent": true
      },
      "customer_sentiment": "conviction",
      "customer_sentiment_reason": "Asked whether the Classic Tee runs true to size before buying.",
      "purchase_sentiment": "strongly_influenced",
      "purchase_sentiment_reason": "The assistant answered the sizing doubt about the Classic Tee, which is the item that was ordered.",
      "purchases": [
        {
          "order_id": "5551234567",
          "order_total": "29.9",
          "currency": "USD",
          "line_items": [
            { "id": "9213800579256", "title": "Classic Tee", "price": "29.9", "quantity": 1 }
          ],
          "created_at": "2026-01-15T10:50:00Z"
        }
      ]
    },
    {
      "id": 12346,
      "chat_id": 1,
      "current_url": null,
      "start_link": null,
      "created_at": "2026-01-15T11:00:00Z",
      "updated_at": "2026-01-15T11:20:00.123456Z",
      "archived": true,
      "last_message_at": "2026-01-15T11:20:00Z",
      "channel": "whatsapp",
      "manual_reply_mode": true,
      "last_escalated_at": "2026-01-15T11:10:00Z",
      "last_escalation_resolved_at": "2026-01-15T11:18:00Z",
      "assignee": {
        "id": 42,
        "name": "Stan Marsh",
        "email": "stan@example.com",
        "avatar_url": "https://app.zipchat.ai/rails/active_storage/blobs/redirect/.../avatar.png"
      },
      "share_url": "https://app.zipchat.ai/chats/1/conversations/12346",
      "lead": null,
      "customer_sentiment": null,
      "customer_sentiment_reason": null,
      "purchase_sentiment": null,
      "purchase_sentiment_reason": null,
      "purchases": []
    }
  ],
  "pagination": {
    "page": 1,
    "per_page": 50,
    "total_count": 142,
    "total_pages": 3,
    "has_next_page": true
  }
}
```

**Page context**

Both list and detail responses include these nullable page-context fields:

| Field         | Type           | Description                                                                                                                                        |
| ------------- | -------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
| `current_url` | string or null | Stored page URL associated with the customer's latest storefront message. Sending a message from another page updates it; browsing alone does not. |
| `start_link`  | string or null | First available page URL captured for the conversation. Later messages from other pages do not replace it.                                         |

Use these URLs to map conversations to products in your system. They are page URLs, not product IDs, and a conversation can discuss multiple products even if it started on a product page. Both fields may be `null` when page context is unavailable, including on non-storefront channels or older conversations. Reading either endpoint does not modify them.

`archived` and `updated_at` are included in both list and detail responses. `updated_at` uses microsecond precision and reflects changes to the conversation record; it is not a change log for every nested lead or message edit.

**Incremental status sync**

Use `updated_at_since` alone to pick up archive/unarchive and escalation changes even when no message has been added. If both timestamp filters are provided, both must match (AND). Invalid timestamps return `422`; omitted or blank filters are ignored.

1. Perform an initial paginated fetch and upsert conversations by ID.
2. Record the time at the **start** of each polling cycle, and fetch every page using the same `updated_at_since` value from the previous completed cycle, with an overlap (for example, one minute).
3. Only advance the checkpoint after all pages succeed. Deduplicate overlapping results by conversation ID, using `updated_at` to avoid applying older responses.
4. Periodically reconcile your tracked conversations, including archived ones, via the detail endpoint so missed archive or unarchive changes can be recovered. Pagination uses offsets, so concurrent changes can move records between pages; it is not a snapshot.

Keep archived records in your local sync state so that a later unarchive can return them to your queue. Retain timestamp precision and account for client/server clock skew when choosing an overlap. The filter reflects conversation updates, not deletions or every update to associated records. No status-change webhook is provided.

The `lead` and `assignee` fields are `null` when not set. `last_escalated_at` is set when the conversation was escalated by the AI or via the API; `last_escalation_resolved_at` is set when the escalation was marked resolved in the dashboard or via the API.

**Sentiment and purchases**

Both list and detail responses include the classifications shown on the dashboard's **Insights** card, and the orders attributed to the conversation:

| Field                       | Type           | Description                                                                                                                                                                                                                             |
| --------------------------- | -------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `customer_sentiment`        | string or null | The customer's buying stage, shown as "Customer sentiment" on the dashboard: `discovery` (browsing, no product in mind), `conviction` (weighing a specific product), `post_purchase` (asking about an order already placed) or `other`. |
| `customer_sentiment_reason` | string or null | One sentence explaining the `customer_sentiment` verdict.                                                                                                                                                                               |
| `purchase_sentiment`        | string or null | How much the conversation influenced its purchases: `strongly_influenced`, `influenced` or `not_influenced`. One verdict covers every purchase in the conversation. Always `null` when `purchases` is empty.                            |
| `purchase_sentiment_reason` | string or null | One sentence explaining the `purchase_sentiment` verdict.                                                                                                                                                                               |
| `purchases`                 | array          | Orders attributed to the conversation, oldest first. Empty when none.                                                                                                                                                                   |

Each purchase has:

| Field         | Type   | Description                                                                                                                                    |
| ------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `order_id`    | string | The store's order ID (the Shopify order ID on Shopify stores).                                                                                 |
| `order_total` | string | Order total as a decimal string (for example `"29.9"`), in `currency`.                                                                         |
| `currency`    | string | ISO 4217 currency code.                                                                                                                        |
| `line_items`  | array  | Ordered items, each with `id` (string), `title`, `price` (decimal string) and `quantity` (integer). Empty when the store did not report items. |
| `created_at`  | string | When Zipchat recorded the purchase.                                                                                                            |

Sentiments are classified once a conversation has been idle for 24 hours, so both are `null` (pending) on recent conversations. Recording a purchase and classifying either sentiment move the conversation's `updated_at`, so the incremental sync on `updated_at_since` described above picks them up.

***

#### Get Conversation

```
GET /chats/:chat_id/conversations/:id
```

Returns a single conversation with its messages.

**Parameters**

| Parameter                  | Type    | Default | Description                                                       |
| -------------------------- | ------- | ------- | ----------------------------------------------------------------- |
| `message_page`             | integer | `1`     | Message page number                                               |
| `message_per_page`         | integer | `100`   | Messages per page (max `200`)                                     |
| `message_created_at_since` | string  | —       | ISO 8601 timestamp. Only return messages created since this time. |

**Response**

```json
{
  "conversation": {
    "id": 12345,
    "current_url": "https://example.com/products/blue-tee",
    "start_link": "https://example.com/products/red-tee",
    "created_at": "2026-01-15T10:30:00Z",
    "updated_at": "2026-01-15T10:45:00.123456Z",
    "archived": false,
    "last_message_at": "2026-01-15T10:45:00Z",
    "channel": "web",
    "manual_reply_mode": false,
    "last_escalated_at": null,
    "last_escalation_resolved_at": null,
    "assignee": null,
    "share_url": "https://app.zipchat.ai/chats/1/conversations/12345",
    "lead": {
      "id": 100,
      "first_name": "John",
      "last_name": "Doe",
      "full_name": "John Doe",
      "email": "john@example.com",
      "phone_number": "+1234567890",
      "email_marketing_consent": true,
      "phone_marketing_consent": false,
      "shopify_customer_id": "7890123456",
      "additional_attributes": {},
      "created_at": "2026-01-15T10:31:00Z"
    },
    "customer_sentiment": "conviction",
    "customer_sentiment_reason": "Asked whether the Classic Tee comes in blue before buying.",
    "purchase_sentiment": "influenced",
    "purchase_sentiment_reason": "The assistant confirmed the blue Classic Tee was available, and that item was ordered.",
    "purchases": [
      {
        "order_id": "5551234567",
        "order_total": "29.9",
        "currency": "USD",
        "line_items": [
          { "id": "9213800579256", "title": "Classic Tee", "price": "29.9", "quantity": 1 }
        ],
        "created_at": "2026-01-15T10:50:00Z"
      }
    ],
    "messages": [
      {
        "id": 50001,
        "created_at": "2026-01-15T10:30:05Z",
        "role": "user",
        "message": "Do you have this in blue?",
        "count_as_reply": false,
        "manual_reply": false,
        "status": "sent",
        "rate": null,
        "sender_id": null
      },
      {
        "id": 50002,
        "created_at": "2026-01-15T10:30:08Z",
        "role": "assistant",
        "message": "Yes! The Classic Tee is available in blue.",
        "count_as_reply": true,
        "manual_reply": false,
        "status": "sent",
        "rate": "positive",
        "sender_id": null
      }
    ],
    "messages_pagination": {
      "page": 1,
      "per_page": 100,
      "total_count": 2,
      "total_pages": 1,
      "has_next_page": false
    }
  }
}
```

The `current_url` and `start_link` fields have the same meaning and nullable types as in the list response.

The show endpoint returns expanded lead details (including `first_name`, `last_name`, `shopify_customer_id`, and `additional_attributes`) compared to the list endpoint. The `assignee`, `last_escalated_at`, `last_escalation_resolved_at`, sentiment and `purchases` fields follow the same shape as on the list endpoint.

***

#### List Users

```
GET /chats/:chat_id/users
```

Returns the users (the chat owner and any chat participants) who can be assigned to a conversation on this chat.

**Parameters**

| Parameter  | Type    | Default | Description                |
| ---------- | ------- | ------- | -------------------------- |
| `page`     | integer | `1`     | Page number                |
| `per_page` | integer | `50`    | Items per page (max `100`) |

**Response**

```json
{
  "users": [
    {
      "id": 42,
      "name": "Stan Marsh",
      "email": "stan@example.com",
      "avatar_url": "https://app.zipchat.ai/rails/active_storage/blobs/redirect/.../avatar.png"
    }
  ],
  "pagination": {
    "page": 1,
    "per_page": 50,
    "total_count": 1,
    "total_pages": 1,
    "has_next_page": false
  }
}
```

`avatar_url` is `null` when the user has not uploaded an avatar.

***

#### Get User

```
GET /chats/:chat_id/users/:id
```

Returns a single user. Returns `404` if the user is not in the assignable set for this chat — the endpoint will never leak information about users from other chats.

**Response**

```json
{
  "user": {
    "id": 42,
    "name": "Stan Marsh",
    "email": "stan@example.com",
    "avatar_url": null
  }
}
```

***

#### Update Conversation Assignment

```
PATCH /chats/:chat_id/conversations/:id/assignment
```

Takes a conversation over from the AI (manual mode) or hands it back to the AI. This is a single atomic operation: setting `assignee_id` to a user puts the conversation into manual mode; setting it to `null` puts it back into AI mode and unassigns.

Use `GET /chats/:chat_id/users` to discover valid `assignee_id` values.

**Request body**

```json
{ "assignee_id": 42 }
```

Or, to hand back to the AI:

```json
{ "assignee_id": null }
```

**Response**

```json
{
  "conversation": {
    "id": 12345,
    "manual_reply_mode": true,
    "assignee": {
      "id": 42,
      "name": "Stan Marsh",
      "email": "stan@example.com",
      "avatar_url": null
    }
  }
}
```

**Errors**

| Status                     | Error message                                         | Cause                                                  |
| -------------------------- | ----------------------------------------------------- | ------------------------------------------------------ |
| `404 Not Found`            | `Conversation not found`                              | The conversation does not belong to this chat.         |
| `422 Unprocessable Entity` | `assignee_id is required (use null to assign to AI)`  | The body did not include `assignee_id`.                |
| `422 Unprocessable Entity` | `assignee_id is not an assignable user for this chat` | The given user is not the chat owner or a participant. |

***

#### Archive or Unarchive Conversation

```
PATCH /chats/:chat_id/conversations/:id/archive
```

Sets the same `archived` state as the dashboard's Archive/Unarchive action, including for conversations that were never escalated.

**Request body**

```json
{ "archived": true }
```

Send `false` to unarchive. The `archived` field is required and must be a JSON boolean; strings, numbers, null, arrays and objects are rejected. Repeating the same request preserves the state and does not advance `updated_at`.

**Response**

```json
{
  "conversation": {
    "id": 12345,
    "archived": true,
    "updated_at": "2026-01-15T11:30:00.123456Z"
  }
}
```

Archiving does not change `last_message_at`, escalation timestamps, assignment, or AI reply mode. Resolving an escalation does not archive a conversation. The internal conversation lifecycle's closed state is separate from the merchant's archive action and is not exposed by this API.

**Errors**

| Status                     | Error message                                     | Cause                                                            |
| -------------------------- | ------------------------------------------------- | ---------------------------------------------------------------- |
| `404 Not Found`            | `Conversation not found`                          | The conversation does not exist or does not belong to this chat. |
| `422 Unprocessable Entity` | `archived is required and must be a JSON boolean` | Missing or invalid `archived` value.                             |

Standard authentication and rate limits apply.

***

#### Escalate or Resolve Conversation

```
PATCH /chats/:chat_id/conversations/:id/escalation
```

Updates the conversation's escalation timestamps and `updated_at`. It does not archive the conversation, send notifications, or change its assignment.

**Request body**

```json
{ "resolved": false }
```

| Field      | Type    | Description                                                                                                                                                                                                                                                                                                            |
| ---------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `resolved` | boolean | Optional, defaults to `false`. When `false` (or omitted), **escalates**: sets `last_escalated_at` to now and clears `last_escalation_resolved_at` (so a previously resolved conversation is re-opened). When `true`, **resolves**: sets `last_escalation_resolved_at` to now and leaves `last_escalated_at` untouched. |

Sending no body escalates the conversation.

**Response**

The same shape for both operations:

```json
{
  "conversation": {
    "id": 12345,
    "currently_escalated": true,
    "last_escalated_at": "2026-01-15T11:10:00Z",
    "last_escalation_resolved_at": null
  }
}
```

`currently_escalated` is `true` when `last_escalated_at` is set and not yet resolved.

**Errors**

| Status          | Error message            | Cause                                          |
| --------------- | ------------------------ | ---------------------------------------------- |
| `404 Not Found` | `Conversation not found` | The conversation does not belong to this chat. |

***

#### Send Manual Message

```
POST /chats/:chat_id/conversations/:id/messages
```

Sends a manual reply from a human agent on a conversation that is currently in **manual mode**. The message is sent through whichever channel the conversation uses (web, email, WhatsApp, Instagram, Messenger).

You must take the conversation over first with `PATCH /conversations/:id/assignment` — sending while the conversation is still in AI mode returns `422`.

**Request body**

```json
{
  "message": "Hi! Happy to help with that.",
  "sender_id": 42
}
```

| Field       | Type    | Description                                                                                                   |
| ----------- | ------- | ------------------------------------------------------------------------------------------------------------- |
| `message`   | string  | The reply text. Required.                                                                                     |
| `sender_id` | integer | The user id that should be recorded as the sender. Must be a member of `GET /chats/:chat_id/users`. Required. |

**Response**

```json
{
  "message": {
    "id": 50003,
    "created_at": "2026-01-15T10:45:00Z",
    "role": "assistant",
    "message": "Hi! Happy to help with that.",
    "count_as_reply": false,
    "manual_reply": true,
    "status": "sent",
    "rate": null,
    "sender_id": 42
  }
}
```

**Errors**

| Status                     | Error message                                                                     | Cause                                                                                                              |
| -------------------------- | --------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| `404 Not Found`            | `Conversation not found`                                                          | The conversation does not belong to this chat.                                                                     |
| `422 Unprocessable Entity` | `message is required`                                                             | Empty or missing `message`.                                                                                        |
| `422 Unprocessable Entity` | `sender_id is required`                                                           | Missing `sender_id`.                                                                                               |
| `422 Unprocessable Entity` | `sender_id is not an assignable user for this chat`                               | Sender is not the chat owner or a participant.                                                                     |
| `422 Unprocessable Entity` | `Conversation is in AI mode; assign it to a user before sending a manual message` | Call the assignment endpoint first.                                                                                |
| `422 Unprocessable Entity` | `Cannot send: customer last messaged more than 24 hours ago on a Meta channel`    | WhatsApp / Instagram / Messenger enforce a 24-hour reply window from Meta. Wait for the customer to message again. |

***

#### Get Master Prompt

{% hint style="warning" %}
**Deprecated 2026-10-28.** Use [Rules](#rules) instead. An agent's instructions are now a set of rules, and this endpoint reads only one of them, the Additional instructions rule. It keeps working in v1.
{% endhint %}

```
GET /chats/:chat_id/prompt
```

Returns the chat's Additional instructions rule as `master_prompt`. `master_prompt` is `null` when the chat has no Additional instructions rule, even if other rules are turned on. This is common: new agents get their instructions as generated rules.

**Response**

```json
{
  "prompt": {
    "chat_id": 1,
    "master_prompt": "You are a helpful support assistant for Acme Co.",
    "master_prompt_max_length": 10000
  }
}
```

***

#### Update Master Prompt

{% hint style="warning" %}
**Deprecated 2026-10-28.** Use [Rules](#rules) instead. This endpoint replaces only the Additional instructions rule, and creates it when the chat has none. The chat's other rules stay as they are. It keeps working in v1.
{% endhint %}

```
PATCH /chats/:chat_id/prompt
```

Replaces the chat's Additional instructions rule, or creates it when the chat has none. The chat's other rules are not changed.

**Request body**

```json
{ "master_prompt": "You are a helpful support assistant for Acme Co." }
```

| Field           | Type   | Description                                                                                                                                                                                                        |
| --------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `master_prompt` | string | The new master prompt. Required. Leading/trailing whitespace is stripped. Must not exceed the chat's configured maximum length. The chat's other turned-on rules count toward the same `master_prompt_max_length`. |

**Response**

```json
{
  "prompt": {
    "chat_id": 1,
    "master_prompt": "You are a helpful support assistant for Acme Co.",
    "master_prompt_max_length": 10000
  }
}
```

**Errors**

| Status                     | Error message                                                                           | Cause                                                                                                                                                                                              |
| -------------------------- | --------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `403 Forbidden`            | `Your role does not allow configuration changes`                                        | User token belongs to a read-only (`member`-role) user.                                                                                                                                            |
| `422 Unprocessable Entity` | `master_prompt is required`                                                             | The body did not include `master_prompt`.                                                                                                                                                          |
| `422 Unprocessable Entity` | `master_prompt cannot be blank`                                                         | The value was `null`, empty, or whitespace-only. Blank values are rejected rather than silently erasing the prompt. To remove it, delete the Additional instructions rule through [Rules](#rules). |
| `422 Unprocessable Entity` | `master_prompt must be at most N characters long`                                       | The prompt exceeded `master_prompt_max_length`.                                                                                                                                                    |
| `422 Unprocessable Entity` | `Instructions can't take the turned-on rules past N characters. M characters are left.` | The new text plus the chat's other turned-on rules would exceed `master_prompt_max_length`.                                                                                                        |

***

#### Custom Tools (Skills)

Custom tools (labeled "skills" in the dashboard) are per-chat actions the AI can invoke.

**List**

```
GET /chats/:chat_id/custom_tools
```

Paginated (`page`, `per_page`, max `100`).

```json
{
  "custom_tools": [
    {
      "id": 12,
      "name": "Order lookup",
      "instructions": "Fetch orders from the API",
      "active": true,
      "channels": ["all channels"],
      "icon_id": null,
      "custom_tool_template_id": null,
      "variable_ids": [5, 7],
      "created_at": "2026-01-15T10:30:00Z",
      "updated_at": "2026-01-15T10:30:00Z"
    }
  ],
  "pagination": { "page": 1, "per_page": 50, "total_count": 1, "total_pages": 1, "has_next_page": false }
}
```

**Create**

```
POST /chats/:chat_id/custom_tools
```

```json
{
  "custom_tool": {
    "name": "Order lookup",
    "instructions": "Fetch orders from the API",
    "channels": ["all channels"],
    "active": true,
    "variable_ids": [5, 7]
  }
}
```

| Field          | Type    | Description                                                                                                                                                    |
| -------------- | ------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `name`         | string  | Required, max 255 chars.                                                                                                                                       |
| `instructions` | string  | Required, max 10000 chars.                                                                                                                                     |
| `channels`     | array   | Channels the tool is active on. When omitted, defaults to the template's install channels if `custom_tool_template_id` is given, otherwise `["all channels"]`. |
| `active`       | boolean | Optional, defaults to `true`.                                                                                                                                  |
| `variable_ids` | array   | Optional. IDs of existing pool variables to attach to this tool. Must be an array of ids (`422` otherwise).                                                    |

Returns `201` with the serialized custom tool. Validation failures return `422` with an `error` message — including an unknown `icon_id` or `custom_tool_template_id` (`icon_id does not exist` / `custom_tool_template_id does not exist`).

**Update**

```
PATCH /chats/:chat_id/custom_tools/:id
```

Same body shape as create (all fields optional; `custom_tool_template_id` is create-only and ignored here). `variable_ids`, when present, is the **full desired set** of attached variables: missing ones are attached and absent ones detached (detaching only removes the link — the pooled variable itself is untouched). Omit the key to leave attachments unchanged. Returns `200`, or `404` if the tool does not belong to this chat.

**Delete**

```
DELETE /chats/:chat_id/custom_tools/:id
```

Returns `204 No Content`, or `404` if the tool does not belong to this chat.

***

#### Variables

Variables are a per-chat pool of secrets (e.g. API keys) that custom tools reference. **Values are write-only** — they are encrypted at rest and never returned by the API; responses expose only a `has_value` flag.

**List**

```
GET /chats/:chat_id/variables
```

Paginated (`page`, `per_page`, max `100`).

```json
{
  "variables": [
    {
      "id": 5,
      "name": "API_KEY",
      "kind": "user",
      "has_value": true,
      "usage_count": 2,
      "custom_tool_ids": [12],
      "created_at": "2026-01-15T10:30:00Z",
      "updated_at": "2026-01-15T10:30:00Z"
    }
  ],
  "pagination": { "page": 1, "per_page": 50, "total_count": 1, "total_pages": 1, "has_next_page": false }
}
```

`kind` is `user` for normal variables or `managed_shopify` for the reserved, auto-managed `SHOPIFY_API_KEY`.

**Create**

```
POST /chats/:chat_id/variables
```

```json
{
  "skill_variable": {
    "name": "API_KEY",
    "value": "sk_live_...",
    "custom_tool_ids": [12]
  }
}
```

| Field             | Type   | Description                                                                                  |
| ----------------- | ------ | -------------------------------------------------------------------------------------------- |
| `name`            | string | Required. Uppercase letters, digits, and underscores only (e.g. `API_KEY`). Unique per chat. |
| `value`           | string | Required. Stored encrypted; never returned.                                                  |
| `custom_tool_ids` | array  | Optional. Custom tools to attach this variable to.                                           |

Returns `201`. Validation failures (bad name format, duplicate, reserved name) return `422`.

**Update**

```
PATCH /chats/:chat_id/variables/:id
```

Updates the value only. The change propagates to every custom tool the variable is attached to.

```json
{ "skill_variable": { "value": "sk_live_new..." } }
```

Returns `200`. Returns `422` if `value` is blank, `404` if the variable is not on this chat, or `422` when targeting the managed `SHOPIFY_API_KEY` (it cannot be edited via the API).

**Delete**

```
DELETE /chats/:chat_id/variables/:id
```

Returns `204 No Content`. Returns `404` if the variable is not on this chat, or `422` for the managed `SHOPIFY_API_KEY` (it cannot be deleted).

***

#### Rules

Rules are the agent's named instructions. Every turned-on rule available on a conversation's channel goes into the AI's prompt, in ID order. `kind` is `custom` for a rule the merchant wrote, `generated` for one onboarding research wrote, or `additional_instructions` for the chat's one Additional instructions rule. That is the rule the deprecated [/prompt endpoints](#get-master-prompt) read and write. `kind` is never writable.

The `instructions` of all turned-on rules together must fit in `master_prompt_max_length`. A single rule is capped at `instructions_max_length`: 2,000 characters, or the chat's whole limit for the Additional instructions rule.

**List**

```
GET /chats/:chat_id/rules
```

Paginated (`page`, `per_page`, max `100`). `active_instructions_length` is the total length of the turned-on rules' instructions, so `master_prompt_max_length - active_instructions_length` is what is left.

```json
{
  "rules": [
    {
      "id": 31,
      "name": "Returns",
      "instructions": "Returns are free within 30 days.",
      "channels": ["all channels"],
      "active": true,
      "kind": "custom",
      "instructions_max_length": 2000,
      "created_at": "2026-01-15T10:30:00Z",
      "updated_at": "2026-01-15T10:30:00Z"
    }
  ],
  "active_instructions_length": 32,
  "master_prompt_max_length": 10000,
  "pagination": { "page": 1, "per_page": 50, "total_count": 1, "total_pages": 1, "has_next_page": false }
}
```

**Create**

```
POST /chats/:chat_id/rules
```

```json
{
  "rule": {
    "name": "Returns",
    "instructions": "Returns are free within 30 days.",
    "channels": ["all channels"],
    "active": true
  }
}
```

| Field          | Type    | Description                                                   |
| -------------- | ------- | ------------------------------------------------------------- |
| `name`         | string  | Required, max 255 chars.                                      |
| `instructions` | string  | Required, max `instructions_max_length`.                      |
| `channels`     | array   | Channels the rule applies on. Defaults to `["all channels"]`. |
| `active`       | boolean | Optional, defaults to `true`.                                 |

Creates a `custom` rule and returns `201` with the serialized rule.

**Update**

```
PATCH /chats/:chat_id/rules/:id
```

Same body shape as create, every field optional. An omitted `channels` key is left as it is. Updating a `generated` rule turns it `custom`, so a later onboarding run keeps it. The Additional instructions rule keeps its kind. Returns `200` with the serialized rule.

**Delete**

```
DELETE /chats/:chat_id/rules/:id
```

Returns `204 No Content`. Deleting the Additional instructions rule clears the master prompt, so [Get Master Prompt](#get-master-prompt) then returns `null`.

**Errors**

| Status                     | Error message                                                                                                                | Cause                                                                                                    |
| -------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- |
| `403 Forbidden`            | `Your role does not allow configuration changes`                                                                             | User token belongs to a read-only (`member`-role) user.                                                  |
| `404 Not Found`            | `Rule not found`                                                                                                             | The rule does not belong to this chat.                                                                   |
| `422 Unprocessable Entity` | `Name can't be blank`, `Instructions can't be longer than 2,000 characters. Shorten them or split them into two rules.`, ... | A validation failed. Messages are joined into one sentence.                                              |
| `422 Unprocessable Entity` | `Instructions can't take the turned-on rules past 10,000 characters. 120 characters are left.`                               | Creating, editing or turning on the rule would take the turned-on total past `master_prompt_max_length`. |

### Rate Limiting

The API allows **120 requests per 60-second window** per credential (per chat integration for chat tokens, per user for user tokens).

Every response includes rate limit headers:

| Header                  | Description                              |
| ----------------------- | ---------------------------------------- |
| `X-RateLimit-Limit`     | Maximum requests per window (`120`)      |
| `X-RateLimit-Remaining` | Requests remaining in the current window |
| `X-RateLimit-Reset`     | Unix timestamp when the window resets    |

When the limit is exceeded, the API returns `429 Too Many Requests`.

### Error Codes

| Status                     | Description                                                                                     |
| -------------------------- | ----------------------------------------------------------------------------------------------- |
| `401 Unauthorized`         | Missing or invalid API key                                                                      |
| `403 Forbidden`            | User token's role does not allow configuration changes (prompt, rules, custom tools, variables) |
| `404 Not Found`            | Conversation, user, rule, custom tool, or variable not found                                    |
| `422 Unprocessable Entity` | Invalid parameter (e.g., malformed timestamp, missing field, ineligible assignee)               |
| `429 Too Many Requests`    | Rate limit exceeded                                                                             |

### Examples

#### Discover your chats with a user token

```bash
curl -H "Authorization: Bearer zcu-your_user_token" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats"
```

#### List rules, then add one

```bash
# 1. List the rules; master_prompt_max_length - active_instructions_length is the room left
curl -H "Authorization: Bearer zcu-your_user_token" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/rules"

# 2. Add a rule
curl -X POST \
  -H "Authorization: Bearer zcu-your_user_token" \
  -H "Content-Type: application/json" \
  -d '{"rule": {"name": "Returns", "instructions": "Always mention our 30-day return policy.", "channels": ["all channels"]}}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/rules"
```

#### Create a custom tool with a secret variable

```bash
# 1. Create the variable (value is write-only; it is never returned)
curl -X POST \
  -H "Authorization: Bearer zcu-your_user_token" \
  -H "Content-Type: application/json" \
  -d '{"skill_variable": {"name": "ORDERS_API_KEY", "value": "sk_live_..."}}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/variables"

# 2. Create the tool and attach the variable (use the id from step 1)
curl -X POST \
  -H "Authorization: Bearer zcu-your_user_token" \
  -H "Content-Type: application/json" \
  -d '{"custom_tool": {"name": "Order lookup", "instructions": "Call GET https://api.example.com/orders/{id} with the ORDERS_API_KEY header...", "variable_ids": [5]}}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/custom_tools"
```

#### Copy a custom tool to another chat

```bash
# 1. List tools on the source chat, pick the one to copy
curl -H "Authorization: Bearer zcu-your_user_token" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/custom_tools"

# 2. POST its name/instructions/channels to the destination chat
curl -X POST \
  -H "Authorization: Bearer zcu-your_user_token" \
  -H "Content-Type: application/json" \
  -d '{"custom_tool": {"name": "Order lookup", "instructions": "...", "channels": ["all channels"]}}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/2/custom_tools"
```

#### Fetch the latest conversations

```bash
curl -H "Authorization: Bearer zc-your_api_key" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations"
```

#### Fetch conversations with new message activity since a timestamp

```bash
curl -H "Authorization: Bearer zc-your_api_key" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations?last_message_at_since=2026-01-15T09:30:00Z"
```

#### Fetch a single conversation with messages

```bash
curl -H "Authorization: Bearer zc-your_api_key" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations/12345"
```

#### Paginate through messages

```bash
curl -H "Authorization: Bearer zc-your_api_key" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations/12345?message_page=2&message_per_page=50"
```

#### Take over a conversation, reply, and hand it back to the AI

```bash
# 1. Take the conversation over and assign it to user 42
curl -X PATCH \
  -H "Authorization: Bearer zc-your_api_key" \
  -H "Content-Type: application/json" \
  -d '{"assignee_id": 42}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations/12345/assignment"

# 2. Send a manual reply on behalf of user 42
curl -X POST \
  -H "Authorization: Bearer zc-your_api_key" \
  -H "Content-Type: application/json" \
  -d '{"message": "Hi! Happy to help.", "sender_id": 42}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations/12345/messages"

# 3. Hand the conversation back to the AI
curl -X PATCH \
  -H "Authorization: Bearer zc-your_api_key" \
  -H "Content-Type: application/json" \
  -d '{"assignee_id": null}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations/12345/assignment"
```

#### Escalate, then resolve a conversation

```bash
# Escalate (no body needed)
curl -X PATCH \
  -H "Authorization: Bearer zc-your_api_key" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations/12345/escalation"

# Resolve the escalation
curl -X PATCH \
  -H "Authorization: Bearer zc-your_api_key" \
  -H "Content-Type: application/json" \
  -d '{"resolved": true}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations/12345/escalation"
```

#### Archive and sync status changes

```bash
# Archive; send {"archived": false} to unarchive.
curl -X PATCH \
  -H "Authorization: Bearer zc-your_api_key" \
  -H "Content-Type: application/json" \
  -d '{"archived": true}' \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations/12345/archive"

# Poll changes, including status-only updates. Follow pagination for all results.
curl --get \
  -H "Authorization: Bearer zc-your_api_key" \
  --data-urlencode "updated_at_since=2026-01-15T11:00:00.000000Z" \
  "https://app.zipchat.ai/api/integrations/backend_api/v1/chats/1/conversations"
```


# Account Management

The **Account Management** section is where you handle key account settings, including managing your AI Chatbots, adding/removing team members, and managing your account billing.&#x20;

This section ensures you have full control over your account details, keeping your information secure and up to date. 🚀


# Manage AI Agents

The **AI Agent** section in Zipchat AI lets you create and manage multiple AI Agents, each functioning as a standalone chatbot. This feature is ideal for businesses with multiple websites, stores, or distinct customer audiences, ensuring every chatbot is tailored to its specific environment.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FINoTq8x3Em4j3FQblmvk%2FScreenshot%202024-11-23%20at%2018.46.01.png?alt=media&amp;token=486339fc-6ee1-4174-bcaa-86f259821b5f" alt=""><figcaption></figcaption></figure>

### **Key Features**

1. **Create Additional AI Agents**
   * Easily add new AI Agents, each acting as an independent chatbot.
   * Customize each agent’s behavior, tone, and responses to fit the needs of its audience or platform.
2. **Dedicated Training and Knowledge Base**
   * Each AI Agent has its own separate training and knowledge base.
   * Equip each chatbot with relevant information, such as product details or brand-specific messaging, for optimal performance.
3. **Custom Installation**
   * Install different AI Agents on specific websites or stores.
   * Tailor each chatbot to the unique content, objectives, and user expectations of its platform.
4. **Tailored Customer Interactions**
   * Align each chatbot with the brand it represents.
   * Example: Use a formal tone and styling advice for a luxury fashion store and a technical focus for a gadget shop.
5. **Manage AI Agents**
   * Switch between AI Agents for updates or monitoring.
   * Delete agents no longer needed to keep your setup streamlined.

***

### **Why Use Multiple AI Agents?**

* **Flexibility**: Serve multiple domains or brands with chatbots tailored to each audience.
* **Accuracy**: Ensure responses are relevant and aligned with specific content.
* **Improved Engagement**: Deliver personalized interactions that resonate with each customer group.

***

The **AI Agent** section gives you the tools to build a network of smart, specialized chatbots that enhance customer interactions across all your platforms. 🚀


# Manage Subscription

The **Subscription** section lets you manage your Zipchat AI plan with ease, ensuring it aligns with your business needs as they evolve. From upgrades to cancellations, this section puts you in control.

***

#### **Key Features**

1. **Upgrade Your Plan**
   * Scale up as your business grows with more features, AI Agents, or higher interaction limits.
   * Access advanced tools and support to meet expanding requirements.
2. **Downgrade Your Plan**
   * Adjust to a smaller plan if your current usage decreases or budget changes.
   * Ensure you’re paying only for what you need.
3. **Cancel Your Subscription**
   * Stop using Zipchat AI by deleting your subscription.
   * Access will remain active until the end of your billing period.
4. **Manage Billing Information**
   * Update payment methods or review your billing history.
   * Ensure your account remains in good standing for uninterrupted service.
5. **Compare Plan Features**
   * View detailed information about each plan’s limits, features, and support options.
   * Make informed decisions when upgrading, downgrading, or maintaining your subscription.


# Members

The **Members** section lets you invite team members to collaborate on managing your AI Agents, with customizable roles and permissions to ensure efficient teamwork and secure access.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FsU55dEb2yRw75dHu4CCN%2FScreenshot%202024-11-23%20at%2018.47.31.png?alt=media&amp;token=39d3f096-d168-4012-acd8-a8a191ab5916" alt=""><figcaption></figcaption></figure>

### **Key Features**

1. **Invite Team Members**
   * Easily invite colleagues to join your Zipchat account.
   * Assign roles tailored to their responsibilities, enabling collaboration across support, marketing, IT, and more.
2. **Role-Based Permissions**
   * **Editors**:
     * **Access**: Almost full control over AI Agents, including managing settings, reading messages, and optimizing chatbot training.
     * **Limitations**: Cannot create/delete AI Agents, manage subscriptions, or add/remove members.
     * **Best For**: Team members responsible for chatbot management and configurations.
   * **Members**:
     * **Access**: Can read conversations and create corrections to refine chatbot responses.
     * **Limitations**: Cannot modify settings, manage training, or perform administrative tasks.
     * **Best For**: Team members who monitor and improve chatbot interactions without needing full control.

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2F4GdU7D4CQC9GNNLKlWSE%2FScreenshot%202024-11-23%20at%2018.47.48.png?alt=media&amp;token=9f27e2b3-456c-4ea3-92f4-10510641c08d" alt=""><figcaption></figcaption></figure>


# Zapier Integration API Documentation

### Overview

This documentation describes the API for integrating with Zapier. The integration allows you to send lead information collected from your chats to Zapier, which can then be used to trigger actions in other platforms.

### Authentication

All API requests require authentication using a chat ID and an API key.

* **chat\_id**: The unique identifier for your chat
* **api\_key**: A unique API key generated for the Zapier integration

Authentication parameters should be included in all API requests as query parameters.

Example:

```
https://your-api-domain.com/api/integrations/zapier/test_connection?chat_id=123&api_key=zc-a1b2c3d4e5f6...
```

### Endpoints

#### Test Connection

Used to verify that the authentication credentials are valid.

* **URL**: `/api/integrations/zapier/test_connection`
* **Method**: `GET`
* **Authentication Required**: Yes
* **Query Parameters**:
  * `chat_id`: Your chat ID
  * `api_key`: Your Zapier integration API key

**Successful Response**

```json
{
  "message": "Connection successful"
}
```

Status Code: 200 OK

#### Create Webhook Endpoint

Used to register a webhook URL where lead data will be sent.

* **URL**: `/api/integrations/zapier/create_endpoint`
* **Method**: `POST`
* **Authentication Required**: Yes
* **Query Parameters**:
  * `chat_id`: Your chat ID
  * `api_key`: Your Zapier integration API key
* **Request Body**:

  ```json
  {
    "hookUrl": "https://hooks.zapier.com/hooks/catch/123456/abcdef/"
  }
  ```

**Successful Response**

```json
{
  "message": "Endpoint created"
}
```

Status Code: 200 OK

**Error Responses**

```json
{
  "message": "Endpoint creation failed"
}
```

Status Code: 422 Unprocessable Entity

```json
{
  "message": "Invalid body"
}
```

Status Code: 422 Unprocessable Entity

#### Delete Webhook Endpoint

Used to delete a registered webhook URL.

* **URL**: `/api/integrations/zapier/destroy_endpoint`
* **Method**: `DELETE` (or `POST` depending on your implementation)
* **Authentication Required**: Yes
* **Query Parameters**:
  * `chat_id`: Your chat ID
  * `api_key`: Your Zapier integration API key
* **Request Body**:

  ```json
  {
    "hookUrl": "https://hooks.zapier.com/hooks/catch/123456/abcdef/"
  }
  ```

**Successful Response**

```json
{
  "message": "Endpoint destroyed"
}
```

Status Code: 200 OK

**Error Response**

```json
{
  "message": "Endpoint not found"
}
```

Status Code: 422 Unprocessable Entity

### Webhook Payloads

When a new lead is created in the system, a webhook notification is sent to all registered Zapier endpoints.

#### Lead Created Event

This webhook is triggered when a new lead is created.

**Payload**

```json
{
  "email_address": "example@email.com",
  "phone_number": "1234567890",
  "channel": "email" or "whatsapp",
  "marketing_consent": true or false
}
```

* **email\_address**: The lead's email address (if available)
* **phone\_number**: The lead's phone number (if available)
* **channel**: The channel through which the lead was acquired (either "email" or "whatsapp")
* **marketing\_consent**: Whether the lead has provided consent for marketing communications

### Error Handling

#### Authentication Errors

If the provided chat\_id and api\_key combination is invalid or not found:

```json
{
  "message": "Unauthorized"
}
```

Status Code: 401 Unauthorized

#### Validation Errors

If the request body is invalid or missing required fields:

```json
{
  "message": "Invalid body"
}
```

Status Code: 422 Unprocessable Entity

### Best Practices

1. Store the webhook URL securely
2. Implement appropriate error handling in your Zapier workflows
3. Consider adding retry logic for failed webhook deliveries
4. Monitor webhook delivery success rates
5. Respect marketing consent flags when using lead data for marketing purposes


# Ask API

Send your customers' questions from your backend and get your Zipchat AI agent's answer in the response.

Send a customer's question from your backend and get your Zipchat AI agent's answer in the response. Use it to put the agent in your own app, help center or chat UI.

The agent answers with the same instructions, knowledge, skills and tools it uses on your other channels. Each customer's questions and the agent's answers are saved as one conversation in Zipchat, where your team can read it and follow up by email.

{% hint style="danger" %}
Call the API from your server. Never put an API key in a browser, mobile app or anything a customer can download: anyone holding it can run billable answers.
{% endhint %}

### Get an API key

1. In Zipchat, open **Channels** and set up **API**.
2. Name and create an API key. Copy it right away: it is shown only once.
3. Send your first question. The API channel goes Live with it.

To create more keys, revoke one, or disconnect the channel, open **Manage** on the API channel. Its **Send a question** tab shows the endpoint and a sample request.

### Authentication

Send the API key as a Bearer token in the `Authorization` header:

```
Authorization: Bearer zca-your_api_key
```

API keys start with `zca-` and belong to one chat. The key tells Zipchat which chat you're asking, so the request doesn't name it.

An API key can only ask questions. It can't read your conversations or change your agent's instructions, skills or tools. It can ask on behalf of any customer, though, and a question for a [verified customer](#who-verifies-a-customer) is answered from that customer's orders. Give keys only to backends you trust with that data.

| Response | When                                                                                       |
| -------- | ------------------------------------------------------------------------------------------ |
| `401`    | The key is missing, invalid or revoked.                                                    |
| `403`    | The key was used on an endpoint other than Ask, or the chat's API channel is disconnected. |

### Ask a question

```
POST https://app.zipchat.ai/api/v1/ask
```

Sends a customer's question to your AI agent and waits for the answer, up to 20 seconds. The question continues that customer's current conversation. Send `Content-Type: application/json`, with a body of up to 32 KB.

| Field                     | Type             | Required | Description                                                                                                                                                                                                                                                                    |
| ------------------------- | ---------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `message`                 | string           | yes      | The customer's question, up to 4,000 characters.                                                                                                                                                                                                                               |
| `customer`                | object           | yes      | Who is asking. Send the same values on every question from this customer. See [Customers and conversations](#customers-and-conversations).                                                                                                                                     |
| `customer.id`             | string           | yes      | Your ID for this customer: their account ID when they are logged in, or a guest or session ID when they aren't. Up to 64 characters.                                                                                                                                           |
| `customer.email`          | string           | no       | The customer's email. Sending it alone does not verify it.                                                                                                                                                                                                                     |
| `customer.email_verified` | boolean          | no       | Defaults to `false`. Set `true` only when your backend authenticated this customer and got the email from their account. It lets the agent look up their orders and remember earlier conversations. Requires `email`. See [Who verifies a customer](#who-verifies-a-customer). |
| `customer.name`           | string           | no       | Display name for the customer's profile in Zipchat, up to 200 characters.                                                                                                                                                                                                      |
| `context`                 | string or object | no       | Background for this question, such as the page the customer is on or their cart, up to 8 KB. The agent reads it, but it can't override your instructions. Don't put secrets in it.                                                                                             |
| `stream`                  | boolean          | no       | Defaults to `false`. Set `true` to get the answer while it's written. See [Streaming](#streaming).                                                                                                                                                                             |

Unknown fields are rejected with `parameter_unknown`. Every request is a new question: sending the same request twice asks twice.

{% tabs %}
{% tab title="cURL" %}

```bash
curl https://app.zipchat.ai/api/v1/ask \
  -H "Authorization: Bearer $ZIPCHAT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "Where is my order?",
    "customer": {
      "id": "cus_1042",
      "email": "jane@example.com",
      "email_verified": true,
      "name": "Jane Doe"
    },
    "context": { "page": "https://acme.com/account/orders" }
  }'
```

{% endtab %}

{% tab title="Node.js" %}

```javascript
const res = await fetch(
  "https://app.zipchat.ai/api/v1/ask",
  {
    method: "POST",
    headers: {
      Authorization: `Bearer ${process.env.ZIPCHAT_API_KEY}`,
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      message: "Where is my order?",
      customer: { id: "cus_1042", email: "jane@example.com", email_verified: true },
      context: { page: "https://acme.com/account/orders" },
    }),
  },
);
const data = await res.json();

if (data.status === "answered") console.log(data.answer.text);
```

{% endtab %}

{% tab title="Python" %}

```python
import os
import requests

res = requests.post(
    "https://app.zipchat.ai/api/v1/ask",
    headers={"Authorization": f"Bearer {os.environ['ZIPCHAT_API_KEY']}"},
    json={
        "message": "Where is my order?",
        "customer": {"id": "cus_1042", "email": "jane@example.com", "email_verified": True},
        "context": {"page": "https://acme.com/account/orders"},
    },
    timeout=30,
)
data = res.json()

if data["status"] == "answered":
    print(data["answer"]["text"])
```

{% endtab %}
{% endtabs %}

### The response

A `200` response says how the question was handled. Every field is always present, and is `null` when it doesn't apply.

```json
{
  "status": "answered",
  "reason": null,
  "conversation_id": 12345,
  "escalated": false,
  "question": { "message_id": 50001 },
  "answer": {
    "message_id": 50002,
    "text": "Your order shipped yesterday. Track it at https://acme.com/tracking/1042?zc_ref=zc_abc123",
    "sources": [
      {
        "url": "https://acme.com/pages/shipping?zc_ref=zc_abc123",
        "title": "Shipping policy",
        "description": "Delivery times and costs",
        "image_url": null
      }
    ]
  }
}
```

| Field                 | Description                                                                                                                                                                                                                         |
| --------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `status`              | How the question was handled: `answered`, `no_reply` or `blocked` (below).                                                                                                                                                          |
| `reason`              | For `blocked`: `{code, message}`.                                                                                                                                                                                                   |
| `conversation_id`     | The Zipchat conversation the question was saved in.                                                                                                                                                                                 |
| `escalated`           | Whether the conversation was escalated to your team when the question was handled. See [Escalations](#escalations).                                                                                                                 |
| `question.message_id` | The saved question.                                                                                                                                                                                                                 |
| `answer`              | Only when `status` is `answered`: `message_id`, `text` and `sources`.                                                                                                                                                               |
| `answer.text`         | Plain text with line breaks and bare URLs. HTML and Markdown are already removed. Render it as text, never as HTML.                                                                                                                 |
| `answer.sources`      | The pages and products the answer links to, in order, for rendering as cards. Each has `url` and nullable `title`, `description` and `image_url`. URLs carry attribution parameters, so purchases are credited to the conversation. |

| `status`   | What to show                                                                                                                                                                                                                           |
| ---------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `answered` | `answer.text` and `answer.sources`.                                                                                                                                                                                                    |
| `no_reply` | Nothing. The agent chose not to reply.                                                                                                                                                                                                 |
| `blocked`  | Your own fallback. A limit stopped the answer, and `reason.code` says which: `quota_exceeded` (your AI replies are used up), `customer_reply_limit_reached` (this customer reached the reply limit set for the chat) or `ai_disabled`. |

When the AI fails or takes longer than 20 seconds, you get an error instead: `502 generation_failed` or `504 timeout`. The question is saved either way. New `status` and `reason.code` values may be added, so treat unknown ones like `blocked`.

### Streaming

Add `"stream": true` to the request body to get the answer while it's written, the way Zipchat's chat bubble shows it. Everything else about the request stays the same: the endpoint, the API key and the other fields.

The response is then `200` with `Content-Type: text/event-stream`: [server-sent events](https://html.spec.whatwg.org/multipage/server-sent-events.html). Each event is an `event:` line with its name and a `data:` line with a JSON object whose `type` repeats that name. A blank line ends each event.

```
event: question.saved
data: {"type":"question.saved","conversation_id":12345,"question":{"message_id":50001}}

event: answer.delta
data: {"type":"answer.delta","delta":"Let me check your order."}

event: answer.delta
data: {"type":"answer.delta","delta":"\n\nYour order **shipped** yesterday"}

event: answer.delta
data: {"type":"answer.delta","delta":". Track it at https://acme.com/tracking/1042"}

event: response.completed
data: {"type":"response.completed","response":{"status":"answered","reason":null,"conversation_id":12345,"escalated":false,"question":{"message_id":50001},"answer":{"message_id":50002,"text":"Your order shipped yesterday. Track it at https://acme.com/tracking/1042?zc_ref=zc_abc123","sources":[]}}}
```

#### Events

| Event                | When                                                                                        | Data                                                                        |
| -------------------- | ------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------- |
| `question.saved`     | First, as soon as the question is saved.                                                    | `conversation_id` and `question.message_id`.                                |
| `answer.delta`       | While the agent writes. Any number of times, or none.                                       | `delta`: the text added since the previous one.                             |
| `response.completed` | Last, once the question is handled.                                                         | `response`: the same body as a [response](#the-response) without streaming. |
| `error`              | Last, instead of `response.completed`, if the answer fails or takes longer than 20 seconds. | `error`: `{type, code, message, param}`, as in [Errors](#errors).           |

#### The deltas are a preview

Show the deltas as they arrive, then replace them with `response.answer.text` and its `sources` from `response.completed`, as Zipchat's chat bubble does. The two can differ:

* The deltas are the agent's raw text and can contain Markdown. The final text is plain text, with made-up links removed.
* Text the agent writes before it looks something up ("Let me check your order.") streams too, followed by a blank line, but it isn't part of the final answer.
* A `no_reply` may still have streamed some text. Follow `response.status`, as for any [response](#the-response).

{% hint style="info" %}
Product cards (`sources`) arrive only with `response.completed`, once they're checked. There are no events for the agent's intermediate steps.
{% endhint %}

#### Errors in a stream

Errors found before the stream starts, such as an invalid key, invalid input, a disconnected API channel or a `429`, are ordinary JSON [error responses](#errors) with their status code. Check the `Content-Type` before you read the stream.

Once `question.saved` is sent, the status is already `200`, so a later failure arrives as an `error` event. Drop the preview and treat it like the matching error response: the question is saved, and the answer or a tool action may already have happened, so [don't resend it automatically](#timeouts-and-retries).

The 20-second limit and the [rate limits](#rate-limits) are the same as without streaming. If you disconnect, the question is still answered and saved.

#### Relay the stream to your customers

Your API key stays on your server, so read the stream in your backend and pass the deltas and the final answer on to the customer's browser over your own connection.

{% tabs %}
{% tab title="cURL" %}

```bash
curl -N https://app.zipchat.ai/api/v1/ask \
  -H "Authorization: Bearer $ZIPCHAT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "Where is my order?",
    "customer": { "id": "cus_1042" },
    "stream": true
  }'
```

{% endtab %}

{% tab title="Node.js" %}

```javascript
const res = await fetch(
  "https://app.zipchat.ai/api/v1/ask",
  {
    method: "POST",
    headers: {
      Authorization: `Bearer ${process.env.ZIPCHAT_API_KEY}`,
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      message: "Where is my order?",
      customer: { id: "cus_1042" },
      stream: true,
    }),
  },
);
// Errors found before the stream starts are JSON.
if (!res.headers.get("content-type").startsWith("text/event-stream")) {
  throw new Error((await res.json()).error.message);
}

const decoder = new TextDecoder();
let buffer = "";
let preview = "";
for await (const chunk of res.body) {
  buffer += decoder.decode(chunk, { stream: true });
  let end;
  while ((end = buffer.indexOf("\n\n")) !== -1) {
    const lines = buffer.slice(0, end).split("\n");
    buffer = buffer.slice(end + 2);
    const data = JSON.parse(lines.find((line) => line.startsWith("data: ")).slice(6));

    if (data.type === "answer.delta") showPreview((preview += data.delta));
    if (data.type === "response.completed") showFinal(data.response);
    if (data.type === "error") showError(data.error);
  }
}
```

{% endtab %}

{% tab title="Python" %}

```python
import json
import os
import requests

with requests.post(
    "https://app.zipchat.ai/api/v1/ask",
    headers={"Authorization": f"Bearer {os.environ['ZIPCHAT_API_KEY']}"},
    json={"message": "Where is my order?", "customer": {"id": "cus_1042"}, "stream": True},
    stream=True,
    timeout=30,
) as res:
    # Errors found before the stream starts are JSON.
    if not res.headers["Content-Type"].startswith("text/event-stream"):
        raise RuntimeError(res.json()["error"]["message"])

    preview = ""
    for line in res.iter_lines(decode_unicode=True):
        if not line.startswith("data: "):
            continue
        data = json.loads(line[6:])
        if data["type"] == "answer.delta":
            preview += data["delta"]
            show_preview(preview)
        elif data["type"] == "response.completed":
            show_final(data["response"])
        elif data["type"] == "error":
            show_error(data["error"])
```

{% endtab %}
{% endtabs %}

### Customers and conversations

Each customer's questions continue their current conversation. A conversation closes after about 24 hours without messages, and the next question starts a new one.

A conversation belongs to one identity: `customer.id`, `customer.email` and `customer.email_verified` together. When any of them changes, the next question starts a new conversation, so one person never sees another's history, even on a shared device.

| Situation                    | What to send                                       | Result                                                                        |
| ---------------------------- | -------------------------------------------------- | ----------------------------------------------------------------------------- |
| Guest browsing               | `id` = your session ID                             | Answers from your store's content. No order lookups.                          |
| Guest gives an email in chat | Add `email`                                        | New conversation, linked to that contact. Still unverified.                   |
| Customer logs in             | `id` = account ID, `email`, `email_verified: true` | New conversation. The agent can look up their orders and remember past chats. |
| Customer logs out            | Back to the guest values                           | New conversation. Their history stays private.                                |

#### Who verifies a customer

You do. Zipchat can't check `email_verified`: it trusts your backend's word that your own login authenticated this customer and that the email comes from their account.

{% hint style="danger" %}
Set `email_verified: true` only from your own logged-in session, never from an email the customer typed. Anyone holding an API key can send `email_verified: true` with any address and get answers from that customer's orders and past conversations.
{% endhint %}

### Escalations

When a customer asks for a person, the agent forwards the request to your support team. It asks for the customer's email first, and tells them to expect a reply by email. The response's `escalated` turns `true`.

Your team answers by email, never through the API. You don't need to poll for replies or receive webhooks: the API only ever returns the agent's answers.

* The agent keeps answering the customer's new questions after an escalation, so your chat UI works as before.
* Show the agent's answer as usual. It already tells the customer that the team will email them.
* If you know the customer's email, send it in `customer.email` so the agent doesn't have to ask for it.

### Errors

A `4xx` or `5xx` response always carries an error. Branch on `error.type` and `error.code`, never on `message`. `param` names the request field at fault, with dots for nested fields.

```json
{
  "error": {
    "type": "invalid_request_error",
    "code": "parameter_invalid",
    "message": "customer.email must be a valid email of at most 254 characters",
    "param": "customer.email"
  }
}
```

Every response, success or error, has a `request-id` header. Include it when you contact support about a request.

| HTTP | `type`                  | `code`                                                        | Meaning                                                                                                                   |
| ---- | ----------------------- | ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
| 400  | `invalid_request_error` | `malformed_json`                                              | The body isn't valid JSON.                                                                                                |
| 401  | `authentication_error`  | `invalid_token`                                               | The key is missing, invalid or revoked.                                                                                   |
| 403  | `permission_error`      | `api_channel_disconnected`                                    | The chat's API channel is disconnected.                                                                                   |
| 413  | `invalid_request_error` | `body_too_large`                                              | The body is over 32 KB.                                                                                                   |
| 415  | `invalid_request_error` | `unsupported_content_type`                                    | The request isn't `application/json`.                                                                                     |
| 422  | `invalid_request_error` | `parameter_missing`, `parameter_invalid`, `parameter_unknown` | A body field is missing, invalid or not part of the API. `param` names it.                                                |
| 429  | `rate_limit_error`      | `rate_limit_exceeded`, `concurrent_ask_limit`                 | Too many requests, or the same customer's previous question is still running. See [Rate limits](#rate-limits).            |
| 500  | `api_error`             | `internal_error`                                              | Something failed on Zipchat's side. The question may already be saved.                                                    |
| 502  | `api_error`             | `generation_failed`                                           | The AI couldn't generate an answer. The question is saved in the conversation.                                            |
| 504  | `api_error`             | `timeout`                                                     | The answer took longer than 20 seconds. The question is saved, and the answer or a tool action may already have happened. |

Don't retry a `403`. Retry a `429` after `Retry-After`: nothing was saved. After a `500`, `502` or `504`, or a response that isn't JSON, the question may already be saved, so [don't resend it automatically](#timeouts-and-retries). New codes may be added, so handle unknown ones by their `type`.

### Rate limits

Each API key has its own limits. Every `429` response includes a `Retry-After` header in seconds.

| Limit                     | Value                  | Error code             |
| ------------------------- | ---------------------- | ---------------------- |
| Questions                 | 300 per minute per key | `rate_limit_exceeded`  |
| Questions running at once | 1 per customer         | `concurrent_ask_limit` |

Each customer has one question at a time. A second question from the same `customer.id`, or with the same `email`, while the first is being answered gets `429 concurrent_ask_limit`. Different customers are answered in parallel.

Both come with `Retry-After: 2`, and nothing is saved, so retry the same question with backoff and some jitter.

### Timeouts and retries

An answer takes a few seconds, and Zipchat stops waiting for it after 20 seconds. Set your HTTP client timeout to about 30 seconds.

Every request is a new question. If you send the same request twice, the customer's question is asked twice: two questions in the conversation, two AI replies, and any tool action twice.

A timeout doesn't mean nothing happened. The question and its answer may already be saved, or a tool may already have sent an email or created a discount. So:

* **Don't resend automatically** after a `504 timeout`, a `502`, a `500`, an `error` event in a stream, a dropped connection, or a response that isn't JSON. The question is saved and the answer may be too. Show the customer that something went wrong and let them ask again.
* **Do retry a `429`** after `Retry-After`. Nothing was saved, so it can't double up.


# Zipchat Customer Identification Integration (Non-Shopify stores)

### Customer Identification - JWT Authentication

#### Overview

The Customer Identification feature allows Zipchat to identify authenticated users on your website. This enables the AI assistant to:

* Know more about the user (name, email, additional attributes)
* Provide user-specific information (e.g., order tracking) without requiring email collection
* Automatically associate leads with conversations
* Skip lead collection forms for verified users

**Note**: This feature is only available for non-Shopify integrations. Shopify stores have their own built-in user identification mechanism.

#### How It Works

1. Customer logs into your website
2. Your backend generates a JWT token containing user information, signed with your private key
3. Your frontend receives the JWT token (via API, rendered in HTML, or stored in a hidden element)
4. When the Zipchat widget is ready, it dispatches a `zipchat:ready-to-identify` event
5. Your frontend calls `Zipchat.identify(jwt)` with the token
6. Zipchat verifies the JWT signature using your public key and associates the user with the conversation
7. The success is cached in localStorage to prevent duplicate requests for 1 hour

#### Activation

**Step 1: Enable the Feature**

1. Navigate to your chat's **Integrations** page
2. Find the "Customer identification" section
3. Click the **Activate** button to enable customer identification

Once activated, you'll receive:

* A **Private Key** (RSA) - Use this to sign JWT tokens on your backend
* A **Public Key** (RSA) - Zipchat uses this to verify your tokens (you can use it for testing)

**Important**: Keep your private key secure and never expose it in client-side code. Only use it on your backend server.

**Step 2: Generate JWT Token on Your Backend**

{% hint style="danger" %}
**You must generate your JWT token in the backend ( not in the FrontEnd ).**\
If you generate the JWT token in the frontend, you will allow anyone to read your Private Key, and hackers will be able to authenticate with Zipchat as ANY USER.
{% endhint %}

Sign user data using the private key with the RS256 algorithm. Here's an example in Ruby:

```ruby
require 'jwt'
require 'openssl'

private_key = OpenSSL::PKey::RSA.new(PRIVATE_KEY_FROM_UI)

payload = {
  email: user.email,                    # Required
  phone_number: user.phone_number       # Optional (E.164 format)
  first_name: user.first_name,          # Optional
  last_name: user.last_name,            # Optional
  additional_attributes: {              # Optional (JSON object)
    user_id: user.id,
    subscription_tier: user.tier,
    # ... any other custom attributes
  },
  iat: Time.now.to_i,                   # Issued at (Unix timestamp)
  exp: 1.hour.from_now.to_i             # Expiration (Unix timestamp)
}

jwt = JWT.encode(payload, private_key, 'RS256')
```

**JWT Payload Keys We Read:**

| Field                   | Type                  | Required | Description                                 |
| ----------------------- | --------------------- | -------- | ------------------------------------------- |
| `email`                 | String                | Yes      | User's email address                        |
| `phone_number`          | String (E.164 format) | No       | User's phone number                         |
| `first_name`            | String                | No       | User's first name                           |
| `last_name`             | String                | No       | User's last name                            |
| `additional_attributes` | Object                | No       | Custom JSON object with any additional data |
| `iat`                   | Number                | Yes      | Issued at time (Unix timestamp)             |
| `exp`                   | Number                | Yes      | Expiration time (Unix timestamp)            |

**Step 3: Send JWT to Frontend**

Choose the method that best fits your stack:

**Option A: Render in HTML (Server-Side Rendering)**

```erb
<script>
  window.zipchatJWT = '<%= jwt_token %>';
</script>
```

**Option B: API Endpoint**

```javascript
// Fetch from your API
fetch('/api/zipchat-token')
  .then(response => response.json())
  .then(data => data.token);
```

**Option C: Hidden Meta Tag**

```html
<meta name="zipchat-jwt" content="YOUR_JWT_TOKEN">
```

**Step 4: Call Zipchat.identify**

Add this script to your HTML where users are logged in:

```javascript
<script>
  function identifyCustomer() {
    getZipchatToken().then(token => {
      if (window.Zipchat && window.Zipchat.identify) {
        Zipchat.identify(token);
      }
    });
  }

  // Wait for Zipchat to be ready before identifying
  window.addEventListener('zipchat:ready-to-identify', identifyCustomer);

  // If Zipchat is already ready, identify immediately
  if (window.Zipchat && window.Zipchat.isReadyToIdentify && window.Zipchat.isReadyToIdentify()) {
    identifyCustomer();
  }

  // Implement this function to get the JWT token from your backend
  function getZipchatToken() {
    // Example: Fetch from API
    return fetch('/your-backend/generate-zipchat-token', {
      method: 'POST',
      credentials: 'include'
    })
    .then(response => response.json())
    .then(data => data.token);
    
    // Alternative examples:
    // return Promise.resolve(window.zipchatJWT); // If rendered by backend
    // return Promise.resolve(document.querySelector('meta[name="zipchat-jwt"]').content); // If in hidden tag
  }
</script>
```

#### Function Parameters

**Zipchat.identify(jwt)**

| Parameter | Type   | Required | Description                 |
| --------- | ------ | -------- | --------------------------- |
| `jwt`     | String | Yes      | JWT token signed with RS256 |

#### Server Responses

The identification function will log different messages to the browser console based on the server response:

**Success Response**

* **HTTP Status**: 200
* **Response**: `{ "success": true }`
* **Console Log**: `Customer identified successfully`
* Success is cached in localStorage for 1 hour

**Error Response**

* **HTTP Status**: 422 Unprocessable Entity
* **Response**: `{ "success": false }`
* **Console Log**: `Error identifying customer: [error details]`

The server returns `{ "success": false }` in the following cases:

* JWT token is missing or invalid
* Customer identification is not enabled for the chat
* JWT signature verification failed
* JWT token has expired
* Email is missing from JWT payload
* Chat not found

#### Client-Side Validation

The JavaScript function performs validation before sending data to the server:

**Invalid JWT Token**

If JWT is not a non-empty string:

```
Zipchat.identify: JWT must be a non-empty string
```

**Widget Not Ready**

If Zipchat widget is not ready to identify:

```
Zipchat.identify: Not ready to identify. Wait for "zipchat:ready-to-identify" event or check Zipchat.isReadyToIdentify()
```

**Network Errors**

If the request fails due to network issues:

```
Error identifying customer: [error details]
```

#### Rate Limiting

To prevent duplicate requests, successful identifications are cached in localStorage:

* **Key**: `zipchat_identified_visitor_token`
* **Value**: `{ value: visitor_token, expiration: timestamp + 1 hour }`
* **Duration**: 1 hour

The cache expires when:

* 1 hour passes
* User clears localStorage
* User starts a new conversation (new visitor\_token)

#### Implementation Examples

> **⚠️ Important**: The examples below are provided as reference guides to help you understand the overall implementation approach. They are meant to give you direction on how to integrate customer identification, but you should adapt them to fit your specific stack, framework, and security requirements.

**Basic Implementation (Server-Side Rendered JWT)**

```html
<!-- In your layout/template where user is logged in -->
<script>
  window.zipchatJWT = '<%= @jwt_token %>';
</script>

<script>
  function identifyCustomer() {
    if (window.Zipchat && window.Zipchat.identify && window.zipchatJWT) {
      Zipchat.identify(window.zipchatJWT);
    }
  }

  window.addEventListener('zipchat:ready-to-identify', identifyCustomer);
  
  if (window.Zipchat && window.Zipchat.isReadyToIdentify && window.Zipchat.isReadyToIdentify()) {
    identifyCustomer();
  }
</script>
```

**Complete Implementation (API-Based)**

```javascript
<script>
  function identifyCustomer() {
    // Fetch JWT from your backend API
    fetch('/api/zipchat-token', {
      method: 'POST',
      credentials: 'include',
      headers: {
        'Content-Type': 'application/json',
      }
    })
    .then(response => response.json())
    .then(data => {
      if (data.token && window.Zipchat && window.Zipchat.identify) {
        Zipchat.identify(data.token);
      }
    })
    .catch(error => {
      console.error('[Zipchat] Error fetching JWT token:', error);
    });
  }

  // Wait for Zipchat to be ready
  window.addEventListener('zipchat:ready-to-identify', identifyCustomer);

  // Check if already ready
  if (window.Zipchat && window.Zipchat.isReadyToIdentify && window.Zipchat.isReadyToIdentify()) {
    identifyCustomer();
  }
</script>
```

**Backend Example (Ruby on Rails)**

```ruby
# app/controllers/api/zipchat_tokens_controller.rb
class Api::ZipchatTokensController < ApplicationController
  before_action :authenticate_user!

  def create
    private_key = OpenSSL::PKey::RSA.new(Rails.application.credentials.zipchat_private_key)
    
    payload = {
      email: current_user.email,
      phone_number: current_user.phone_number,
      first_name: current_user.first_name,
      last_name: current_user.last_name,
      additional_attributes: {
        user_id: current_user.id,
        subscription_tier: current_user.subscription_tier,
        account_created_at: current_user.created_at.iso8601
      },
      iat: Time.now.to_i,
      exp: 1.hour.from_now.to_i
    }
    
    jwt = JWT.encode(payload, private_key, 'RS256')
    
    render json: { token: jwt }
  end
end
```

**Backend Example (Node.js/Express)**

```javascript
const jwt = require('jsonwebtoken');
const fs = require('fs');

// Load private key
const privateKey = fs.readFileSync('path/to/private_key.pem', 'utf8');

app.post('/api/zipchat-token', authenticateUser, (req, res) => {
  const payload = {
    email: req.user.email,
    phone_number: req.user.phoneNumber,
    first_name: req.user.firstName,
    last_name: req.user.lastName,
    additional_attributes: {
      userId: req.user.id,
      subscriptionTier: req.user.subscriptionTier
    },
    iat: Math.floor(Date.now() / 1000),
    exp: Math.floor(Date.now() / 1000) + (60 * 60) // 1 hour
  };

  const token = jwt.sign(payload, privateKey, { algorithm: 'RS256' });
  
  res.json({ token });
});
```

#### Troubleshooting

**Common Issues**

1. **"Widget is not ready"**
   * Ensure the Zipchat widget script is loaded before calling `Zipchat.identify()`
   * Wait for the `zipchat:ready-to-identify` event or check `Zipchat.isReadyToIdentify()`
2. **"JWT signature verification failed"**
   * Verify you're using the correct private key from the Integrations page
   * Ensure you're using RS256 algorithm
   * Check that the public key matches the private key pair
3. **"JWT token has expired"**
   * Increase the `exp` (expiration) timestamp in your JWT payload
   * Ensure your server's clock is synchronized
4. **"Email is required in JWT payload"**
   * Always include the `email` field in your JWT payload
   * Ensure the email value is not null or empty
5. **"Customer identification is not enabled"**
   * Activate the feature from the Integrations page
   * Verify the chat has an active customer identification setup
6. **Identification not working**
   * Check browser console for error messages
   * Verify the JWT token is valid using a JWT decoder
   * Ensure the visitor\_token exists in localStorage
   * Check that the identification request is not being blocked by rate limiting (wait 1 hour or clear localStorage)

#### Security Best Practices

1. **Never expose your private key** in client-side code, HTML, or JavaScript
2. **Store private keys securely** using environment variables or secure key management systems
3. **Use HTTPS** for all API endpoints that generate JWT tokens
4. **Set appropriate expiration times** (recommended: 1 hour) for JWT tokens
5. **Validate user authentication** before generating JWT tokens
6. **Rotate keys** if you suspect they've been compromised (contact support to regenerate)


# Zipchat Purchase Tracking Integration (Non-Shopify stores)

## Purchase Tracking - Pixel (JavaScript)

### Overview

The Purchase Tracking feature allows Zipchat to track purchases that originate from chat bubble interactions on your website. This helps you measure the ROI of your chat widget by attributing sales to conversations that happened within a 24-hour window.

**Note**: This feature is only available for non-Shopify integrations. Shopify stores have their own built-in purchase tracking mechanism.

### How It Works

1. Customers interact with your Zipchat widget
2. The widget stores a visitor token in the browser's local storage
3. When a purchase is completed, your checkout page calls our tracking function
4. We match the purchase to the conversation using the visitor token and attribute the sale if it occurred within 24 hours of the last message

### Activation

#### Step 1: Enable the Feature

1. Navigate to your chat's **Integrations** page
2. Find the "Purchase tracking - Pixel (JavaScript)" section
3. Click the **Activate** button to enable purchase tracking

Once activated, you'll see the integration interface with the script snippet and implementation instructions.

#### Step 2: Add the Script to Your Checkout Page

Copy the provided script snippet and add it to your checkout success/thank you page:

```html
<script src='https://app.zipchat.ai/widget/track_zipchat_purchase.js?id=YOUR_WIDGET_TOKEN' data-no-optimize='1' defer></script>
```

**Important**: The script must be loaded on the page before calling the tracking function.

#### Step 3: Track the Purchase

Once the script is loaded, call the `trackZipchatPurchase` function with the purchase data:

```javascript
<script>
window.trackZipchatPurchase({
  order_id: "12345",
  order_total: 99.99,
  currency: "USD",
  line_items: [
    {
      id: "product_1",
      title: "Product Name",
      price: 99.99,
      quantity: 1
    }
  ]
});
</script>
```

### Function Parameters

#### Required Fields

| Field         | Type   | Description                                          |
| ------------- | ------ | ---------------------------------------------------- |
| `order_id`    | String | Unique identifier for the order                      |
| `order_total` | Number | Total order amount (including taxes, shipping, etc.) |
| `currency`    | String | Currency code (e.g., "USD", "EUR", "GBP")            |

#### Optional Fields

| Field        | Type  | Description                                    |
| ------------ | ----- | ---------------------------------------------- |
| `line_items` | Array | Array of purchased items (see structure below) |

**Line Items Structure**

Each item in the `line_items` array can include:

| Field      | Type   | Description        |
| ---------- | ------ | ------------------ |
| `id`       | String | Product identifier |
| `title`    | String | Product name       |
| `price`    | Number | Item price         |
| `quantity` | Number | Quantity purchased |

### Server Responses

The tracking function will log different messages to the browser console based on the server response:

#### Success Response

* **HTTP Status**: 200
* **Response**: `{ "success": true }`
* **Console Log**: `[Zipchat] Purchase tracked successfully.`

#### Error Responses

**Sales Tracking Not Enabled**

* **HTTP Status**: 403 Forbidden
* **Response**: `{ "error": "Sales tracking is not enabled. Enable it from [integration_url]." }`

**Chat Not Found**

* **HTTP Status**: 404 Not Found
* **Response**: `{ "error": "Chat not found" }`

**Missing Parameters**

* **HTTP Status**: 422 Unprocessable Entity
* **Response**: `{ "error": "Missing widget_token or shop parameter" }`

**Validation Errors**

* **HTTP Status**: 422 Unprocessable Entity
* **Response**: `{ "error": "[validation error messages]" }`

### Client-Side Validation

The JavaScript function performs validation before sending data to the server:

#### Missing Visitor Token

If no visitor token is found in localStorage:

```
[Zipchat] No visitor token found. Purchase tracking requires a visitor token.
```

#### Missing Required Fields

If `order_id`, `order_total`, or `currency` are missing:

```
[Zipchat] Missing required fields. Please provide order_id, order_total, and currency.
```

#### Network Errors

If the request fails due to network issues:

```
[Zipchat] Error tracking purchase: [error details]
```

#### Server Errors

If the server returns an error status:

```
[Zipchat] Failed to track purchase
```

### Implementation Examples

#### Basic Implementation

```javascript
// Minimal required data
window.trackZipchatPurchase({
  order_id: "ORD-123456",
  order_total: 49.99,
  currency: "USD"
});
```

#### Complete Implementation

```javascript
// With all optional data
window.trackZipchatPurchase({
  order_id: "ORD-123456",
  order_total: 149.97,
  currency: "USD",
  line_items: [
    {
      id: "PROD-001",
      title: "Wireless Headphones",
      price: 99.99,
      quantity: 1
    },
    {
      id: "PROD-002",
      title: "Phone Case",
      price: 24.99,
      quantity: 2
    }
  ]
});
```

### Troubleshooting

#### Common Issues

1. **"No visitor token found"**
   * Ensure the Zipchat widget has been loaded and a conversation has been initiated
   * Check that localStorage contains a `visitor_token` entry
2. **"Widget token not found in script URL"**
   * Verify the script URL includes the correct widget token parameter
   * Ensure the script tag src attribute is properly formatted
3. **Purchase not appearing in analytics**
   * Check that the purchase occurred within 24 hours of the last chat message
   * Verify that the visitor token matches an existing conversation
   * Ensure all required fields are provided correctly

### Attribution Window

Purchases are only attributed to conversations if they occur within **24 hours** of the last message in the conversation. This ensures accurate attribution while preventing false positives from older conversations.


# Cloudflare: Allow Zipchat to crawl your webiste

Fix 403 forbidden errors for Cloudflare sites

Currently, Cloudflare is blocking the Zipchat crawlers by default; therefore, Zipchat can't keep itself up to date.

To use Zipchat and Cloudflare together, you need to add a custom security rule that allows Zipchat to do its job. Here's how to do it:

1. Open Cloudflare and click on your website

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FK9stFELHZMOun9zl5mLG%2Fimage.png?alt=media&amp;token=44a4a847-5b51-457e-9d29-dd472136fda9" alt=""><figcaption></figcaption></figure>

2. On the left menu, find Security / Security rules
   1. After opening "Security rules" click "Create rule" > "Custom rules"

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FUdrGOGzWZkMLoZP745Bt%2Fimage.png?alt=media&amp;token=ae9bdf29-27e3-469c-86f1-272b28a12973" alt=""><figcaption></figcaption></figure>

Then add the following info in the custom rule

1. Rule name: `Allow Zipchat crawler` ( or something else )
2. When incoming requests match...&#x20;
   1. Field: `User Agent`
   2. Operator: `equals`&#x20;
   3. Value: `Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko) compatible; ZipchatBot/1.0; +https://zipchat.ai/bot`
3. &#x20;Then take action: `Skip`
4. WAF components to skip
   1. Click all checkboxes
5. Place at:
   1. Select order: First
6. Click "Deploy"

<figure><img src="https://2043605213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvYpZDb6HsnLHFu8ZygCS%2Fuploads%2FXTIRwn5q2qQqejL670JN%2Fimage.png?alt=media&amp;token=842a129e-cfa9-4d4e-a15c-485b041fa9eb" alt=""><figcaption></figcaption></figure>

This should allow the Zipchat crawler to update itself on your website.


# Publish a Skill on the Zipchat Skill Gallery

## Build & Publish Custom Skill Templates

> This page is for third-party developers and integration partners who want to publish a **skill template** to the Zipchat skill gallery — think of it as publishing an app on our app store. By the end, every Zipchat merchant will be able to install your integration in two clicks, with their own credentials.

### What is a custom skill?

{% embed url="<https://www.youtube.com/watch?v=G4NDj6BedF4>" %}

A **custom skill** lets a merchant's Zipchat AI agent perform a real action against an external HTTP API — look up an order, create a discount, fetch tracking, escalate a ticket, or run a richer multi-step flow across several systems.

There is **no code hosted on Zipchat**. A skill is just four inputs:

| Input            | What it is                                                                                                                          |
| ---------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| **Name**         | Short, human-readable (e.g. "Woo — Track orders"). Shown to the agent and the merchant.                                             |
| **Instructions** | The core deliverable: a structured prompt that tells the agent when to act, which API calls to make, and how to present the result. |
| **Variables**    | Secrets and per-merchant config (API keys, store URLs). Encrypted at rest, never shown to customers.                                |
| **Setup note**   | Merchant-facing install instructions for gallery templates (e.g. "How to get your REST API key").                                   |

A **skill template** is a pre-packaged skill in our gallery: your icon, name, description, instructions, and setup note. Merchants install it and only fill in their own variable values.

### How a skill executes

1. When a merchant installs your skill, Zipchat injects its instructions into the AI agent's system prompt, wrapped as:

   ```
   #### <skill name>
   <custom_tool_instructions>
   …your instructions…
   </custom_tool_instructions>
   ```
2. When a customer's request matches the skill, the agent runs the shell command(s) your instructions specify in a secure sandbox — typically `curl`, optionally piped through `jq` to reshape JSON, across multiple steps when the flow needs them. Each command's output comes back to the agent, which either runs the next step or replies to the customer in the brand's voice.
3. **Variables are injected as environment variables.** A variable named `WOO_CONSUMER_KEY` is referenced in your curl as `$WOO_CONSUMER_KEY`. The agent never sees the value.
4. **Runtime values use `{PLACEHOLDER}` syntax.** Values that come from the conversation — `{ORDER_ID}`, `{EMAIL}` — are filled in by the agent. Your instructions tell it how to obtain each one.

The sandbox toolbox is small and deliberate: `curl` (every HTTP call — the only thing that produces an effect), `jq` (parse and reshape JSON), `ripgrep`/`fd` (search fetched text), `unzip`. If a desired action has no HTTP call behind it, a skill can't do it.

**Zipchat handles the guardrails for you.** Command hygiene, fix-and-retry on malformed requests, no blind retries on genuine failures, honest failure messages in the brand's voice, and secret safety are all enforced platform-side — your instructions should only contain what's specific to your integration.

#### Variable naming rules

* Uppercase letters, digits, underscores; cannot start with a digit (`^[A-Z_][A-Z0-9_]*$`).
* Must be unique across all of a merchant's active skills — always prefix with your product: `WOO_…`, `ZENDESK_…`, never a bare `API_KEY`.

### The publishing process

#### Step 1 — Create a free Zipchat account

1. Create an account on [www.zipchat.ai](https://www.zipchat.ai).
2. Contact <support@zipchat.ai> (or your partnership manager) and ask for a **free developer account** — we'll set you up so you can build and test without a subscription.

#### Step 2 — Build your custom skill on your dev shop

The fastest way to author a skill is with our [Claude Code](https://claude.com/claude-code) skill — it embeds everything about how skills execute, interviews you, and hands back every input ready to paste:

1. Add the skill to Claude Code:

   ```
   /plugin marketplace add zipchat-ai/zipchat-custom-tool-skill
   /plugin install zipchat-custom-tool@zipchat-tools
   ```
2. Point it at your **API documentation** and tell it what you want the agent to achieve. It will work out the endpoints, auth, and call sequence, draft the instructions, and define the variables.
3. In your Zipchat dashboard, go to **AI training → Prompt and Skills → Add skill → Add your own**, and paste in the name, instructions, and variables.
4. Open **Test chat** (top right) and talk to your agent like a customer would. Confirm the skill triggers when it should, the API calls succeed, and the replies read well.

You can also write everything by hand — the [skill repository](https://github.com/zipchat-ai/zipchat-custom-tool-skill) documents the full prompt structure with complete examples.

#### Step 3 — Debug with the Debug button

If the skill misbehaves, every AI reply (in Test chat and in Conversations) has a **Debug** action with two tabs:

* **AI helper** — describe what's wrong and send it straight to our Support AI.
* **RAW debug info** — the exact prompts the agent received, every command it ran, and every API response it got back. Click **Copy debug info** and paste the transcript into Claude Code — the zipchat-custom-tool skill knows how to read it and will pinpoint the fix.

Typical symptoms map cleanly:

| Symptom in the transcript                                  | Likely fix                                           |
| ---------------------------------------------------------- | ---------------------------------------------------- |
| Your skill's block missing from the system prompt          | Skill inactive or not enabled for that channel       |
| No tool call where you expected one                        | Sharpen the when-to-use wording in your instructions |
| Malformed command (empty `$VAR`, unfilled `{PLACEHOLDER}`) | Fix variable names / input resolution rules          |
| API error in the output (401, 404, 422)                    | Wrong credential value, path, or params              |

Still stuck? Contact <support@zipchat.ai> — include the debug transcript.

#### Step 4 — Publish to the gallery

Happy with how it works? Tell your partnership manager (or <support@zipchat.ai>) that you want it published. Hand over:

* The final **name**, **description**, and **instructions**
* The **variable list**, each with a note on where merchants get the value
* The **setup note** (merchant-facing install steps)
* Your **logo/icon**

We review the template, package it, and publish it to the skill gallery — from then on, any Zipchat merchant can install your integration with their own credentials. We'll handle updates with you the same way.


# Chat Bubble Not Showing on your website

If the chat bubble isn’t appearing on your website, let’s first identify whether you’re using **Shopify** or another **e-commerce platform**:

***

#### 👉 If you’re a **Shopify** customer:

1. Go to **Zipchat > Chat Settings > Script & Integrations > Chat Bubble Script** and click on **“Visit this Link”**.

   This will take you to Shopify – please ensure that the **Zipchat app is activated**.
2. If the bubble still doesn’t appear, navigate to **Zipchat > Chat Settings > Channels > Bubble > Update Visibility** and make sure all toggles are switched **ON**.
3. Still not showing? Feel free to **contact our support team**, and we’ll help you troubleshoot further.

***

#### 👉 If you’re using **another shop system**:

1. You’ll need to install a **JavaScript snippet** on your website to display the chat bubble.
2. To find it, go to **Zipchat > Chat Settings > Script & Integrations > Install via JavaScript code**.
3. Copy the code and add it to your website as a script.
   * The easiest method is through **Google Tag Manager**: simply add the script as a tag visible across your entire site.
   * If you’re not using GTM, you can still add the script directly through your **CMS or site’s code**, just like any other JavaScript snippet.


# Collecting Phone Numbers with Zipchat

At the moment, **Zipchat collects phone numbers exclusively through the WhatsApp channel**. The lead generation pop-up does **not yet support phone number collection**.

To start collecting phone numbers via WhatsApp:

1. **Set up the WhatsApp channel** in Zipchat.
2. Once configured, Zipchat will **automatically capture the phone numbers** of any customers who message you via WhatsApp.
3. You can view them under **Zipchat > Contacts > Phone Numbers**.
4. If needed, you can **export the list as a CSV file** directly from that section.


# Translating the welcome message based on geolocation

Zipchat can translate your chatbot’s **welcome message based on the user’s geolocation**, but this feature is currently available **only for Shopify customers**.

If you are using Shopify and would like to enable this functionality, please reach out to our support team — we’ll be happy to configure it for you.

Please note:

* The geolocation-based translation applies **only to the welcome message**.
* It does **not** apply to prefilled messages (quick reply buttons).
* At this time, quick reply buttons cannot be translated automatically based on geolocation.

***

#### If You’re Not Using Shopify

Unfortunately, geolocation-based translation of the welcome message is not available for non-Shopify platforms.

As an alternative, you can:

* Create a separate bot for each language.
* Assign each bot to the corresponding language subdomain of your website.

This approach allows you to fully customize the content and language experience for each audience.


# Adding the bubble on the checkout page

If you're a **Shopify Plus** customer, you can now display the Zipchat Bubble directly on your **checkout page**.

\
To enable it, follow these steps:\
**Shopify Admin > Online Store > Edit theme > Switch to "Checkout and Customer accounts" > Add the Zipchat Checkout script.**

If you're **not a Shopify Plus** customer, you can still show the Zipchat Bubble on the **thank you page** by following the same steps.


# Adding multiple pages to your knowledge base

Zipchat allows you to add pages to your knowledge base both automatically and manually, giving you full control over the content your AI can reference.

### Initial Bulk Scan

When you first set up Zipchat, the AI performs an **initial bulk scan** of your website. This **Initial Scrawl** automatically scans all available pages and adds them to your knowledge base in bulk. No manual action is required during this step.

### Manually Adding Pages

After the initial scan, you can manually add pages to your knowledge base:

Go to **Zipchat > AI Training > Knowledge Base > Add a New Source**. Here, you can:

* **Add a Single Page** – Enter the URL of a page you want to include.
* **Add Multiple Pages** – Enter the **generic site URL** (without folders or subpages). Zipchat will scan all pages that haven’t been previously added and include them in your knowledge base.
* **Add Sitemap** – Use your site’s sitemap to add all listed pages automatically.

This allows you to add pages individually or in bulk, depending on your needs.

### Concurrent Scans and Updates

Zipchat ensures your knowledge base stays up to date with **automatic scheduled scans**:

* **Starter and Growth Plans** – Weekly scans
* **Pro, Scale, and Enterprise Plans** – Daily scans

These scans check for **new pages** and **updates to existing pages**, keeping your knowledge base current.

#### Hard Reset / Rescan

If the initial scroll was incomplete, blocked (e.g., via Cloudflare), or something went wrong during the scan, you can request a **hard reset / rescan** through the support team. This will reprocess your website and update your knowledge base accordingly.


# What the different conversation icons mean

### Conversation Icons Overview

Clear explanations of the icons displayed in the AI chatbot conversation tabs and what each status represents.

***

#### Purple Brain Icon

The purple brain icon indicates that AI replies have been turned off and a human agent has taken over the conversation. This means all responses are being sent manually and the AI will no longer generate answers or follow up with the customer.

This mode is typically used when:

* You want to provide information manually
* You need to handle sensitive or delicate topics
* The situation requires direct human judgment beyond AI handling

Best practice: Once the conversation has been handled, the human agent should re-enable AI replies. After AI is turned back on, the purple brain icon will no longer be displayed.

***

#### Red Exclamation Mark in a Diamond

The red diamond exclamation mark indicates that a conversation has been escalated to human support. It signals that the inquiry requires manual review and intervention by a human agent to resolve the issue.

***

#### Blue Shopping Cart Icon

The blue shopping cart icon indicates that the conversation is directly related to a product sale on your website. This helps teams quickly identify chats that involve purchase intent, order discussions, or sales-related interactions.


# How to Enable Zipchat AI Search for Your Shopify Store

Replace your standard search bar with an AI-powered search experience that combines product results with conversational AI assistance.

### What Is Zipchat AI Search?

Zipchat AI Search is an intelligent search overlay that takes over your store's existing search bar. When a visitor clicks the search icon or search field on your Shopify store, instead of the default Shopify search, they get a powerful AI-enhanced search experience.

The search overlay combines two things:

* Smart search results — instantly displays matching products and pages from your catalog as the visitor types, with images, titles, and prices.
* An AI chat panel — your Zipchat AI assistant, ready to answer questions, recommend products, and guide shoppers in a conversational way.

On desktop, visitors see both panels side by side. On mobile, they see search results first with a prominent "Ask AI" button to switch to the conversational assistant.

Everything is fully customizable — colors, labels, placeholder text, and button styling — all from the Zipchat dashboard.

### Setup Guide

#### Step 1: Open Your Chat Settings

Log in to your Zipchat dashboard. Navigate to your chat (your AI agent), and look for the AI Search section under the channels area on your chat settings page.

You'll see the AI Search card with options to Edit and Add to site.

#### Step 2: Configure the Search Trigger (CSS Selectors)

This is the most important step. You need to tell Zipchat which element on your store should trigger the AI search overlay.

Click Edit (or Add to site if it's your first time). In the Search trigger section, enter the CSS selectors of your store's search elements.

CSS selectors identify the search bar or search icon on your Shopify theme. Common examples include:

* .search-modal\_\_toggle — a search icon button
* \[data-action="search"] — a data attribute on the search element
* \#search-input — a search input field
* .header\_\_search — search area in the header

You can add multiple selectors — just type each one and press Enter. Zipchat will intercept clicks on any of those elements and open the AI search overlay instead of the default search.

To find your search selectors: right-click on your store's search icon or search bar, select "Inspect", and look at the HTML element. Copy the class name (prefixed with a dot) or the ID (prefixed with a hash). If you're unsure, contact Zipchat support — we can help you identify the right selectors for your theme.

#### Step 3: Customize the Look and Feel

On the same edit page, you can personalize how the AI search looks:

* Search placeholder — the text visitors see in the search input (e.g., "Search products or ask a question..."). Use {{ai-agent}} to dynamically insert your assistant's name.
* "Ask AI" button colors (mobile) — set the background color, gradient color, and label color for the mobile "Ask AI" button.
* Button label (mobile) — customize the text on the "Ask AI" button. Use {{ai-agent}} for your assistant's name.

#### Step 4: Customize Search Result Labels

For Shopify stores, the search results panel shows separate sections for products and pages. You can customize:

* Products label — the heading above product results (e.g., "Products")
* Pages label — the heading above page results (e.g., "Pages")
* See all results label — the link text at the bottom (e.g., "See all results for {{search-query}}")
* No results message — what to show when no results are found

#### Step 5: Adjust Positioning (Optional)

If the search overlay appears behind other elements on your page, you can adjust the Z-index value. A higher number means the overlay will appear on top of other page elements. The default value works for most themes.

#### Step 6: Go Live

Once you've configured the search trigger and customized the design, head back to the chat settings page and click "Add to site" (or "Update visibility" if it's already been enabled before).

A modal will appear where you can choose where the AI search should be active:

* on Mobile — enable for mobile visitors
* on Desktop and Tablet — enable for desktop and tablet visitors

Check the options you want and click Save. Your AI search is now live!

### How It Works for Your Visitors

#### On Desktop

When a visitor clicks your store's search icon or search bar, the Zipchat AI Search overlay opens. They see a split view: on the left, real-time search results with product images, titles, and prices, plus matching pages below. On the right, your AI assistant, ready to answer questions, recommend products, and guide the shopper.

Visitors can search and chat at the same time — it's like having a personal shopping assistant built right into the search bar.

#### On Mobile

On mobile devices, visitors first see the search results. At the bottom of the screen, a prominent "Ask AI" button invites them to start a conversation with your AI assistant. Tapping it switches to the chat view.

### Tips for Best Results

* Make sure your product data is complete. AI Search pulls from your synced product catalog. Products with good titles, descriptions, and images will show up better in results.
* Test on both mobile and desktop. Use the preview tabs in the editor to see how your search looks on each device before going live.
* Set up suggestion messages in your chat. The AI panel shows suggestion chips (quick questions visitors can click). Configure these in your chat settings for a more engaging experience.
* Need help finding your CSS selectors? Every Shopify theme uses different HTML structure. If you're not sure which selectors to use, reach out to the Zipchat support team — we'll identify the right ones for your specific theme.

### Summary

1. Go to your chat settings and find the AI Search section
2. Click Edit and add the CSS selectors of your store's search elements
3. Customize colors, labels, and placeholder text to match your brand
4. Click "Add to site" and enable it for mobile and/or desktop
5. That's it — your visitors now have an AI-powered search experience


# How to Enable AI Search for Non-Shopify Stores

Set up Zipchat's AI-powered search on any website — WooCommerce, Magento, custom builds, and more.

***

### What is AI Search?

AI Search is Zipchat's smart search feature that replaces or enhances your website's existing search bar. It uses semantic search to surface the most relevant products and pages — even when visitors don't type the exact right keywords.

For Shopify stores, AI Search works out of the box because products sync automatically. For non-Shopify stores, you need to provide a product feed so Zipchat knows about your catalog. Here's how.

***

### Step 1: Install the Zipchat Widget on Your Website

If you haven't already, add the Zipchat script to your website. This is the same script that powers the chat widget — AI Search is included with it.

Copy the script tag from your Zipchat dashboard and paste it into the \<head> or before the closing \</body> tag on every page of your site:

`<script src="https://widget.zipchat.ai/widget/zipchat.js?id=YOUR_WIDGET_TOKEN" data-no-optimize="1" defer></script>`

You can find your unique widget token in your chat settings in the Zipchat dashboard.

***

### Step 2: Add Your Product Feed

Since Zipchat can't pull products directly from your store (like it does with Shopify), you need to provide a Google Merchant Feed — a standard XML or CSV file that lists all your products.

#### How to add it:

1. Go to your chat settings in the Zipchat dashboard.
2. Navigate to the AI Training section (Sources / Pages area).
3. Click "Add new source."
4. Select "Product Feed" as the source type.
5. Paste your Google Merchant Feed URL (e.g. <https://yourstore.com/product-feed.xml>).
6. Click Add.

#### What is a Google Merchant Feed?

It's a standardized file (XML or CSV) containing your product data — titles, descriptions, prices, images, availability, and links. Most e-commerce platforms (WooCommerce, Magento, PrestaShop, BigCommerce, etc.) can generate one automatically, often through a plugin or built-in export. If you already use Google Shopping, you likely already have one.

Once added, Zipchat will automatically parse your feed and index all your products. This runs periodically to keep your catalog up to date.

#### Out-of-stock handling

Zipchat automatically detects out-of-stock products from your feed. For extra control, you can set an "out-of-stock keyphrase" in your chat configuration — a text snippet that appears only on out-of-stock product pages, helping Zipchat identify them during crawling.

***

### Step 3: Enable AI Search Visibility

Once your products are indexed, turn on AI Search:

1. Go to your chat settings in the Zipchat dashboard.
2. Find the AI Search channel card (it appears in the Channels section alongside your chat widget).
3. Click on it and toggle visibility for Mobile, Desktop, or both.

Important: AI Search requires at least one CSS selector to be configured so it knows where to attach on your page. Zipchat automatically detects your site's search bar during setup, but if it didn't find one, you'll need to add it manually (see next step).

***

### Step 4: Configure the Search Trigger (CSS Selectors)

AI Search works by replacing or enhancing your existing search bar. It uses CSS selectors to identify which element(s) on your website should trigger the AI Search overlay when clicked.

#### How to configure:

1. Go to AI Search → Edit in your chat settings.
2. In the "Search trigger" card, add the CSS selectors for your site's search element(s).

#### Examples of CSS selectors:

* `input[type="search"]` — targets any search input
* `.search-bar` — targets an element with the class "search-bar"
* `#site-search` — targets an element with the ID "site-search"
* `[class*="search-form"]` — targets any element with "search-form" in its class name

#### How to find your search selector:

Right-click on your website's search bar, select "Inspect" in your browser, and look at the HTML element. Note its class, id, or other identifying attributes to build your CSS selector.

Zipchat tries to auto-detect these selectors when your chat is first created. If auto-detection worked, you'll already see selectors filled in. You can adjust them anytime.

***

### Step 5: Customize the Look & Feel

From the Edit AI Search page, you can customize:

* Search placeholder — the hint text in the search bar. Use {{ai-agent}} to insert your assistant's name.
* Ask AI button colors — background color, gradient, and label color for the mobile "Ask AI" button.
* Button label — the text on the mobile AI button (e.g. "Ask {{ai-agent}}").
* Z-index — controls the layering of the search overlay. Increase if it appears behind other elements (default is 999).
* No results message — what visitors see when their search returns nothing.

The preview panel on the right shows you how it will look on both desktop and mobile.

***

### Step 6: Test It

Visit your website and click on your search bar. You should see the Zipchat AI Search overlay with:

* A search input at the top.
* Relevant results from your product feed and crawled pages as you type.
* An "Ask AI" panel where visitors can ask natural language questions to your AI assistant.

***

### How Non-Shopify Search Differs from Shopify

#### Shopify stores:

* Products sync automatically via the Shopify API.
* Search results show product images, titles, and prices in separate sections ("Products" / "Pages").
* Search visibility is auto-enabled when selectors are detected.
* Includes a "See all results" link.

#### Non-Shopify stores:

* Products come from your Google Merchant Feed (XML or CSV).
* Search results show pages in a unified list (powered by semantic/RAG search).
* You need to manually enable search visibility.
* You may need to set an out-of-stock keyphrase for stock filtering.

Under the hood: Shopify stores use a "shopify" search type that queries Shopify's Predictive Search API alongside Zipchat's semantic search. Non-Shopify stores use a pure RAG (Retrieval-Augmented Generation) search that combines dense vector search with sparse keyword search for the best results.

***

### Troubleshooting

* AI Search doesn't appear: Make sure visibility is toggled ON (for mobile and/or desktop) and that you have at least one CSS selector configured.
* No results showing: Check that your product feed URL is accessible and valid. Zipchat needs to successfully parse it before products appear.
* Search overlay appears behind other elements: Increase the Z-index value in AI Search settings.
* Wrong element being targeted: Adjust your CSS selectors. Use browser DevTools to inspect the correct element.
* Products not updating: Zipchat periodically re-parses your feed. For an immediate refresh, remove and re-add the product feed, or contact support.


# Test & Train your AI Agent

Testing your bot is very simple. To get started, log in to ZipChat, go to **Chat Settings**, and click the **Test Chat** button in the top-right corner. This will open a testing interface where you can interact with the agent and simulate different conversations.

Your agent continuously learns over time from conversations and from your website content. When you create your ZipChat account, we automatically scan all the information available on your website. After that, we perform a full rescan every week to ensure the knowledge base remains up to date.

At any time, you can manually improve or modify your agent’s knowledge. To do this, go to the **AI Training** section, where you’ll find three main areas: **Knowledge Base**, **Corrections**, and **Prompt & Tools**.

#### Knowledge Base

In the Knowledge Base section, you can remove pages that were scanned from your website or add new ones. You can also upload product feeds, PDF files, sitemaps, and even product catalogs that ZipChat can process and learn from. If needed, you can simply upload plain text files. This allows you to add specific information that may not already be included in the automatic scan.

#### Corrections

In the Corrections section, you can review and manage specific responses you’ve asked ZipChat to modify. You can create a correction directly from either the Test Chat or from real customer conversations. Under each message, you’ll find a **Create Correction** button. By clicking it, you can update the Knowledge Base or adjust the agent’s behavior as you see fit.

#### Prompt & Tools

This section contains the core of ZipChat: the **Core Prompt**, which defines how the AI behaves in general scenarios.

In **Additional Instructions**, you can define how ZipChat should behave in specific situations — for example:

* How to respond when a customer asks to speak with human support
* How to handle order tracking requests
* What qualification questions to ask when a customer requests product recommendations

You’ll also find important tools here, such as **Escalate Conversation**, which allows you to transfer a conversation to human support when the AI is unable to resolve it independently.

***

Once your agent has completed scanning your website, you’ve tested a few conversations, and you’ve adjusted the Core Prompt as needed, your AI agent is ready to go live.

Our recommendation is to launch as soon as possible so you can start testing real conversations with real customers. From there, you’ll be able to review ZipChat’s responses and fine-tune the agent according to your preferences.

***


# Customize the chat to fit your brand

When we create your bot, we automatically set it up with branded visuals, an image, and shortcut buttons that align with your brand.

However, we strongly recommend customizing it further so your AI agent truly reflects your identity and delivers a fully branded experience.

#### How to Customize Your ZipChat Agent

Customizing your agent is simple.

Go to **Chat Settings**, then navigate to the **Bubble Chat** section and click **Edit**. This will open the agent customization panel.

From here, you can:

* **Change the agent’s name**
* **Edit the welcome message**
* **Set predefined messages**

Predefined messages are shortcut buttons designed to highlight frequently asked questions or key actions. They help guide your customers toward the most relevant topics and make the conversation more intuitive.

You can also:

* Add or modify a short disclaimer
* Adjust the chat bubble’s colors and shape

The bubble style can be set to:

* **Modern**
* **Classic**
* Or the innovative **Type Bar**, which creates a more product-recommendation-focused experience rather than a traditional support chat feel.

#### Advanced Customization Options

In this section, you can also:

* Enable the **Lead Collection Popup** to request a customer’s email address before they send a message
* Choose whether to display the chat bubble on desktop, mobile, or both
* Select the specific pages where the bubble appears
* Adjust the bubble’s size and position

If the bubble overlaps with other design elements on your website, you can easily adjust its position by modifying the **z-index** value. The higher the z-index, the more the chat bubble will appear on top of other page elements.


# Install the Zipchat Script (Shopify)

Installing the ZipChat script on your Shopify store is quick and easy.

First, go to **Chat Settings** and click on **Update Visibility**. Make sure the chat bubble is enabled for both desktop and mobile.

Next, still within **Chat Settings**, navigate to **Scripts and Integrations**. In this section, you’ll find an area labeled **Chat Bubble Script**.

There, you’ll see a link that will redirect you directly to Shopify, under the **App Embeds** section.

Simply enable ZipChat from the list of available apps and click **Save**.

That’s it — ZipChat will now be live and visible on your website.


# Install the Zipchat Script (not-Shopify)

To make the ZipChat app visible on your website, you need to ensure that the ZipChat script is installed across all pages.

You can find the script by going to **Chat Settings**, then clicking on **Scripts and Integrations**, and selecting **Install via JavaScript Code**. Here, you’ll see a simple line of code that needs to be copied and pasted into your website as a script.

If you’re using a platform like WordPress, you can easily add the script site-wide using a plugin designed for custom scripts.

Alternatively, if you use tools such as Google Tag Manager, you can add the ZipChat script as a new tag and publish it so that it runs across your entire website.

Once the script is properly installed, ZipChat will be activated and visible on your site.

If, after installation, you’re still unable to see ZipChat live, go back to **Chat Settings**, click on **Channels**, and under **Bubble Chat**, select **Update Visibility**. There, you can confirm whether the chat bubble is enabled for both desktop and mobile.


# Ignore spam conversations

You can instruct ZipChat to ignore entire conversations in order to reduce spam and avoid wasting AI responses.

To do this, go to **AI Training** in your ZipChat dashboard and select **Prompt & Tools**. Scroll down to the section called **Skip Conversation** and click **Activate**.

In this area, you can define rules that tell ZipChat to automatically skip specific conversations. For example, you can configure it not to respond to emails coming from a particular email address or even from an entire domain — such as any address ending in *@test.com*.

This ensures that valuable AI responses are not used on irrelevant or unwanted conversations.

You can also set rules to prevent ZipChat from replying to internal emails sent by members of your own team.


# Collect leads from the bubble chat

You can use ZipChat to collect your customers’ email addresses directly through the chat.

To enable this feature, go to **Chat Settings**, then navigate to the **Bubble Chat** section and click **Edit**. Scroll down to the **Lead Collection Popup** section and select **Ask for email before starting a chat**.

From there, you can fully customize the email collection pop-up. You can:

* Edit the text and messaging
* Customize the buttons
* Request marketing consent, allowing you to use the collected emails for future marketing campaigns

This is a powerful tool for growing your email list. However, keep in mind that requiring an email before starting a conversation may discourage some users from continuing with the chat.

If your primary goal is **customer support**, collecting email addresses is highly recommended.\
If your objective is to **convert customers who are close to making a purchase**, it may be more effective to remove this requirement to reduce friction and maximize conversions.


# WA: Send a one-off marketing campaign

You can send WhatsApp marketing campaigns directly from ZipChat.

To get started, go to **ZipChat → Campaigns → WhatsApp Marketing**.

If you haven’t already set it up, you’ll see a message asking you to add a payment method on Meta. This is required because WhatsApp Marketing campaigns are paid and billed directly by Meta.

Follow the steps to add your payment method to your Meta account. Once completed, click the **“I’ve added my payment method”** button. You’ll then be able to create your first campaign.

#### Creating a Campaign

Inside the campaign builder, you can choose which contacts to send your message to. You can:

* Send it to **all contacts**
* Select a **specific segment** created in the **Contacts** section of ZipChat
* Import external segments from **Shopify**
* Upload a contact list via **CSV file**

You can then define the opening message of your campaign. ZipChat allows you to use dynamic variables, such as the customer’s first name or last name, to personalize the message.

#### GDPR & Unsubscribe Instructions

To remain compliant with GDPR and other privacy regulations, it’s important to always include clear unsubscribe instructions. You can configure this in the **Unsubscribe Instructions** section, allowing users to opt out of future WhatsApp marketing messages.

#### Automating Responses

In the **Campaign Prompt** section, you can define how ZipChat should behave when a customer replies to your opening message. For example, you can instruct ZipChat to:

* Send a discount code
* Share a specific product link
* Ask qualifying questions to help the customer find the best product
* Guide the user through a personalized buying journey

As mentioned, WhatsApp Marketing campaigns involve costs that are paid directly to Meta. You can calculate the expected cost of your campaigns by visiting Meta’s official pricing page here:\
<https://business.whatsapp.com/products/platform-pricing>


# Install Zipchat on your thank you page (Shopify)

This works for all Shopify stores (not just Shopify Plus).\
Steps:

1. In your Shopify admin, go to Online Store → Themes → Customize (click the "Customize" button on your active theme)
2. In the theme editor, click the dropdown at the top that says "Home page" and select "Checkout and Customer accounts"
3. On the left sidebar, click the "Apps" icon (it's the icon on the far-left menu bar)
4. Click "Add app block" and select "Zipchat Thank You"
5. Save your changes

That's it — Zipchat will now appear on your thank you page after checkout!

\
[Shopify Plus customers can also add Zipchat to the checkout page itself](https://docs.zipchat.ai/help-center/adding-the-bubble-on-the-checkout-page) (not just thank you). Same steps, but in step 4 you'd add "Zipchat Checkout" instead (or in addition).<br>


# Connect Facebook Messenger

### Before You Start

* A Facebook Page for your business (personal profiles won't work)
* Admin access to that Facebook Page
* A Zipchat agent already set up

### Setup Steps

**Step 1 — Go to Channels**

Open your Zipchat dashboard and navigate to your agent's Channels section. You'll see the Messenger card with the description "Let Zipchat respond to your Facebook page messages."

**Step 2 — Click "Connect page"**

Click the Connect page button on the Messenger card. This will redirect you to Facebook to authorize the connection.

**Step 3 — Log in to Facebook**

If you're not already logged in, Facebook will ask you to sign in. Use the account that has admin access to the Facebook Page you want to connect.

**Step 4 — Select your Facebook Page**

Facebook will show you a list of Pages you manage. Select the Page you want Zipchat to respond on and grant the requested permissions.

**Step 5 — Confirm and return to Zipchat**

After approving, you'll be redirected back to Zipchat. The Messenger card will now show a Connected badge with your page name.

That's it — your AI agent is now responding to Messenger conversations automatically.

### What You Get After Connecting

* **Automatic responses** — Your AI agent replies to incoming Messenger messages using your knowledge base, just like it does on your website.
* **Link to Messenger chat** — A shareable link (m.me/yourpage) you can put on your website, emails, or social media to send customers directly to chat with your agent.
* **QR code** — A scannable QR code that opens a Messenger conversation with your agent — great for print materials or in-store displays.
* **Pre-filled messages** — Optionally set a default message that pre-fills the text box when someone opens the chat link or scans the QR code.
* **Test button** — Quickly test the connection by clicking "Test" to open a Messenger chat with your agent.


# Make Zipchat follow-up with your customers

*What is it?*\
Follow-Up Campaigns let the AI automatically re-engage customers after a conversation goes quiet. Instead of the customer disappearing, Zipchat sends them a personalized follow-up message after a set delay — nudging them to come back, finish a purchase, or get more help.\
\
*Supported channels:* WhatsApp, Instagram, Messenger, Email\
\
───\
\
*How it works (step by step):*\
\
1\. A customer sends a message on one of the supported channels\
2\. The AI replies normally\
3\. After the conversation goes quiet, a timer starts based on the delay you set (1h, 2h, 3h, 6h, 12h, or 23h)\
4\. When the timer fires, the AI checks whether a follow-up makes sense — it looks at the conversation context, your conditions, whether the customer's last message was within 24 hours, and whether they didn't ask to stop being contacted\
5\. If everything checks out, the AI generates a personalized follow-up message using the instructions you wrote and sends it on the same channel\
\
*Important:* The follow-up only triggers if the customer initiated the conversation AND AI replies are still enabled on that conversation. If a human agent took over, or the customer hasn't messaged in 24+ hours, no follow-up is sent.\
\
───\
\
*How to activate it:*\
\
1\. Go to *Campaigns* in your Zipchat dashboard\
2\. Click the *Follow-Ups* tab\
3\. Click *Create* to make a new follow-up campaign\
4\. Fill in the form:\
• *Name* — internal label, only you see it\
• *Channels* — pick which channels to follow up on (only connected channels are selectable)\
• *Message delay* — how long to wait after the last message before following up (1 hour to 23 hours)\
• *Conditions for following up* — optional, describe when the AI *should* follow up (e.g. "if the customer showed interest in buying a product")\
• *What to say* — required, tell the AI what the follow-up message should achieve (e.g. "Ask if they're still interested, address objections, offer a discount")\
5\. Save the campaign\
6\. Activate it by setting the status to *Sending* (campaigns start in Pending status)\
\
You can also *pause* a campaign at any time, and there's a *preview mode* in the dashboard to test how your follow-up would look before going live.\
\
───\
\
*Quick tips:*\
• You need at least one channel connected (WhatsApp, Instagram, Messenger, or Email) for this to work\
• You can have multiple follow-up campaigns running at once, even on different channels\
• The "Conditions" field is powerful — use it to make sure follow-ups only happen when relevant (e.g. don't follow up if the customer already bought)


