=== Egosaru Suggest ===
Contributors: egosaru
Tags: seo, keywords, suggest, search, block editor
Requires at least: 6.0
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.1.0
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Shows search suggestions from the Egosaru Suggest API in the WordPress post editor.

== Description ==

Egosaru Suggest adds a sidebar panel to the WordPress block editor (Gutenberg) that fetches search suggestions from Google, Yahoo, Bing, Amazon, and YouTube — powered by the [Egosaru Suggest API](https://gstudio1.com/egosaru-api/).

**Key features:**

* Get search suggestions for any keyword without leaving the editor
* Supports Google, Yahoo, Bing, Amazon, YouTube
* One-click copy of any suggestion to clipboard
* Results cached 7 days by default (configurable) to stay within free-tier limits
* API key stored server-side — never exposed in HTML or browser JavaScript
* Works on any public post type

**This plugin requires a free API key from gstudio1.com.**

= External Service =

This plugin sends search terms to the Egosaru Suggest API hosted at **gstudio1.com**. Requests are made server-side (PHP). Your API key and the keywords you type are sent to this service.

* [Terms of Service](https://gstudio1.com/api/terms/)
* [Privacy Policy](https://gstudio1.com/api/privacy/)

No personal data, post content, or user information is transmitted. Only the keyword you enter in the sidebar panel is sent.

= Free Tier Limits =

* 30 requests / minute
* 1,000 requests / day
* 20 new keywords / day per source

Results are cached server-side, so repeated searches for the same keyword do not consume quota.

== Installation ==

1. Upload the `egosaru-suggest` folder to `/wp-content/plugins/`.
2. Activate the plugin in **Plugins → Installed Plugins**.
3. Go to **Settings → Egosaru Suggest** and enter your API key.
4. Block editor: click the Egosaru Suggest icon in the top-right toolbar (or the three-dot menu, then Plugins, then Egosaru Suggest). Classic editor: use the **Egosaru Suggest** box in the right column.

== Frequently Asked Questions ==

= Where do I get an API key? =

Register for a free key at [gstudio1.com/egosaru-api/](https://gstudio1.com/egosaru-api/).

= Is my API key safe? =

Yes. The key is stored in `wp_options` and all API requests are made server-side via `wp_remote_get`. It is never included in any HTML output or JavaScript variable sent to the browser.

= Can I use it with the classic editor? =

Yes (since 1.1.0). In the classic editor, an "Egosaru Suggest" box appears in the right column of the post edit screen. In the block editor, use the sidebar panel instead.

= Why do I sometimes see a "queued" state? =

The Egosaru API processes some requests asynchronously. The plugin polls automatically for up to 10 attempts. This is normal and usually resolves within a few seconds.

== Screenshots ==

1. The Egosaru Suggest sidebar panel in the block editor.
2. Settings page under Settings → Egosaru Suggest.

== Changelog ==

= 1.1.0 =
* Added classic editor support (meta box).
* Fixed searches never finishing for new keywords (polling interval is now 5 seconds).
* Fixed non-ASCII keywords being double-encoded in API requests.
* The block editor script is no longer loaded on classic editor screens.
* Shows up to 100 suggestions.

= 1.0.0 =
* Initial release.

== Upgrade Notice ==

= 1.0.0 =
Initial release.
