=== Carticy Conversion Tracking with GA4, Google Ads, and Meta Pixel for WooCommerce ===
Contributors: carticy, alikhallad
Donate link: https://alikhallad.com/donations/donation-form/
Tags: woocommerce, conversion tracking, google analytics, meta pixel, google ads
Requires at least: 6.0
Tested up to: 7.0
Requires PHP: 8.0
WC requires at least: 8.0
WC tested up to: 10.4.3
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Reliable, consent-respecting WooCommerce conversion tracking for GA4, Google Ads, and Meta Pixel - tracked from the order, not the thank-you page.

== Description ==

Carticy Conversions for WooCommerce tracks purchases from WooCommerce's authoritative order-paid signals (`woocommerce_payment_complete` plus paid-status fallbacks), so conversions are recorded even when a customer never returns from an off-site payment gateway. Classic, shortcode, and block (Store API) checkout are all supported.

The free plugin includes:

* Client-side GA4, Google Ads, and Meta Pixel tracking from merchant-supplied IDs (direct tag injection, or an optional GTM dataLayer mode with a generated import container).
* Purchase events deduplicated by order id across every layer (`transaction_id` for GA4, `eventID` for Meta), plus add-to-cart and begin-checkout events.
* Consent-respecting behavior out of the box: multi-source consent intake (WP Consent API, Google Consent Mode v2, common CMP cookies, a first-party hook), a tri-state consent record stored per order, and default-deny before any tag loads.
* Duplicate-tag detection so an existing GA4/Pixel/GTM setup is never silently double-fired.
* WordPress privacy tooling: personal data exporter and eraser coverage, configurable IP anonymization, and a data retention window.

Server-side delivery - Meta Conversions API and GA4 Measurement Protocol with retries, refund and subscription-renewal events - is part of the Pro build and is excluded from the WordPress.org package.

This plugin does not make your store GDPR compliant by itself; it is consent-gated and ships GDPR tooling, while compliance remains the store's responsibility.

== Installation ==

1. Upload the plugin files to `/wp-content/plugins/carticy-conversions-for-woocommerce/`.
2. Activate the plugin through the Plugins menu in WordPress.
3. Make sure WooCommerce is active.
4. Add your GA4 Measurement ID, Google Ads conversion ID/label, or Meta Pixel ID to enable tracking. No events are sent before you configure a destination.

== Frequently Asked Questions ==

= Does this version send tracking events? =

Yes - once you configure at least one destination (GA4, Google Ads, or Meta Pixel) with your own IDs. Nothing is sent before a destination is configured, and events respect the visitor's stored consent.

= Does the WordPress.org package include Pro server-side providers? =

No. Premium server-side provider implementation paths are excluded from the WordPress.org artifact.

= Does the plugin make outbound HTTP requests on activation? =

No. The plugin does not contact Google, Meta, or Carticy on activation. Google/Meta requests happen only after you configure the matching destination and the visitor's consent allows them. Freemius may be loaded for licensing and upgrade handling according to its WordPress.org-compliant opt-in flow when the SDK is present.

= Does it work with the block (Store API) checkout? =

Yes. Purchases are tracked from WooCommerce's server-side order-paid hooks, which fire identically for classic, shortcode, and block checkout.

== Screenshots ==

1. Guided setup in about two minutes. No developer needed, and the plugin handles Tag Manager for you.
2. Choose what you track: GA4 analytics, Google Ads conversions, and the Meta Pixel.
3. Paste your IDs with an inline "Where do I find this?" walkthrough and real screenshots for every field.
4. Consent-aware by design. Pick your store's consent posture, and nothing is sent to Google or Meta without permission.
5. Honest verification: setup only completes when a real purchase is tracked, never a hardcoded green check.
6. The Home dashboard shows measured tracking health, per-platform status, and the payment-gateway accuracy check.
7. Server-side tracking (Pro): Meta Conversions API and GA4 Measurement Protocol fire from your server, deduplicated by order ID.

== Changelog ==

= 1.0.0 =
* Order-paid purchase tracking engine with per-destination idempotency.
* Client-side GA4, Google Ads, and Meta Pixel tracking (direct and GTM dataLayer modes).
* Multi-source consent intake with per-order tri-state consent records.
* Identity and attribution capture (client id, click ids, UTM first/last touch).
* WordPress privacy exporter/eraser, IP anonymization, retention purge.
* WooCommerce HPOS and cart/checkout block compatibility.

== Source Code ==

This plugin ships entirely in human-readable form. None of its code is minified or obfuscated, so the files included in the download are the source.

== Third-Party Services ==

This plugin integrates with the following services when the merchant configures them. No data is sent to any service before the merchant supplies that service's IDs and the visitor's stored consent allows it:

**Google Analytics, Google Ads, and Google Tag Manager**
* Service URLs: https://analytics.google.com/, https://ads.google.com/, https://tagmanager.google.com/
* Used for: conversion measurement and ecommerce event tracking when the merchant configures Google destinations.
* Data sent: ecommerce event data such as order ID, value, currency, item data, and consent-gated identifiers when the related feature is implemented and configured.
* Terms: https://policies.google.com/terms
* Privacy Policy: https://policies.google.com/privacy

**Meta Pixel**
* Service URL: https://www.facebook.com/business/tools/meta-pixel
* Used for: Meta advertising conversion measurement when the merchant configures Meta destinations. Server-side Meta Conversions API delivery is part of the Pro build and is not included in this package.
* Data sent: ecommerce event data such as order ID, value, currency, item data, and consent-gated identifiers when the related feature is implemented and configured.
* Terms: https://www.facebook.com/legal/terms
* Privacy Policy: https://www.facebook.com/privacy/policy/

**Freemius**
* Service URL: https://freemius.com/
* Used for: licensing, upgrade handling, and opt-in software usage services.
* Data sent: only data covered by the Freemius SDK permission and opt-in flow.
* Terms: https://freemius.com/terms/
* Privacy Policy: https://freemius.com/privacy/
