=== Storey – Social Media Automation ===
Contributors: storeyhq, slkprojects
Tags: woocommerce, social media, instagram, facebook, automation
Requires at least: 6.0
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 0.9.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Automate Instagram and Facebook posts for your WooCommerce products. Pick what to promote and Storey writes captions and schedules posts.

== Description ==

Storey turns your WooCommerce catalogue into scheduled social media posts on Instagram and Facebook so you can sell without spending your day in caption editors.

After connecting your store, you choose which products you want Storey to promote, link your Meta accounts via OAuth, and Storey's hosted backend generates captions and schedules posts at sensible cadences. You retain full control: select or deselect products at any time, disconnect social accounts in one click, and review every published post inside your WordPress admin.

The plugin itself is a thin client. The heavy work — caption generation, scheduling, OAuth token storage, publishing to Meta — runs on the Storey backend service at api.storeyplugin.co.za. A Storey account and active subscription are required to publish; a 14-day free trial is included.

= What you can do =

* Connect your WooCommerce store to Storey with a single API key.
* Pick which products are eligible for social posting from a familiar WooCommerce-style picker.
* Connect Facebook Pages and Instagram Business accounts via OAuth (no copy-pasting of access tokens).
* Schedule and publish posts automatically — Storey decides timing and writes the captions.
* See connection status, recent posts, and any errors directly inside the WordPress admin.

= How it works =

1. Install and activate the plugin.
2. Use the in-admin onboarding wizard to register or sign in to your Storey account. An API key is provisioned for this site.
3. Select the WooCommerce products you want promoted.
4. Connect Facebook / Instagram from the plugin's Connections page.
5. Storey takes it from there — posting on your schedule, surfaced back to your dashboard.

== Installation ==

1. Upload the `storey` folder to `/wp-content/plugins/` (or install the zip from the WordPress plugin directory).
2. Activate the plugin through the **Plugins** menu in WordPress.
3. Make sure **WooCommerce** is installed and active — Storey will display a notice if it isn't.
4. Open **Storey → Dashboard** in the admin sidebar to launch the onboarding wizard.
5. Follow the wizard to create a Storey account or sign in, then return to the plugin to pick products and connect social accounts.

== Frequently Asked Questions ==

= Do I need a Storey account? =

Yes. The plugin connects to the Storey backend service to generate captions and publish posts. New accounts include a 14-day free trial; after that a paid subscription is required.

= Does this plugin work without WooCommerce? =

No. Storey publishes WooCommerce products, so WooCommerce must be installed and active.

= What data does the plugin send to the Storey backend? =

When you select products for posting, Storey transmits product title, description, price, currency, image URLs, and your store URL so it can generate captions and publish. OAuth tokens for Facebook and Instagram are exchanged via the Storey backend and stored there (not in your WordPress database). Full details are documented under "External services" below and in our Privacy Policy.

= Can I disconnect at any time? =

Yes. You can disconnect any social account from the plugin's Connections page, and you can revoke the Storey API key from the Settings page. Uninstalling the plugin removes all Storey-related options from your database.

= Where do I get support? =

Email support@storeyplugin.co.za or visit https://storeyplugin.co.za.

== External services ==

This plugin relies on the Storey backend service to do its work. Without this service the plugin cannot function.

Found at https://api.storeyplugin.co.za/

**What the service does**

Provides account/license management, caption generation, social-account OAuth, post scheduling and publishing for the plugin. All caption, posting, and OAuth work happens server-side at api.storeyplugin.co.za; the WordPress plugin is a thin client.

**What data is sent and when**

* When you create an account or sign in via the onboarding wizard: your email address, password, and store URL are sent over HTTPS to establish your Storey account and issue an API key.
* When you select products for posting: product title, description, price, currency, image URLs, product IDs, and your store URL are sent so Storey can generate captions and schedule posts.
* When you connect a Facebook or Instagram account: the OAuth flow is initiated by the backend; the access tokens issued by Meta are stored on the Storey backend, not in WordPress.
* When you load admin screens that show status: a short status check is made over HTTPS to verify license validity.
* When you disconnect a social account: a request is sent to revoke the corresponding token server-side.

All requests are authenticated with your site's Storey API key over HTTPS. No data is sent to any third party other than the Storey backend (which in turn talks to Meta and the payment processor on your behalf, as described in our Privacy Policy).

**Terms of Service**: https://storeyplugin.co.za/terms.html
**Privacy Policy**: https://storeyplugin.co.za/privacy.html

== Screenshots ==

1. The Storey dashboard inside the WordPress admin.
2. Selecting products from your WooCommerce catalogue.
3. Connecting Facebook and Instagram accounts.

== Changelog ==

= 0.9.4 =
* readme: trimmed the short description to fit the 150-character limit.

= 0.9.3 =
* readme: added "External services" section documenting the Storey backend, with Terms and Privacy links.
* readme: expanded description, installation, and FAQ sections.
* readme: added wordpress.org username `storeyhq` to Contributors.
* REST: tightened `/products` and `/products/selected` permission callbacks to `manage_woocommerce` or `manage_options` (removed the broader `edit_products` capability).
* Admin: replaced inline arrow-function `sanitize_callback` with a named method.
* Admin: the "Connect your store" notice now appears only on Storey admin pages, not site-wide.

= 0.9.2 =
* Plugin Name updated for clarity; slug aligned to `storey`.

= 0.9.0 =
* First public submission to the WordPress plugin directory.
* Full i18n + escape audit pass.

== Upgrade Notice ==

= 0.9.4 =
Short-description trim only; no code changes.

= 0.9.3 =
Documentation and review fixes; no migrations or breaking changes.
