=== UP SEO Assistant ===
Contributors: sobiluciano
Tags: seo, ai, google-search-console, keyword-research, schema
Requires at least: 5.8
Requires PHP: 7.4
Tested up to: 6.7
Stable tag: 1.4.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

AI-powered SEO assistant. Analyzes your real GSC data to find quick wins, optimize high-value pages, and make your brand visible in AI-generated answers.

== Description ==

**UP SEO Assistant** is an advanced WordPress plugin that uses artificial intelligence (Google Gemini and Anthropic Claude) to analyze your website and find the most concrete SEO growth opportunities — based on your real data, not generic advice.

Unlike traditional SEO plugins that stop at meta tags, UP SEO Assistant connects to your **Google Search Console** data and analyzes **real content** and **search intent** to surface actionable improvements that move the needle.

The plugin is built on a **Serviceware model**: all AI processing runs on the UP-SEO SaaS server (up-seo.it). No AI happens locally, no API keys required to get started, and all feature limits are managed server-side. You can activate a **free 7-day trial** directly from the plugin settings with one click.

= What makes it different =

Most SEO plugins tell you *what* is wrong. UP SEO Assistant tells you *what to do* — with specific, prioritized actions tied to pages that already have traffic potential in your Google Search Console.

= Features =

* **Value Page Analysis**: Identify which pages have the highest potential to drive sales or leads, and get a prioritized action plan for each.
* **AI On-Page Audit**: Receive specific, page-level suggestions based on CRO (Conversion Rate Optimization) and search intent signals.
* **GSC Quick Wins**: Connect your Google Search Console and instantly surface pages ranking on page 2 with high impressions — the fastest wins available.
* **SERP Reverse Engineering**: Analyze the top search results for any keyword and extract a winning content formula to outrank them.
* **AI-Proof Content**: Find content angles that AI-generated answers cannot replicate, based on your real GSC data and sitemap. Includes an AI writer to produce that content.
* **AI Writer**: Generate full SEO-optimized articles with H1/H2/H3 structure, meta title, and meta description in one click.
* **Niche Keyword Finder**: Discover high-intent keywords and competitor gaps in your niche with search volume and intent data.
* **Auto FAQ Schema**: Automatically scan your content, generate FAQPage structured data, and inject it in the footer — no manual work required.
* **Internal Linker**: AI-powered internal link suggestions based on your actual published content and target keywords.
* **GEO/AEO Strategy**: Generate a complete strategic document to make your brand visible in AI-generated answers (ChatGPT, Claude, Gemini, Perplexity, Google AI Overviews). Includes live site discovery, an editorial plan, off-site authority actions, robots.txt and llms.txt templates, schema priorities, KPIs, and a 12-month roadmap.

== External Services ==

This plugin connects to the following external services to provide its core functionality:

**1. UP-SEO SaaS Server (up-seo.it)**
Used for: All AI-powered analyses (SEO audit, keyword research, content suggestions, SERP analysis, AI Writer, AI-Proof content, internal linking, GEO/AEO strategy). The plugin sends your website URL, Google Search Console data (page URLs, clicks, impressions, positions), and content snippets to our server for processing. The plugin never contacts this server automatically or in the background: the very first connection only happens after you explicitly click "Attiva il trial gratuito" (Activate free trial) on the Settings tab, or enter a license key. After that explicit action, the plugin periodically checks your trial/license status to keep it in sync, and sends data whenever you trigger an analysis from the plugin dashboard. The server acts as a proxy to the AI providers listed below: the plugin never contacts them directly, except for the optional Gemini key validation described in section 2.
- Service URL: https://www.up-seo.it
- Terms of Service: https://www.up-seo.it/termini-di-servizio-plugin/
- Privacy Policy: https://www.up-seo.it/cookie-policy/

**2. Google Gemini API (Google LLC)**
Used for: AI-powered content analysis, SEO suggestions, and content generation. Requests are routed through the UP-SEO SaaS server. If you provide your own Gemini API key in the settings, the plugin also calls the Gemini API directly to validate the key.
- Service URL: https://ai.google.dev/
- Terms of Service: https://ai.google.dev/gemini-api/terms
- Privacy Policy: https://policies.google.com/privacy

**3. Anthropic Claude API (Anthropic PBC)**
Used for: The GEO/AEO Strategy feature only. When you trigger this analysis, the UP-SEO server sends your website URL to Claude, which visits your public pages and performs web searches about your brand, niche and competitors in order to write the strategic document. Requests are routed exclusively through the UP-SEO SaaS server; the plugin never contacts Anthropic directly and no API key is stored in the plugin. Only publicly accessible information about your website is processed, and only when you explicitly start the generation.
- Service URL: https://www.anthropic.com/
- Terms of Service: https://www.anthropic.com/legal/commercial-terms
- Privacy Policy: https://www.anthropic.com/legal/privacy

**4. DataForSEO API (DataForSEO LLC)**
Used for: Search engine results data and keyword metrics that power the SERP Reverse Engineering and Niche Keyword Finder features (organic SERP results, keyword ideas, search volume, search intent). When you run one of these analyses, the UP-SEO server sends the keyword you typed together with the target language and country. Requests are routed exclusively through the UP-SEO SaaS server; the plugin never contacts DataForSEO directly. No personal data and no content from your website is sent to this service.
- Service URL: https://dataforseo.com/
- Terms of Service: https://dataforseo.com/terms-of-service
- Privacy Policy: https://dataforseo.com/privacy-policy

**5. Google Search Console API (Google LLC)**
Used for: Fetching real traffic data (clicks, impressions, rankings) for your website to power GSC-based analyses. Authentication is handled via OAuth2 through the UP-SEO server. Data is retrieved only when you connect your GSC account and trigger an analysis.
- Service URL: https://search.google.com/search-console/
- Terms of Service: https://developers.google.com/terms
- Privacy Policy: https://policies.google.com/privacy

== Installation ==

1. Upload the `up-seo-assistant` folder to the `/wp-content/plugins/` directory.
2. Activate the plugin via the 'Plugins' menu in WordPress.
3. Go to the new 'UP SEO Assistant' menu in the WordPress admin sidebar.
4. Follow the Quick Setup wizard to connect your Google Search Console account.
5. Once connected, all features are immediately available from the dashboard.

== Frequently Asked Questions ==

= Do I need an API key to get started? =
No. The plugin connects to the UP-SEO SaaS server (up-seo.it) which handles all AI processing. You can activate a **free 7-day trial** directly from the plugin Settings tab with one click — no API key, no credit card required. Optionally, you can provide your own Google Gemini API key if you prefer to use your own quota.

= Do I need to connect Google Search Console? =
Several features (Quick Wins, AI-Proof Content, Pages at Risk of AI Overviews) require a GSC connection to work with your real traffic data. Other features like SERP Reverse Engineering, AI Writer, and Niche Keyword Finder work without GSC. You can connect GSC via OAuth in the Quick Setup wizard.

= Is the plugin fully functional without a paid plan? =
Yes — all features are available during the free trial. After the trial, feature access depends on your UP-SEO plan. All limits are enforced server-side; the plugin code itself has no artificial restrictions.

= What data is sent to external servers? =
Only when you explicitly trigger an analysis: your website URL, GSC performance data (page URLs, clicks, impressions, positions), and content snippets are sent to the UP-SEO SaaS server. The server then forwards only what is needed for each feature: Google Gemini for most AI analyses, Anthropic Claude for the GEO/AEO Strategy, DataForSEO for SERP and keyword data (keyword + language + country only). **Nothing is sent automatically in the background.** See the External Services section for full details.

= Does it work with any theme or page builder? =
Yes. The plugin adds a standalone dashboard to the WordPress admin. It does not modify your front-end theme or interact with page builders. The Auto FAQ Schema feature injects structured data in the `wp_footer` hook, which is compatible with all standard WordPress themes.

= Does it support languages other than English? =
Yes. The AI analysis works in any language supported by Google Gemini. You configure the target language when running analyses. The plugin interface is in English; Italian support is planned.

= Does it support search engines other than Google? =
Currently the plugin is optimized for Google and uses Google Search Console data. Bing and other engines are not supported.

== Screenshots ==

1. Main dashboard — value page analysis with prioritized action plan.
2. GSC Quick Wins — pages on page 2 with high impressions, ready to rank.
3. SERP Reverse Engineering — content formula extracted from top 10 results.
4. AI-Proof Content — unique angles based on your real GSC data.
5. AI Writer — full article generation with H1/H2/H3, meta title and description.
6. GEO/AEO Strategy — complete document for AI answer visibility.
7. Quick Setup wizard — connect Google Search Console in minutes.

== Changelog ==

= 1.4.0 =
* **New**: GEO/AEO Strategy tab — generates a complete strategic document to make your brand visible in AI-generated answers (ChatGPT, Claude, Gemini, Perplexity, Google AI Overviews). Includes live site discovery, editorial plan, off-site actions, robots.txt/llms.txt templates, schema priorities, KPIs, and a 12-month roadmap.
* **New**: Free trial activation now requires explicit user consent — the plugin stays completely silent until you click "Activate free trial" on the Settings tab or enter a license key. No background registration on activation.
* Added Anthropic Claude API and DataForSEO API declarations to the External Services section.
* Added GEO/AEO section to the built-in plugin guide.
* Security: improved output escaping for AI-generated content throughout the plugin.
* Security: JSON-LD schema output now uses JSON_HEX_TAG to prevent script injection edge cases.

= 1.3.0 =
* **New**: SERP Reverse Engineering — analyze top 10 results for any keyword and extract a winning content formula.
* **New**: AI-Proof Content tab — finds unique content angles that AI-generated answers cannot replicate, based on your real GSC data.
* **New**: AI Writer — generates full SEO-optimized articles from AI-Proof content angles.
* **New**: Pages at Risk of AI Overviews detection in the GSC tab.
* **New**: Built-in plugin guide modal with 11 sections covering all features.
* Major UI redesign with floating button navigation.
* All functionality limits enforced server-side (Serviceware model — no artificial limits in plugin code).
* Full Plugin Check compliance: fixed date functions, escaping, and text domain issues.
* Updated Chart.js to v4.5.1.

= 1.2 =
* Improved server-side security for the Niche Finder.
* Added support for the unlimited Sandbox plan.
* Fixed FAQ suggestion system for pages with thin content.

= 1.1 =
* Integration with Gemini 2.0 Flash for faster AI responses.
* New SEO progress visualization in the dashboard.

= 1.0 =
* Initial release.
