=== Fetchply - AI Chatbot and Live Chat ===
Contributors: ranaharoon322
Tags: chatbot, ai, live chat, customer support, woocommerce
Requires at least: 6.3
Tested up to: 7.0
Stable tag: 1.0.1
Requires PHP: 7.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Add the Fetchply AI chat agent to your site in one click. No code to paste. Train, customize, and read conversations in your dashboard.

== Description ==

Fetchply builds an AI chat agent from your own content, your pages, your files, and your Q&A, so it answers visitor questions in your words, around the clock.

This plugin is the WordPress half of that. It stays deliberately small and does three things:

* **Puts the chat widget on your site.** Connect an agent and the widget appears for visitors. No theme edits, no script tags to paste.
* **Connects your site in one click.** Sign in at fetchply.com, pick your agent, done. No API keys to copy between screens.
* **Connects WooCommerce, optionally.** Approve read-only access on WooCommerce's own screen and your agent can answer product and order questions.

= Managed from your Fetchply dashboard =

Everything beyond the widget lives in your dashboard, and the plugin links straight to each page:

* **Train your agent** on pages, files, and Q&A pairs.
* **Customize the widget** colors, greeting, and chat behavior.
* **Inbox** to read conversations and reply as your team.
* **Analytics** for top questions and trends.

What you save there applies to your site automatically.

= What the plugin stores on your site =

Very little, on purpose: which agent is connected, its name, whether the widget is showing, and the date you approved WooCommerce access. The plugin stores no API keys or passwords. Deleting it removes all four values.

= Requirements =

* A Fetchply account. A free plan is available, and you can create the account during the connect step.
* WordPress 6.3 or newer, and PHP 7.4 or newer.
* WooCommerce is optional, and only needed for product and order answers.

== External services ==

This plugin relies on Fetchply (fetchply.com), the service that runs your chat agent. It cannot work without it.

**Chat widget.** Once your site is connected and the widget is on, public pages load the widget script from fetchply.com, and a visitor's messages are sent to Fetchply to generate replies. While the widget is off, or before you connect, the script is not loaded at all.

**Connecting your site.** Clicking Connect to Fetchply takes you to fetchply.com to sign in and choose an agent. Your site address, the admin page to return to, and a one-time verification code are included so the connection can be matched back to your site. Nothing is sent before you click Connect.

**WooCommerce (optional).** If you approve the request on WooCommerce's own screen, WooCommerce sends read-only API keys to Fetchply so your agent can look up products and orders. You can revoke that access at any time.

Terms and privacy: [terms of service](https://fetchply.com/terms), [privacy policy](https://fetchply.com/privacy).

== Installation ==

1. Go to **Plugins > Add New**, search for **Fetchply**, then install and activate. To install manually, upload the plugin folder to your plugins directory and activate it from **Plugins**.
2. Open **Fetchply** in the admin menu.
3. Click **Connect to Fetchply**. Sign in, or create a free account, then pick the agent for this site. New to Fetchply? Create an agent instead and it starts training on your content right away.
4. Done. The widget is live, and the page shows **Connected to** your agent's name.

For product and order answers, click **Connect WooCommerce** on the same page and approve the read-only request. That button appears only when WooCommerce is active.

== Frequently Asked Questions ==

= Do I need a Fetchply account? =

Yes. The agent runs on Fetchply. You can create a free one during the connect step.

= Do I have to paste code or edit my theme? =

No. Connecting your site is the whole setup. The plugin adds the widget for you and works with any properly built theme.

= Who can connect or disconnect the site? =

Only users who can manage site options, which normally means Administrators. Other roles do not see the Fetchply menu.

= Where do I train my agent or restyle the widget? =

In your dashboard. The **Manage on Fetchply** card links to **Train your agent**, **Customize widget**, **Inbox**, and **Analytics**. What you save there applies automatically, with nothing to re-save here.

= Can I hide the widget without disconnecting? =

Yes. Untick **Show the chat widget on my site** and click **Save**. The status becomes **Hidden** and visitors stop seeing it, while your connection and agent stay as they were.

= Will it slow down my site? =

The widget script loads in the footer and is deferred, so it does not hold up your content. While hidden, or before you connect, nothing loads.

= The widget isn't showing on my site. =

Check three things in order. The page should say **Connected to** your agent's name. **Show the chat widget on my site** should be ticked and saved. Then clear your caching or optimization plugin's cache, since some strip or defer scripts they don't recognize. Caching is otherwise fine: the widget is a small script tag that cached pages serve like any other asset. Clear the cache too if you restyled the widget and still see the old look.

= My new agent replies "I don't know" at first. =

Training starts the moment the agent is created and usually takes a few minutes. Follow it under **Train your agent**; answers improve as soon as it finishes, with nothing to change here.

= I got "This connect link expired or did not match this browser session." =

Connect links are single use, last about 15 minutes, and must be finished in the same browser by the same logged-in user who started them. Usually that means too much time passed, you restarted in another tab, or a different administrator finished it. Click **Connect to Fetchply** again.

= I don't see the WooCommerce card. =

It appears only when your site is connected and WooCommerce is active. Otherwise you will see **Connect your site to Fetchply and make sure WooCommerce is active first.** Activate WooCommerce, finish connecting, then reload.

= WooCommerce said access was not approved. =

That happens when the approval screen is declined or closed early. Nothing was shared and nothing changed on your store. Click **Connect WooCommerce** to try again.

= How do I revoke WooCommerce access? =

Two steps. In **WooCommerce > Settings > Advanced > REST API**, revoke the Fetchply key. Then remove the store under **Integrations** in your dashboard. Your agent keeps working for everything else.

= What does Disconnect do? =

It removes the widget and deletes the few settings the plugin saved. Your account, agent, and training are untouched, so reconnecting is one click. To switch agents, disconnect and connect again, choosing the agent you want. Revoking WooCommerce access is separate.

= What happens if I delete the plugin? =

Every option it created is removed, leaving nothing in your database. Your Fetchply account and agent are not affected.

= Can I use it on more than one site? =

Yes. Install and connect it on each site. Several sites can share one agent, or each can have its own.

= Does it work on WordPress multisite? =

Yes, one site at a time. Connect each site from its own Fetchply page. There is no network-wide setting.

== Screenshots ==

1. Every conversation in one inbox. Your agent answers first, and your team can step in at any point.
2. See how many conversations your agent handled, how many it answered without you, and what visitors ask most.
3. Everything your agent has learned in one place: your pages, your files, and your own instant answers.
4. Connect WooCommerce, WhatsApp, Instagram, Messenger, Slack, and more, so one agent covers every channel.
5. Set your agent's name, colors, greeting, and chat icon, with a live preview beside you as you edit.
6. A built-in help center, so you can search the guides or just ask.

== Changelog ==

= 1.0.1 =
* Initial public release: one-click site connect, chat widget embed, optional WooCommerce connection, and dashboard shortcuts.
* Security: connect and WooCommerce callbacks verify a WordPress nonce, the administrator's permissions, and a one-time connection code before saving anything.

== Upgrade Notice ==

= 1.0.1 =
First public release. Connect your site in one click, with no code to paste.
