=== MarketSync Beacon Customer ===
Contributors: marketsync
Tags: analytics, campaign tracking, download tracking, woocommerce
Requires at least: 6.0
Requires PHP: 7.4
Stable tag: 0.1.11
License: GPLv2 or later

Standalone WordPress visitor analytics with optional WooCommerce tracking and optional central MarketSync Beacon Server sync.

== Installation ==
1. Install this ZIP in WordPress > Plugins > Add New > Upload Plugin.
2. Activate MarketSync Beacon Customer and open MarketSync Beacon in the WP sidebar.
3. Open Settings & Diagnostics. Browser events and managed downloads can be tested locally without the Server.
4. On your central WordPress install, also activate MarketSync Beacon Server; pairing is automatic on the next request.
5. On a remote WordPress installation, click Register / Sync now in Settings & Diagnostics. The Customer uses the internally configured https://marketsyncpro.com/ server URL (existing endpoint values are preserved), proves ownership through its public WordPress REST API over HTTPS, and automatically registers without a pairing code. If temporarily unavailable, registration retries via the existing scheduler.
6. Beacon no longer displays its own cookie warning. The main event-tracking switch remains in Settings & Diagnostics. The tracker uses first-party attribution storage and honors supported browser privacy signals. Site owners must configure any required external consent management and maintain accurate privacy disclosures before public deployment.
7. Register a same-site ZIP under Downloads. Replace only the desired download button target with the generated tracked URL; original direct URLs are not tracked.
8. Create advertising campaigns under Advertising. Copy the generated branded /go/<campaign-code>/ link; it redirects to the saved landing page without showing UTM parameters. Previously issued long UTM URLs remain valid.

== Data and limits ==
Tracks client-rendered pages, generic element clicks, attributed download requests and optional WooCommerce cart/paid-order events. Stores visitor session pseudonyms and first-party attribution information, not raw IP addresses or form field contents. Does NOT confirm completed downloads or installs. WP-Cron queues run on site traffic; high reliability requires a real server scheduler. Ads API integration, fully verified conversion attribution, refund reconciliation and plugin installation reconciliation are future work.

== Changelog ==
= 0.1.0 =
Independent developer build. No live WordPress site or server integration test performed.

= 0.1.1 =
Customer admin UI: hide Server URL without changing pairing; add downloads and advertising instructions; paginate Pages & Clicks and Traffic Sources (25/50).

= 0.1.2 =
Advertising report: independent UTC date-range controls for page views, download requests, purchases and revenue (7/30/90 days, all available, custom dates). ROAS is based on the selected revenue period divided by lifetime declared campaign spend in USD; the spend is not date-apportioned.

= 0.1.3 =
One-click self-service site registration with public HTTPS ownership verification and automatic retry; pairing-code entry removed from Customer settings. Existing site credentials and all analytics/tracking features preserved.

= 0.1.4 =
Fix automatic registration when the internally configured Server URL is missing/empty, retaining existing custom URLs and securely persisting the default after successful registration.

## 0.1.5 updates
 - Added Software Updates and Other Software tabs with server-published catalog, installation status, package download and explicit one-click install/update.
 - Added native WordPress plugin-update discovery and six-hour catalog refresh with authenticated Beacon registration.
 - Software ZIP downloads are SHA-256-verified, and local Server/Customer installations avoid an HTTP loopback.
 - No changes to analytics collection, campaign tracking, or sync registration.

= 0.1.6 =
Pages & Clicks and Traffic Sources have UTC date filters (7/30/90 days, custom or all available) and full matching aggregated CSV exports, independent of 25/50-row pagination. Downloads has matching date filters and a full matching CSV report. Advertising has CSV exports using the existing independently selected date ranges, and one-click clipboard copy for campaign tracking links. Dashboard raw-event export and all tracking/registration code are unchanged.

= 0.1.7 =
Added a built-in Allow analytics / Decline visitor opt-in banner when consent is required. An accepted visitor starts tracking the current UTM landing page immediately. Declined visitors remain untracked; Do Not Track and Global Privacy Control remain respected. Renamed the Downloads form placeholder to Digital Product without altering stored field names or download handling.

= 0.1.8 =
Renamed Downloads tab to Digital Products. Consent acceptance says Accept Cookies; declining clears attribution and returns to a safe referring URL or browser history when available (with no-referrer fallback). Added scoped, confirmed per-row deletion for campaigns, digital-product registrations, page/click reports and traffic-source reports. Deletions queue for authenticated Server replay during outages; deleting a product disables its tracked link. Campaign metadata and declared spend synchronize for central campaign performance reporting (Server v0.1.4 required). Existing registration, software updates and analytics event collection remain intact.

= 0.1.9 =
Removed the built-in cookie warning and opt-in gate in both frontend tracking and WooCommerce recording, including previously persisted opt-in choices; kept the event-tracking toggle and browser privacy-signal checks. No registration, synchronization, reports, or database table changes.

= 0.1.10 =
Generate branded /go/<campaign-code>/ tracking URLs for existing and new campaigns, with a clean landing-page redirect and first-party campaign attribution. Reuse the existing campaign table and reports, and prefer the freshly set attribution cookie over stale browser session data. Old UTM URLs remain supported. No Server plugin changes required.

= 0.1.11 =
Dashboard: show up to 50 individual recent events with their original event-page URL, tracked clicked-link destination when available, and UTC date/time. Newly tracked link clicks store the URL origin and path (no query strings or fragments) in the existing event label field. All stored events, report totals, CSV export, databases, synchronization, and other report tabs retain their prior behavior.
