=== CrazyBot – AI Chatbot & Lead Capture ===
Contributors: crezvatic
Tags: chatbot, ai chatbot, live chat, lead generation, whatsapp
Requires at least: 5.8
Tested up to: 6.6
Requires PHP: 7.4
Stable tag: 1.1.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Connect your CrazyBot account and add your AI chatbot to WordPress: capture leads, answer questions with AI and book appointments, without editing your theme.

== Description ==

CrazyBot turns website visitors into leads. Build the conversation in the CrazyBot dashboard (visual flow builder + AI answers), then use this plugin to show it on your WordPress site:

* Connect with CrazyBot in one click: sign in, pick your bot, done. No code to copy, no theme or footer editing, survives theme updates.
* See your bot, plan and quick links (edit bot, leads, plan & billing) right in Settings → CrazyBot.
* Shows on every page, with exclusions (e.g. `/checkout`, `/my-account/*`, page IDs).
* Option to hide the chat while you're logged in as an administrator.
* One-click test link that runs the bot without creating real leads.
* Lightweight: the chat script loads in the footer with `defer`.

You need a CrazyBot account. New? Click Connect and choose Create an account: you set up your bot and plan on https://crazybot.crezvatic.com, then come back to finish.

== Installation ==

1. Install and activate the plugin (Plugins → Add New → upload the zip, or search "CrazyBot").
2. Go to **Settings → CrazyBot** and click **Connect with CrazyBot**.
3. Sign in to CrazyBot (or create an account and a bot), pick the bot for this site and click **Connect**.
4. Back in WordPress you'll see **Connected**. Visit your site: the chat bubble appears in the corner.

Prefer not to connect? Paste your bot's embed code (CrazyBot → your bot → Share) into "Embed code or Bot ID" and save. Clear your caching plugin's cache after connecting.

Full guide with troubleshooting: https://crazybot.crezvatic.com/docs/wordpress

== Frequently Asked Questions ==

= Does it work with my theme / page builder? =
Yes. It adds the chat through WordPress's standard script loading, so it works with any theme and with Elementor, Divi, Gutenberg and others.

= Where do I change what the bot says? =
In your CrazyBot dashboard. Changes go live immediately — no need to touch WordPress.

= Can I hide the chat on some pages? =
Yes — list paths (`/checkout`), sections (`/shop/*`) or page IDs under "Don't show on".

== External services ==

This plugin loads the CrazyBot chat widget from the CrazyBot server (by default https://crazybot.crezvatic.com, or the server in your embed code). When you click Connect, your browser opens that server to sign in, and this site's address is sent so the bot can be linked to it; the plugin then asks the server (from your WordPress server) for the connected bot's name, your plan name and account email to show on the settings page, and tells it when you disconnect or delete the plugin. The widget script is requested on every front-end page where the chat is shown, and messages your visitors type in the chat — plus what they enter in it, such as name, email or phone — are sent to that server to reply and to save leads for the site owner. The page URL and basic browser details are sent with each chat.

Service terms: https://crazybot.crezvatic.com/terms
Privacy policy: https://crazybot.crezvatic.com/privacy

== Changelog ==

= 1.1.0 =
* Connect with CrazyBot: sign in (or sign up) and pick your bot instead of copying an embed code.
* Settings page shows the connected bot, your plan and links to edit the bot, see leads and manage billing.
* Change bot and Disconnect buttons; deleting the plugin also disconnects the site.

= 1.0.1 =
* Link to the full setup guide and troubleshooting from the settings page.

= 1.0.0 =
* First release: paste embed code or Bot ID, page exclusions, hide for admins, test link.
