=== Ssentezo Wallet for WooCommerce ===
Contributors: thinkxsoftware
Tags: payments, mobile money, uganda
Requires at least: 6.4
Tested up to: 6.6
Requires PHP: 8.1
Stable tag: 0.1.2
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Collect MTN and Airtel mobile money through Ssentezo Wallet. Orders are paid only after the status API confirms them.

== Description ==

This is a beta payment gateway for classic WooCommerce checkout and the Cart and Checkout blocks. It starts a Ssentezo Wallet mobile-money collection when the customer places an order, then marks the WooCommerce order paid only when `POST /api/get_status/{externalReference}` returns SUCCEEDED for the same amount.

It does not trust the browser return or the unsigned callback by itself. Card checkout and bank transfer are not part of this version.

WordPress.org submission is a separate release. This beta is installed from a ZIP.

== Installation ==

1. Upload the plugin ZIP and activate it. WooCommerce must already be active. The plugin does not add a checkout to WordPress sites that do not run WooCommerce.
2. Open Settings, Ssentezo Wallet. Sandbox is selected by default.
3. Enter the API base URL, API user, and API key. Use a staging URL and a sandbox organization's credentials for testing. Save, then use Test connection. The test calls the balance endpoint and does not start a payment.
4. Sandbox mode does not start a payment on `https://wallet.ssentezo.com`. On any other URL it still does not start a payment until you check the box confirming that you independently verified that host's payment mode. A test phone number is not that verification. After that confirmation, checkout accepts only 256770000001, 256770000002, 256770000003, and 256770000004.
5. Live payments stay off until Live is selected and the confirmation box is checked. Do that only for a live organization.
6. Open WooCommerce, Settings, Payments, Ssentezo Wallet, and enable it. Set the store currency to UGX.

The Checkout block displays a mobile-number field for the payment prompt. The classic checkout displays the same field. Both flows keep the order on hold until the wallet status API confirms success.

== Changelog ==

= 0.1.2 =
* Add support for the WooCommerce Cart and Checkout blocks, including a payment-specific mobile-number field.

= 0.1.1 =
* Status verification now requires the same reference, UGX, and amount. Cancelled and refunded orders are not paid by a late notice. The base URL must be HTTPS, and redirects are not followed.
* Credentials and the sandbox or live choice are on the WordPress settings page. Sandbox mode cannot start a payment on the production host, and live mode requires a separate confirmation. The version is unchanged.

= 0.1.0 =
* First beta. Mobile-money collection, status verification, duplicate protection, and a ten-minute status poll.
