=== RadarAddress for WooCommerce ===
Contributors: radarwave
Tags: address autocomplete, address validation, checkout, postcode, woocommerce
Requires at least: 6.4
Tested up to: 7.1
Requires PHP: 8.1
WC requires at least: 8.3
WC tested up to: 11.1
Stable tag: 1.0.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Address autocomplete and verification at checkout from Europe's national address registers; orders flagged to review. Never blocks an order.

== Description ==

RadarAddress completes and corrects the customer's address while they type it at checkout — billing and shipping, classic checkout and Checkout Block — in the countries where the national address register is in service (Italy, Germany, France, Spain, the Netherlands, Belgium, Austria, Switzerland, Denmark, Norway, Finland, Iceland, Portugal and more). The postcode and the house number come from the register at the moment of selection; the customer can always change what they wrote. Nothing ever blocks the order.

Every new order is checked on the server: outcome and verified form are saved next to the order, the order list shows a colour dot (verified, warning, to review, not verified) with a filter, and the order screen shows the verified address with one button to apply it. The order address is never changed by itself.

**What you get**

* Address autocomplete on billing and shipping, classic checkout and Checkout Block.
* Correction on the field of an address typed by hand (postcode, city, street) — optional.
* Verification of every order, with the verified address, coordinates and the reason.
* «To review» flag, filter and bulk action in the order list; verification of existing orders.
* Fail-open by design: if RadarAddress does not answer, the checkout goes on as usual.
* Data stays in the EU. Sources: the national address registers, published as open data.

**How it works**

1. Create a free account on radaraddress.com (every month 50 contact checks are free).
2. Create an API token in your personal area.
3. Paste it in WooCommerce → Settings → RadarAddress and press «Verify».

Typing is free. One contact check is used when the customer selects an address, or when an order is verified — one per address, never twice for the same one. For a small shop the 50 free checks a month are often all it needs; beyond that, packs and monthly subscriptions on radaraddress.com.

**Third-party service**

This plugin sends the address typed at checkout and the order addresses to the RadarAddress API (https://www.radaraddress.com) to get suggestions and verification results. Terms: https://www.radaraddress.com/en/contratto.php — Privacy: https://www.radaraddress.com/en/privacy-policy.php

== Installation ==

1. Upload the plugin folder to `/wp-content/plugins/` or install the zip from Plugins → Add New → Upload.
2. Activate it. WooCommerce 8.3 or later is required.
3. WooCommerce → Settings → RadarAddress: paste your API token and press «Verify».

== Frequently Asked Questions ==

= Does it block the order when the address is wrong? =

Never. The customer can go on with what they wrote; the order is created and, if the address does not check out, it is flagged «to review» for you.

= Which countries? =

Those where the national address register is in service: the list is in the settings and grows as registers are added. Elsewhere the address is put in the postal form of the country, without suggestions.

= Does it change the order address by itself? =

No. The verified form is shown next to the order address; you apply it with one click, and an order note records before and after.

= How much does it cost? =

The plugin is free and so is typing. One contact check is counted when the customer selects an address or when an order is verified, only one per address. Every month the first 50 are free: for a small shop that is often all it needs. Beyond that, packs and monthly subscriptions on radaraddress.com.

= What if RadarAddress is down? =

The checkout goes on as usual, with no suggestions and no message to the customer; the order is marked «not verified» and checked again by a background task.

== External services ==

This plugin connects to the RadarAddress API, a service run by RadarWave (the author of this plugin), to suggest and verify postal addresses. It does nothing until you paste your own API token in WooCommerce > Settings > RadarAddress.

* **What is sent and when:** while a customer types an address at checkout, the text typed in the address fields (street, house number, postcode, city, country) is sent to the API to get suggestions; when an order is placed, or when you verify existing orders from the admin, the order's billing and shipping address (name, company, street, postcode, city, province, country) is sent to be verified. Your API token is sent with every request to identify your account. The settings page also asks the API for your account's remaining verifications.
* **Where:** https://www.radaraddress.com/api/v1/ (calls are made by your site's server, or through the plugin's own REST endpoint on your site: the token never reaches the browser).
* **Terms of use:** https://www.radaraddress.com/en/terms
* **Privacy policy:** https://www.radaraddress.com/en/privacy-policy

== Screenshots ==

1. The checkout: the street completes while the customer types, with the register source at the bottom of the popup.
2. The order page: outcome, reason, verified address, map and the button to apply it.
3. The settings: token, switches, countries, this month's usage, existing orders.

== Changelog ==

= 1.0.3 =
* Code prefixes and translations reorganised following the WordPress.org review; the plugin no longer checks for new versions on radaraddress.com (updates come from WordPress.org).

= 1.0.2 =
* If the site keys change (for example after moving the site), the saved token is no longer read as random characters: it is treated as missing and the settings ask for it again.

= 1.0.1 =
* The settings now say how to get a token: a link to the getting started page, where the free account, the email confirmation and the token are explained in four steps. Fixes the link that opened the sign-in form instead of the sign-up form.

= 1.0.0 =
* First release: autocomplete and verification at checkout (classic and block), order verification, order list flag and filter, bulk action, existing orders, settings with token, countries and usage.
