=== Usedkit – Notify Me for Used Items, Margin VAT, Lowest Price ===
Contributors: psavela
Tags: back in stock, notify me, second-hand, margin scheme, omnibus
Requires at least: 6.5
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 0.4.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Tell customers when the next one of a sold model comes in. For WooCommerce shops selling used, one-of-a-kind items: margin VAT, lowest price, more.

== Description ==

A used camera, lens or guitar is sold once. The customer who came for it a day late leaves and never comes back. Back-in-stock plugins can't help: a used item is never restocked. The next one is a new product with a different title, condition and price.

**Usedkit matches by model, not by product.** On a sold item, the customer leaves their email. When you list the next one of the same model, however you title it, they get one email with its photo, price and link, minutes after you publish it. "Sony Alpha 7 III body (ILCE-7M3)" reaches the customer who signed up on "Sony A7 III runko".

= Notify me, for used goods =

* A short form on sold-out products: "Sold. Want to hear when the next one comes in?"
* The same offer on empty search results, and anywhere with `[usedkit_watch]` or `[usedkit_watch query="Leica M6"]`.
* Cameras and lenses matched by model across titles, maker codes and languages; camera bodies by exact model, so an A7 III watcher is never sent an A7 IV. Other goods by the words of the listing.
* An optional maximum price per customer.
* Double opt-in, one-click unsubscribe (RFC 8058), abuse limits. Works with page caches.
* A **Waiting** column in your product list and a weekly email: the demand behind each model, while you buy stock.
* Sold items can leave your listings while their pages stay live with the form. They keep their search ranking and catch the next buyer.

= Margin-scheme VAT =

For second-hand goods bought from private people (EU VAT Directive, Articles 311–325):

* A purchase price, purchase date and margin-scheme mark on each product.
* No separately charged VAT on those items at checkout.
* The margin VAT stored on each order line.
* The invoice wording the law requires on order pages and emails.
* A monthly or quarterly report, per item or by the global margin of the period with losses carried forward, with a CSV for your accountant.

= Lowest price before a discount (EU Omnibus rule) =

WooCommerce keeps no price history. Usedkit records every price change and shows "Lowest price in the 30 days before the discount" next to each sale price.

= Selling one-of-a-kind items =

* **Condition grades** for any kind of goods: words (New to For parts), letters (A+ to D) or ten-point (10/10), or your own names and descriptions, with only the grades you use. On product pages as a card with a scale, one line or a badge on the photo; in listings as a pill, text, a small scale or a badge on the photo. A note and what is included, a condition filter for the shop, and `itemCondition` in the structured data Google Shopping requires for used goods. Already grading in an attribute ("Kunto", "Condition")? It is read from there.
* **Make an offer**: accepted at once above a share of the price, turned down at once below a share or below your purchase price plus a margin, the rest waiting for you. An accepted offer is a link that puts the item in the customer's cart at that price.
* **Reserve for pickup**: a customer holds an item for a day to see it in the shop; meanwhile it can't be bought online. The hold ends by itself.
* **Automatic markdowns**: every so many days unsold, a step off the price, never below your purchase price plus a margin. Customers waiting with a maximum price hear when it is met.
* **Similar items in stock** on a sold item's page: the same model first, then the same category nearest in price.
* **Spec templates** for cameras, lenses, bikes, e-bikes, phones, computers, watches, audio, instruments, clothing and furniture: shutter count, frame size, battery health, box and papers. Saved as ordinary product attributes.

= Buying stock =

* **Your own sales as a price reference**: "4 sold: median 410 €, typically 12 days to sell", beside the price while you edit an item and in the pricing view. For anything you sell, not only cameras.
* **Instant trade-in offers** with `[usedkit_tradein]`, from the used market price ([Kamarvo](https://kamarvo.com), cameras and lenses) or your own sales of the model, and your buying percentages. Requests are listed under **Trade-ins**; one click makes a bought one a draft product with its purchase price, grade and seller.
* **Purchase register**: seller, ID checked, serial number, date and price of every item bought, by date, with CSV. Kept in WordPress only.
* **Add used item**: one screen that works on a phone. Photos, title, grade, prices, seller, and the description, categories and specs copied from the last one of the same model.
* **Used market price** on product pages, from Kamarvo, for cameras and lenses.
* **Sold items**: what sold, when, for how much, how long it took and at what margin.
* **Pricing vs market**: every item for sale against its market price and your own sales, furthest off first, with the next markdown.

In ten languages: English, German, French, Spanish, Italian, Polish, Dutch, Portuguese, Swedish and Finnish. Customers get their emails in the language of the shop's site.

== External services ==

This plugin connects to the **Usedkit service** (https://usedkit.app), which stores the shop's products, matches them to waiting customers and sends the emails. Nothing is sent before an API key is saved in the plugin's settings.

* **What is sent, and when:** product ID, title, link, image URL, price, currency and stock status when a product is saved or its stock changes, and nightly. A customer's email address, the model or search words, an optional maximum price and the site language when the customer submits the notify-me form. Product IDs when the product list or the pricing page is opened, for the waiting counts and market prices. A trade-in model name when a customer asks for an offer. Product IDs, or a trade-in model name, to look up which model they are, for the price reference from your own sales. Seller details from the purchase register, offers and reservations stay in WordPress and are never sent.
* **Terms of use:** https://usedkit.app/terms
* **Privacy policy:** https://usedkit.app/privacy

Market prices come from **Kamarvo** (https://kamarvo.com) through the Usedkit service. Your site does not contact Kamarvo directly. Kamarvo receives only model names. Kamarvo's privacy policy: https://kamarvo.com/privacy

== Installation ==

1. Install and activate the plugin. WooCommerce must be active.
2. Get a free key at https://usedkit.app/start. It arrives by email.
3. Go to **WooCommerce → Usedkit**, paste the key, choose the features you want and save.
4. Press **Send all products now** once. From then on every change is sent as you make it.

== Frequently Asked Questions ==

= How is this different from a back-in-stock plugin? =

Back-in-stock plugins wait for the same product to be restocked. A used item never is. Usedkit waits for any new listing of the same model.

= Is it GDPR compliant? =

Customers confirm by email before anything is sent, every email has a one-click unsubscribe, and only the email address and the model are stored, in the EU. The shop is the controller of that data and Usedkit its processor. Unconfirmed sign-ups are deleted after 7 days and watches end after a year.

= Does it work with page caching? =

Yes. The public forms use no nonces, which would expire in cached pages. A hidden honeypot field keeps bots out.

= Is the margin VAT report tax advice? =

No. Check the rate, the method and which goods qualify with your accountant.

= What does it cost? =

Free during early access.

== Screenshots ==

1. The form on a sold product.
2. The arrival email.
3. Settings: who is waiting for which model.
4. The margin-scheme VAT report.

== Changelog ==

= 0.4.0 =
* Condition grades, with structured data for search engines and a shop filter.
* Make an offer, reserve for pickup, similar items in stock on sold pages.
* Automatic markdowns with a floor; a price cut reaches customers whose maximum price it meets.
* Your own sales as a price reference, in the editor, the pricing view and trade-in offers.
* Spec templates for eleven kinds of goods.
* Trade-in requests kept and turned into draft products; a purchase register; a fast add-item screen.
* German, French, Spanish, Italian, Polish, Dutch, Portuguese and Swedish, besides English and Finnish.

= 0.3.0 =
* Self-serve sign-up link and connection status in the settings.
* Global margin: the period's purchases set against its sales, with a purchase date per product.
* Escaping and translator notes throughout.

= 0.2.0 =
* HTML arrival emails, one-click unsubscribe, click counts, the Waiting column, maximum price, nightly sync, cache-safe forms.
* Margin-scheme VAT, the lowest price before a discount, sold items and pricing vs market.

= 0.1.0 =
* First version: notify me when one comes in.
