magdev f7f36b891b Reorganize CLAUDE.md: move completed versions to Session History
- Remove completed version 0.0.1 from Temporary Roadmap
- Add Session History section at end of file for AI session documentation
- Document v0.0.1 implementation details and architecture decisions

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-21 19:00:13 +01:00

WC Licensed Product

A WooCommerce plugin to sell software products using license keys with domain-based validation.

Description

WC Licensed Product adds a new product type "Licensed Product" to WooCommerce, enabling you to sell software with automatically generated license keys. Licenses are bound to specific domains and can be validated through a REST API.

Features

  • Licensed Product Type: New WooCommerce product type for software sales
  • Automatic License Generation: License keys generated on order completion
  • Domain Binding: Licenses are bound to customer-specified domains
  • REST API: Public endpoints for license validation and management
  • Customer Account: Customers can view their licenses in My Account
  • Admin Management: Full CRUD interface for license management
  • Version Binding: Optional binding to major software versions
  • Expiration Support: Set license validity periods or lifetime licenses

Requirements

  • WordPress 6.0 or higher
  • WooCommerce 10.0 or higher
  • PHP 8.3 or higher

Installation

  1. Upload the wc-licensed-product folder to /wp-content/plugins/
  2. Activate the plugin through the 'Plugins' menu in WordPress
  3. The plugin will create necessary database tables on activation

Usage

Creating a Licensed Product

  1. Go to Products > Add New
  2. Select "Licensed Product" from the product type dropdown
  3. Configure the product price in the General tab
  4. Set license options in the "License Settings" tab:
    • Max Activations: Number of domains allowed per license
    • License Validity: Days until expiration (empty = lifetime)
    • Bind to Major Version: Lock license to current major version
    • Current Version: Your software's current version

Customer Checkout

When a customer purchases a licensed product, they must enter the domain where they will use the license during checkout.

Viewing Licenses

  • Customers: My Account > Licenses
  • Administrators: WooCommerce > Licenses

REST API

Validate License

POST /wp-json/wc-licensed-product/v1/validate
Content-Type: application/json

{
  "license_key": "XXXX-XXXX-XXXX-XXXX",
  "domain": "example.com"
}

Check Status

POST /wp-json/wc-licensed-product/v1/status
Content-Type: application/json

{
  "license_key": "XXXX-XXXX-XXXX-XXXX"
}

Activate License

POST /wp-json/wc-licensed-product/v1/activate
Content-Type: application/json

{
  "license_key": "XXXX-XXXX-XXXX-XXXX",
  "domain": "newdomain.com"
}

Deactivate License

POST /wp-json/wc-licensed-product/v1/deactivate
Content-Type: application/json

{
  "license_key": "XXXX-XXXX-XXXX-XXXX",
  "domain": "example.com"
}

License Statuses

  • Active: License is valid and usable
  • Inactive: License has been deactivated
  • Expired: License validity period has ended
  • Revoked: License has been manually revoked by admin

Support

For issues and feature requests, please visit: https://src.bundespruefstelle.ch/magdev/wc-licensed-product/issues

Author

Marco Graetsch

License

GPL-2.0-or-later

Description
WooCommerce plugin to sell licensed Software products
Readme 3.2 MiB
Release 0.7.5 Latest
2026-02-03 10:29:33 +00:00
Languages
PHP 76.8%
JavaScript 11%
Twig 7.3%
CSS 4.9%