=== AI Poster Client ===
Contributors: Andrii Syrtsov
Tags: ai, content, gpt, automation, saas
Requires at least: 6.0
Tested up to: 6.9
Requires PHP: 8.0
Stable tag: 1.2.40
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Client-side WordPress plugin for connecting websites to the AI Poster SaaS platform via REST API.

== Description ==

AI Poster Client is a client-side WordPress plugin designed to securely connect your website to the AI Poster SaaS platform.

The plugin acts as a bridge between your WordPress installation and the AI Poster API server, allowing you to:
- register and authenticate your site,
- manage API credentials,
- send content generation tasks,
- receive task statuses,
- manage prompts and settings from the WordPress admin panel.

Important:
This plugin does NOT generate content locally.
All AI processing is performed on the AI Poster server via secure REST API requests.

= Security & Architecture =

AI Poster Client is built with a security-first SaaS architecture in mind:

- Client and server operate on different domains
- All requests are authenticated using:
  - client_id
  - api_key
  - site_uuid
- Domain validation is performed server-side
- Encrypted storage is used for sensitive credentials
- No AI keys are stored in plain text
- No public endpoints are exposed

The plugin does not modify WordPress core behavior and does not expose any public-facing functionality.

= Usage =

After activation and connection:

- Use the admin interface to manage connection status
- Create and manage content tasks
- Monitor server availability
- Manage prompts and configuration
- Publish generated content to your site

All actions are performed asynchronously via the AI Poster API.

= Uninstall =

By default, uninstalling the plugin does NOT remove stored data.

This behavior is intentional and allows safe reinstallation without losing the site connection.

To fully remove all plugin data:
1. Enable the "Purge data on uninstall" option in plugin settings.
2. Deactivate and uninstall the plugin.

When enabled, the uninstall process removes:
- stored options
- encrypted credentials
- site UUID
- plugin-specific settings

No user content or posts are ever deleted.

= Multisite Compatibility =

AI Poster Client fully supports WordPress Multisite.

- Each site is registered independently
- Site-specific UUIDs are used
- Uninstall cleanup runs per site

== Installation ==

1. Upload the `ai-poster-client` folder to the `/wp-content/plugins/` directory
   OR install via ZIP archive in the WordPress admin panel.
2. Activate the plugin through the "Plugins" menu in WordPress.
3. Open "AI Poster Client" in the WordPress admin menu.
4. Register or connect your site to the AI Poster server.
5. Complete the setup wizard to start using the service.

== Frequently Asked Questions ==

= Does this plugin work without the AI Poster server? =
No. This plugin is a client component and requires an active AI Poster server.

= Does the plugin store OpenAI or AI keys locally? =
No. All sensitive keys are encrypted or stored server-side.

= Will uninstall delete my posts or content? =
No. The plugin never deletes posts or generated content.

= Is this plugin safe for production use? =
Yes. The plugin is designed for production SaaS environments and follows WordPress security best practices.

== Changelog ==

= 1.2.11 =
* Security hardening
* Improved uninstall logic
* Internal refactoring
* Performance optimizations

== Notes ==

This plugin is part of the AI Poster SaaS ecosystem.
Only the official AI Poster server API is supported.
