=== Strainovic IT Shop Invoices for AbaNinja Pro ===
Contributors: gstrainovic
Tags: abaninja, woocommerce, invoice, credit note, switzerland
Requires at least: 6.5
Tested up to: 7.1
Requires PHP: 8.1
Stable tag: 0.4.2
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Extension for Strainovic IT Shop Invoices for AbaNinja: every WooCommerce order goes to AbaNinja automatically, every refund becomes a credit note.

== Description ==

Requires the free plugin "Strainovic IT Shop Invoices for AbaNinja" (version 0.3.0 or newer) and WooCommerce. The free plugin keeps the connection, the settings and the transfer of an order; this extension adds:

* Automatic transfer: as soon as an order is processing (paid) or completed (setting under WooCommerce → AbaNinja), it is transferred in the background via the WooCommerce Action Scheduler. Checkout is never slowed down, each order is transferred only once.
* Credit notes: every refund of an order that is already in AbaNinja is created as a credit note for the same AbaNinja address, with the refunded items, shipping and fees and their VAT rates. A refund of an amount without items uses the VAT rate of the order; if the order has several VAT rates, the refund has to name the items.
* The credit note number is written as an order note; each refund is sent only once.

= Trial and licence =

* 30-day free trial per shop. It starts as soon as the extension is active and the AbaNinja API token is saved in the free plugin. Reinstalling the extension on the same shop does not start a new trial.
* Afterwards CHF 149 per shop and year. The annual invoice arrives by email once the billing address is entered under "Billing address and invoices" on the settings page (WooCommerce → AbaNinja); the first invoice comes 7 days before the trial ends and is payable within 30 days, and the extension keeps working until then. You don't need to request anything.
* When the trial or the paid year has ended, the automatic transfer and the credit notes pause. No order is lost: waiting orders and refunds get an order note and are transferred automatically after your payment. The order action "Transfer to AbaNinja" of the free plugin keeps working. Want to continue? Then pay the invoice; otherwise you don't need to do anything and no costs arise.
* If the licence service cannot be reached, the extension keeps working with the last known status; a network error never stops the transfer.

More at https://www.strainovic-it.ch/en/abaninja-shop-connector/

== External services ==

Like the free plugin, this extension sends data to the AbaNinja API (https://api.abaninja.ch, DeepCloud AG): every order when it reaches the chosen status (see the free plugin's readme for the data), and for every refund the refunded items, amounts, VAT rates, the order number and the AbaNinja address of the invoice. API terms of use: https://www.deepcloud.swiss/legal/NB-DeepCloud-AG_API_EN.pdf, privacy policy: https://www.deepcloud.swiss/datenschutz/

The trial and the licence are managed by strainovic-connect, a service by Strainovic IT: https://connect.strainovic-it.ch. When the API token is saved the first time, the extension registers the shop (sent: shop URL, administrator email, site language, product name) and receives a site ID and secret. Afterwards, once a day and when the settings page is opened, it reads the trial or licence status (sent: site ID, signed timestamp). Orders, customer data and the AbaNinja token are never sent to this service. Terms and privacy: https://www.strainovic-it.ch/datenschutz/

Site owners must mention the transfer to AbaNinja in their own privacy policy. After the trial or the paid year has ended, waiting orders and refunds stay in the WordPress database until they are transferred.

== Changelog ==

= 0.4.2 =
* While an invoice is open, the settings page shows "Invoice open" with the due date up to which the transfer to AbaNinja continues, instead of the trial or paid date.

= 0.4.1 =
* The annual invoice arrives by email; the settings page links to "Billing address and invoices" instead of an invoice request.
* Texts after the trial or the paid year has ended: continue only with payment.

= 0.4.0 =
* 30-day free trial per shop, then CHF 149 per shop and year; status on the settings page, notice after expiry.
* After the trial or the paid year has ended, automatic transfers and credit notes wait and are caught up after your payment.

= 0.3.0 =
* First release: automatic transfer of every order (moved from the free plugin) and credit notes for refunds.
