=== Astroworld Tools ===
Contributors: astroworld
Tags: images, compression, webp, background removal, media
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Bring the Astroworld image tools into wp-admin: compress images, convert to WebP, and remove backgrounds straight from the Media Library.

== Description ==

Astroworld Tools connects your WordPress site to the Astroworld Convert API (https://convert.astroworldmc.com) so you can optimize images without leaving wp-admin.

Phase 1 features, available now:

* Compress JPEG and PNG images in place from the Media Library.
* Convert JPEG and PNG images to WebP, saved as new attachments.
* Remove image backgrounds, saved as new PNG attachments.
* Bulk actions on the Media Library list view.
* A single image "Optimize with Astroworld" row action and an attachment meta box for one click compression.
* A "Test connection" button on the settings screen that reports your plan and monthly usage.

All API calls run server side using the WordPress HTTP API. Your API key is stored in the WordPress database and is never written to logs.

Coming soon (planned, not yet functional):

* PDF tools (merge, split, compress).
* AI writing assistant in the Gutenberg editor.
* WooCommerce bulk product image optimization.

== Installation ==

1. In wp-admin go to Plugins, then Add New, then Upload Plugin.
2. Choose astroworld-wp-tools.zip and click Install Now.
3. Activate the plugin.
4. Go to Settings, then Astroworld Tools, and paste your API key (it looks like awk_...).
5. Click Test connection to confirm the key works.
6. Open the Media Library in list mode to use the bulk actions, or open any image to use the meta box.

== Frequently Asked Questions ==

= Where do I get an API key? =

Contact Astroworld for a Convert API key. The key starts with awk_.

= Which file types are supported in Phase 1? =

JPEG and PNG images. Files larger than 50 MB are skipped.

= Does compression overwrite my original image? =

Yes. The Compress action replaces the original file in place and regenerates its thumbnails. WebP conversion and background removal create new attachments and leave the original untouched.

= Where do WebP and background removed images go? =

They are added to your Media Library as new attachments in the standard uploads directory.

== Screenshots ==

1. The settings page with the API key field and Test connection button.
2. The Media Library bulk actions menu.
3. The attachment meta box with the Compress now button.

== Changelog ==

= 1.0.0 =
* Initial release.
* Phase 1: Media Library compression, WebP conversion, and background removal via the Astroworld Convert API.
* Settings page with API key, base URL, default quality, and a Test connection button.
* Roadmap section listing the planned Phase 2 to Phase 4 features as coming soon.

== Upgrade Notice ==

= 1.0.0 =
First release of Astroworld Tools.
