=== MightWork Leads ===
Contributors: mightwork
Tags: leads, crm, woocommerce, mightwork
Requires at least: 6.5
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.0.1
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Send new WooCommerce order contacts to your MightWork Leads inbox.

== Description ==

MightWork Leads connects your store to the MightWork service. It creates and manages one WooCommerce Order created webhook. Contact details from new orders appear in your workspace's Leads inbox. Existing orders are not imported.

The plugin is free to install directly. A MightWork account and a plan with Leads Connector are required. No paid WooCommerce subscription or Woo Marketplace listing is required for direct ZIP installation.

= External service and privacy =

Nothing is sent until a store manager enters an endpoint and secret and enables delivery. Each new order sends its ID and billing first name, last name, email, phone and company to https://app.mightwork.us. Products, totals, billing address, payment data, IP addresses and marketing consent are not sent by this plugin. Orders without an email do not create a lead. An order never grants marketing consent.

MightWork terms: https://mightwork.us/terms
MightWork privacy: https://mightwork.us/privacy
Support: https://mightwork.us/contact

The webhook secret is stored using WooCommerce's native webhook storage. Protect your WordPress database and backups. Delivery uses WooCommerce's native asynchronous webhook system and logs. The MightWork receiver verifies the signature and deduplicates orders.

Installation guide with screenshots: https://mightwork.us/docs/woocommerce

== Installation ==

1. Install and activate WooCommerce 9.0 or later on an HTTPS store.
2. Open Plugins > Add New > Upload Plugin and upload mightwork-leads.zip. Activate it.
3. In MightWork, open Connections > Leads Connector > WooCommerce. Enter your store URL and a strong signing secret. Save and copy the endpoint.
4. In WordPress, open WooCommerce > Settings > Integration > MightWork Leads.
5. Paste the endpoint and the same secret. Enable delivery and save.
6. Place a test order with an email address in a test store. Verify exactly one lead in MightWork.

== Frequently Asked Questions ==

= Does this require a WooCommerce subscription? =
No. Direct plugin installation does not use a paid WooCommerce subscription. Your MightWork service plan is separate.

= What happens on pause or deactivation? =
Unchecking Enable pauses the webhook. Deactivation deletes the managed webhook and disables delivery. Reactivation requires entering the secret and enabling again. Existing orders and MightWork leads stay intact. Queued requests may already be in flight.

= What happens after delivery failures? =
WooCommerce can disable a webhook after repeated failures. Check its delivery logs, fix the connection, and save the settings to enable it again. Missed orders are not automatically replayed.

= Does it work with HPOS and checkout blocks? =
The plugin uses WooCommerce order APIs and native order.created webhooks. It declares HPOS compatibility and has no checkout UI.

== Changelog ==

= 1.0.1 =
* Add verified WordPress compatibility and publisher metadata for directory review.
* Use the plugin's full prefix for uninstall variables.

= 1.0.0 =
* Initial release with managed order webhook, minimal contact payload and pause/deactivation cleanup.
