=== ARIA Commerce ===
Contributors: haiaria
Tags: woocommerce, whatsapp, ai assistant, inventory, orders
Requires at least: 6.0
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.5.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Run your WooCommerce store from WhatsApp and the phone: products from photos, orders, shipping and stock, handled by the ARIA AI assistant.

== Description ==

ARIA Commerce connects your WooCommerce store to [ARIA](https://haiaria.com/), the AI assistant for small businesses.

Once connected, the store owner can:

* **Create products from photos** sent on WhatsApp: ARIA reads size and EAN from the box labels and builds a variable product with one variation per size.
* **Receive every new order on WhatsApp** and mark it as shipped by writing "shipped 123 BRT 0123456789": the customer gets the email with the tracking code.
* **Update stock by voice or chat** ("sold one pair of size 42").
* **Answer customers** about their own orders and product availability, on WhatsApp and by phone.
* **Set different prices per sales channel** (website, Amazon, Zalando, eBay…).

= Secure connection, no passwords =

The plugin generates a one-time **connection code**. The owner pastes it in the ARIA portal: ARIA and the site prove to each other that they know the code (HMAC challenge) and derive the same key. The code itself never travels over the network and is destroyed after use. No WordPress password and no WooCommerce API key are ever shared.

Every request from ARIA is signed with that key (timestamp, one-time nonce and body): old, replayed or altered requests are refused.

= Limited by design =

ARIA can only read and change **products, categories, orders, webhooks, reports, product images and text pages**. It cannot install plugins or themes, manage users or change site settings. Every change is listed in **WooCommerce → ARIA → Latest operations**, and the owner can disconnect ARIA with one click.

== External services ==

This plugin connects to the ARIA service, operated by ARIA (https://haiaria.com/), to let the store owner manage the store through the ARIA assistant.

* **When**: only after the store owner pastes the connection code in the ARIA portal. Before that, the plugin sends and receives nothing.
* **What is exchanged**: the ARIA portal sends signed requests to this site's REST endpoint `/wp-json/aria/v1/` to read and update products, stock and orders, and to upload product images. Order data (customer name, shipping address, phone, items) is read by ARIA to notify the owner and to answer the customer's own questions. WooCommerce order webhooks are created towards `https://portal.haiaria.com/api/webhooks/shop/`.
* **Marketplaces (optional)**: when the owner fills in the Marketplaces form in WooCommerce → ARIA, the plugin sends those keys once, in a signed request, to `https://portal.haiaria.com/api/shop/plugin`; they are not stored in the WordPress database. The same endpoint is called to show which marketplaces are connected. For TikTok Shop the owner is then redirected to TikTok's authorization page.
* **Optional chat widget**: if the owner enables it from the ARIA portal, the plugin adds the ARIA web chat script `https://portal.haiaria.com/aria-site-widget.js` to the site footer. It is off by default.

Terms of service: https://haiaria.com/termini/
Privacy policy: https://haiaria.com/privacy/

== Installation ==

1. Upload the plugin in **Plugins → Add New → Upload Plugin** and activate it.
2. Open **WooCommerce → ARIA** and copy the connection code.
3. In the ARIA portal open **Online store → Connect the site** and paste the code.

== Frequently Asked Questions ==

= Do I need an ARIA account? =

Yes. ARIA Commerce is the connector between your store and the ARIA service; the e-commerce plans are described at https://haiaria.com/.

= Can ARIA change my site's design or settings? =

No. The plugin only allows the operations listed above. Everything else is refused and logged.

= How do I disconnect ARIA? =

Open **WooCommerce → ARIA** and click **Disconnect ARIA**. The key is destroyed immediately and a new connection code is generated.

= Does it work with page caching (LiteSpeed, etc.)? =

Yes. Responses to ARIA are marked as not cacheable.

== Changelog ==

= 1.5.0 =
* Product SEO: Google title and description written by ARIA (also for Yoast, Rank Math and SEOPress); printed on product pages when no SEO plugin is active; editable in the product data.
* Image alt text for product photos.

= 1.4.1 =
* Sends its version to ARIA, shown in the ARIA portal.

= 1.4.0 =
* Mandatory choices before synchronizing: parent catalog, which products (all, categories or a word), out-of-stock yes/no, and what to do with products without brand or department. No hidden defaults.

= 1.3.0 =
* Product synchronization: use this store as the parent catalog and choose, for each marketplace, which products ARIA sends (categories, text, only in stock).
* «Do not send to marketplaces» option on each product.

= 1.2.0 =
* Marketplaces section: connect eBay, Amazon, Zalando and TikTok Shop with your own keys. Keys are sent to ARIA over a signed request and are not stored on the site.

= 1.1.0 =
* Translatable interface (English source, Italian translation included).
* Readme with the external services section.

= 1.0.0 =
* First release: code-based connection, signed requests, operations log, product/order/stock management, optional chat widget.
