How to deliver license keys automatically

Generate a unique license key for every buyer, limit activations and check keys from your software with the license API.

Illustration showing a software dashboard listing generated license keys with status checks for product activation management.

If you sell software, plugins, themes or any product that needs activation, ScaleEdges can generate a unique license key for every buyer. The key appears in the buyer's purchased content, and your software can check it with the license API.

You do not need to prepare a list of keys: each key is created automatically when the order is completed.

Add a license key to a product

  1. Open the product and go to the Content tab.
  2. In a content page, open the block menu and add License key.
  3. Fill in the block:
  • License type: Standard, Pro, Team…;
  • Buyer-facing label: the title shown above the key, Your license key by default;
  • Maximum activations (0 = unlimited): how many times the key can be activated;
  • Instructions (optional): how to activate the key, up to 500 characters;
  • Show usage count to the buyer: displays how many activations are used.
  1. Publish the product.

The License key block is only available in the Content tab. It cannot be added to the public product description, so a key is never visible before purchase.

Keys look like 7NQ2M-VK5AR-3YD8P-XC6TW: four groups of five characters, without ambiguous characters such as 0, O, 1 or I.

What the buyer sees

After purchase, the buyer finds the key in their purchased content with a copy button, whether the key is enabled and, if you chose to show it, the usage count.

Buyers who purchased before you added the block receive their key the next time they open the product content.

Offer several license types

The License type decides how many keys a buyer gets:

  • several License key blocks with the same type show the same key, for example on several pages;
  • blocks with different types create separate keys, for example one Desktop key and one Mobile key.

To sell Personal and Team licenses at different prices, use product versions: give each version its own page with its own license type and maximum activations. A buyer receives only the keys of the version they purchased.

A product can contain up to 20 license types.

Connect your software

Your software checks keys with the license API. It authenticates with a secret that belongs to the product, not with your account API key.

When you first save a product with a License key block, ScaleEdges creates this product secret and displays it once. Copy it immediately and store it on your server.

To find or replace the secret later:

  1. Open the product and go to the Content tab.
  2. Open Advanced options — Download limits below the editor and find Product license API secret.
  3. Select Rotate product secret to create a new one. The previous secret stops working immediately, but customers' license keys do not change.

With the API, your software can:

  • verify a key before activating the product;
  • add one use when a device is activated, and remove one when it is deactivated;
  • disable or re-enable a key, for example after a chargeback.

Never put the product secret in code that runs on the buyer's computer or in a browser. Call the API from your own server.

When a key stops being valid

A key is valid when it is enabled and has not reached its maximum activations. It becomes invalid when:

  • the order is fully refunded: all keys of that payment are disabled. If the refund fails, the keys are enabled again;
  • you disable the key through the API;
  • it is attached to a subscription that is no longer active;
  • the maximum number of activations is reached. Removing a use makes room for a new activation.

Good practices

  • Write clear activation instructions in the block, with a link to your installation guide.
  • Allow two or three activations for personal licenses, so buyers can reinstall or change computers.
  • In your software, check the valid field returned by the API, not only enabled.