=== Lexiata Checkout Fees ===
Contributors: mrsureshlk
Tags: woocommerce, payment gateway, fees, discounts, checkout
Requires at least: 6.4
Tested up to: 6.9
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Add custom fees or discounts to WooCommerce payment gateways with conditional logic by gateway, country, category, or cart total.

== Description ==

**Lexiata Checkout Fees** lets you charge an extra fee or apply a discount on the checkout page based on which payment gateway your customer chooses.

Common use cases:

* Charge a Cash on Delivery handling fee
* Pass on payment processor fees (e.g. 2.9% for Stripe)
* Offer a discount for customers who pay by direct bank transfer
* Add a flat surcharge for international payment methods
* Apply gateway fees only to specific product categories or countries

= Key features =

* Two fee slots per gateway — combine a flat handling fee with a percentage processing fee
* Fixed amount or percent of cart
* Min and max fee bounds
* Coupon-aware rules (apply only when no coupons / only when coupons present)
* Country and state include / exclude lists
* Product category include / exclude lists
* Min and max cart amount thresholds
* Per-product gateway fee overrides
* Global caps on total fees and total discounts per order
* Optional taxable fees with tax class selection
* Multiple rounding strategies
* HPOS (High-Performance Order Storage) compatible
* Cart Block and Checkout Block compatible
* Translation ready

= Built for WooCommerce 2026 =

This plugin is built against the latest WordPress and WooCommerce architecture: HPOS, Cart Block, Checkout Block, and StoreAPI extension callbacks. No tracking, no upsells, no third-party calls — just clean code that does one job well.

== Installation ==

1. Upload the `lexiata-checkout-fees` folder to `/wp-content/plugins/`, or install through the WordPress Plugins screen directly.
2. Activate the plugin.
3. Go to **WooCommerce → Settings → Payment Gateway Fees** to configure.

== Frequently Asked Questions ==

= Does this work with the new Cart Block and Checkout Block? =

Yes. The plugin registers as a Cart/Checkout Block integration and triggers a server round-trip whenever the customer changes payment method, so the fee always reflects the chosen gateway.

= Is it HPOS compatible? =

Yes. The plugin declares compatibility with custom order tables and uses CRUD (`wc_get_order`, `WC_Order_Item_Fee`) throughout — no direct post meta access for orders.

= Can I give a discount instead of a fee? =

Yes. Enter a negative value in the Fee value field.

= Will the fee be taxable? =

Each fee slot has its own taxable toggle and tax class, so you can mix taxable and non-taxable fees on the same gateway.

= Does the plugin send any data anywhere? =

No. The plugin does not contact any external server, send tracking data, or include any third-party scripts.

== Screenshots ==

1. The General settings tab — master switch and global options.
2. Per-gateway settings — main and additional fee slots with conditional rules.
3. The fee shown to the customer on the cart and checkout pages.

== Changelog ==

= 1.0.0 =
* Initial release.

== Upgrade Notice ==

= 1.0.0 =
Initial release.
