=== SabPaisa Payment Gateway for WooCommerce ===
Contributors: sabpaisa
Tags: payment gateway, woocommerce, upi, cards, net banking, sabpaisa
Requires at least: 5.8
Tested up to: 6.7
Requires PHP: 7.4
WC requires at least: 7.0
WC tested up to: 9.5
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Accept payments via UPI, Cards, Net Banking, and Wallets through SabPaisa Payment Gateway 2.0.

== Description ==

SabPaisa Payment Gateway for WooCommerce enables Indian merchants to accept payments through multiple payment methods including UPI, Credit/Debit Cards, Net Banking, and Wallets.

**Features:**

* UPI, Cards, Net Banking, and Wallet payments
* Secure HMAC-SHA256 checksum verification
* Double verification (callback checksum + server-side enquiry)
* Automatic and partial refunds from WooCommerce admin
* Webhook support for real-time payment updates
* Staging and Production environment support
* HPOS (High-Performance Order Storage) compatible
* Debug logging for troubleshooting

== Installation ==

1. Upload the `sabpaisa-payment-gateway` folder to `/wp-content/plugins/`.
2. Activate the plugin through the WordPress Plugins menu.
3. Go to **WooCommerce > Settings > Payments > SabPaisa**.
4. Enter your API Key, Merchant ID, Secret Key, and Client Code.
5. Select the environment (Staging for testing, Production for live).
6. Enable the gateway and save.

== Configuration ==

1. **API Key** — Your SabPaisa API key (provided by SabPaisa).
2. **Merchant ID** — Your merchant identifier for API authentication.
3. **Secret Key** — HMAC secret for checksum generation and verification.
4. **Client Code** — Your client/merchant code for API requests.
5. **Environment** — Choose Staging (for testing) or Production (for live payments).
6. **Debug Log** — Enable to log payment events for troubleshooting.

== Frequently Asked Questions ==

= What payment methods are supported? =

UPI, Credit Cards, Debit Cards, Net Banking, and Wallets.

= How do I test the integration? =

Set the environment to "Staging" and use the test credentials provided by SabPaisa.

= Where can I find the debug logs? =

When debug logging is enabled, logs are stored in **WooCommerce > Status > Logs** under the `sabpaisa-pg` source.

= Does this plugin support refunds? =

Yes. You can process full or partial refunds directly from the WooCommerce order admin page.

== Changelog ==

= 1.0.0 =
* Initial release.
* Payment creation with redirect to SabPaisa checkout.
* Callback verification with checksum and server-side enquiry.
* Refund support (full and partial).
* Webhook handler for real-time payment status updates.
* HPOS compatibility.
