=== Kivunly ===
Contributors: liorttt3
Tags: chat, chatbot, ai, assistant, recommendations
Requires at least: 5.8
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 0.2.1
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

A lightweight AI chat widget that guides visitors to your own articles, reviews and products. No cookies, no tracking, no third-party scripts.

== Description ==

Kivunly adds a small chat bubble to your site. Visitors ask what they're looking for, and the AI answers with links to **your own content** — your reviews, articles, categories and products — instead of generic answers.

**Built to be light and private:**

* No cookies. No analytics. No tracking pixels.
* No third-party scripts — all widget code is bundled in the plugin and served from your own site.
* Conversation history lives only in the visitor's browser (sessionStorage) and disappears when the tab session ends.
* Nothing loads on your pages until you enable the widget and configure an endpoint.

**Customizable from the settings page:**

* Bot name, tagline, greeting and teaser bubble
* Suggested-question buttons ("chips")
* Brand colors and logo
* Bottom-left or bottom-right position (RTL-friendly)

**Bring your own AI backend.** Kivunly is the front end; replies come from the chat endpoint you configure — either the hosted Kivunly service (paid, includes automatic indexing of your site's content) or any backend you run yourself that implements the simple request format below.

Learn more about the hosted service at [kivunly.com](https://kivunly.com/).

= Request format (for self-hosted backends) =

The widget sends a POST request with a JSON body to your endpoint:

`{ "message": "...", "history": [ { "role": "user|assistant", "content": "..." } ], "key": "your site key", "page": "https://your-site.com/current-page" }`

and expects a JSON response: `{ "reply": "..." }`. Markdown links and bold in the reply are rendered; everything else is displayed as plain text.

== External Services ==

This plugin connects to the AI chat backend **that you, the site owner, configure** on the settings page. It makes no network requests at all until an endpoint is configured and the widget is enabled.

When a visitor sends a message in the chat widget, the following data is transmitted to the configured endpoint, solely to generate a reply:

* The message text the visitor typed
* The recent conversation history from the current browser session (up to the last 8 messages)
* The URL of the page the visitor is on
* The site key you configured (used by the backend to identify your site)

No other personal data, cookies or identifiers are sent. If you use the hosted Kivunly service (https://kivunly.com/) as your endpoint, its [Terms of Service](https://kivunly.com/terms.html) and [Privacy Policy](https://kivunly.com/privacy.html) apply. If you configure your own backend, you are responsible for its data handling.

The plugin also adds suggested wording to Settings → Privacy for your site's privacy policy.

== Installation ==

1. Install and activate the plugin.
2. Go to **Settings → Kivunly**.
3. Enter your chat endpoint URL and site key, customize the texts and colors, and tick **Enable widget**.
4. The chat bubble appears on your site immediately.

== Frequently Asked Questions ==

= Does the widget slow my site down? =

No. It's one small CSS file and one small JavaScript file, loaded in the footer, with no external dependencies. Nothing at all is loaded until you enable the widget.

= Does it set cookies or track visitors? =

No cookies, no tracking. The conversation is kept in the visitor's own browser for the duration of the tab session only.

= Can I use it in Hebrew, Arabic or another RTL language? =

Yes. All visitor-facing texts are your own settings, and the layout supports RTL sites.

= Do I need an account? =

You need a chat endpoint. You can run your own backend (the request format is documented above), or use the hosted Kivunly service.

== Changelog ==

= 0.2.1 =
* Documentation: explicit Terms of Service and Privacy Policy links for the hosted service in the External Services section.

= 0.2.0 =
* Tappable follow-up suggestions: after each answer the assistant offers 2-3 next questions visitors can tap.

= 0.1.0 =
* Initial release: chat widget, teaser bubble, suggestion chips, settings page, privacy-policy helper.
