=== Elorus Invoicing for WooCommerce ===
Contributors: catcodestudio
Tags: elorus, invoicing, greece, mydata, woocommerce
Requires at least: 6.2
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Create invoices in your Elorus account from WooCommerce orders, download the PDF, and map your VAT rates to Elorus taxes.

== Description ==

For shops that invoice with [Elorus](https://www.elorus.com). The plugin talks to the Elorus REST API with your own API key and creates the document from the order, so nobody retypes it.

* **Invoice from the order screen:** one button in the "Elorus invoice" box. The customer becomes an Elorus client (found again by a stable ID the next time), the order lines, fees and shipping become invoice lines, and the invoice number comes back to the order.
* **No duplicates:** the order's ID travels with the invoice; pressing the button twice, or a retry after a timeout, links the invoice that already exists instead of creating a second one.
* **PDF download** straight from the order, fetched from Elorus with your key.
* **VAT mapping:** you tell the plugin which Elorus tax belongs to which VAT percentage (24 = your 24 % tax and so on). A line whose rate is not mapped goes without VAT and the order gets a warning note, so nothing is invoiced silently wrong.
* **Void** an invoice from the order.
* **Demo mode:** the X-Elorus-Demo header keeps every call inside a demo organization while you test.
* HPOS (custom order tables) supported. Elorus limits the API to 60 requests a minute and 1000 a day; the plugin names the limit when Elorus answers with it.
// @pro-begin
* Greek translation included.
// @pro-end

// @pro-begin
= Pro =

The Pro version is sold on [catcode.com.ua](https://catcode.com.ua/modules/elorus-invoicing-woocommerce/), with a 7-day trial that never starts by itself:

* **Automatic invoices** when an order reaches the status you choose.
* **Credit notes** for WooCommerce refunds, linked to the invoice.
* **E-mail from Elorus** to the customer right after the invoice is created.
* **Greek myDATA fields:** document type, payment method, and the choice to submit now or later by hand.
* **Invoice PDF link** in the customer's My account orders list.

The licence runs for 1-5 years and includes updates and support for that term; a purchased licence keeps its Pro features after the term ends.
// @pro-end

= Third-party service =

The plugin sends order and customer data (name, address, e-mail, phone, VAT ID, order lines and amounts) to the Elorus API at https://api.elorus.com when you create an invoice, and asks it for taxes and PDFs. Nothing is sent before you enter an API key and press the button (or switch automation on). Elorus: [terms](https://www.elorus.com/terms/), [privacy](https://www.elorus.com/privacy/). Elorus is a trademark of its owner; this plugin is made by CatCode and is not endorsed by Elorus.

= Not tax advice =

Which VAT applies and what is reported to the tax authority is decided by you and your accountant. The plugin passes the amounts of the order on to Elorus.

== Installation ==

1. Install and activate the plugin. WooCommerce must be active.
2. WooCommerce → Elorus Invoicing: enter the API key (Elorus user profile) and the organization ID. Tick "Demo organization only" while testing.
3. Press "Test the connection and list my Elorus taxes", then write the mapping "24=<tax ID>" in the VAT rates field.
4. Open an order and press "Create invoice in Elorus".

== Frequently Asked Questions ==

= Where do I get the API key and organization ID? =

The key is in your Elorus user profile; the organization ID is the one used in the X-Elorus-Organization header of the API (see developer.elorus.com).

= Does it submit to myDATA? =

Elorus does that, when the myDATA integration is on in your Elorus organization. // @pro-begin
The Pro version can set the document type and payment method and can ask Elorus not to submit at once.
// @pro-end

== Changelog ==

= 1.0.0 =
* First release: invoice from the order, PDF, VAT mapping, void.
