License models

A license model is one thing you sell, such as an edition at a given term and price. Every key sold under a model takes the model's terms at the moment of the sale.

Not sure which settings make a perpetual, floating, node-locked or metered license, and the rest? See Choosing a licensing model.

  • Add models on a product's License models tab with + Add a license model.
  • A product can have as many models as it sells, and a new product has none.
  • Editing a model later affects only keys sold after the edit, not the ones sold before.

Perpetual, subscription, trial, timed

A model's type, under How it expires, decides when its keys expire. The last column is the Offline days a key gets when its model sets none.

TypeThe key expiresOffline days
Perpetual Never, unless it is issued with an expiry. 30
Subscription Sold through Stripe: at the end of each period Stripe reports, plus its grace period. Issued by hand or from your server: 365 days (Yearly) or 30 days (Monthly) from the day it is issued, plus its grace period. 7
Trial Issued by hand or from your server: the model's trial length from the day it is issued. 7
Timed One payment buys a set term, or runs to a date, after which the key stops at the end of its grace period. Buying again extends the same key. See Timed models. 7
  • A subscription key issued by hand or from your server does not renew on its own, so extend it from your server on each renewal.
  • A trial model issues trial keys. A trial started from the app without a key (a device trial) is set on the product instead; see Trials.

The terms

The model dialog's Terms column sets the first four lists below, and its Versions and entitlements column the last. A default is what a new model starts with.

Type, price and keys

Name

Names the model in your dashboard and on the key delivery email. A model sold as an upgrade is on no email: its sale sends the upgrade email, which names no model.

  • KeyGrant sends that email for each sale under the model, and for each key issued under it by hand or over the API. It does so only while the product's License delivery tab is set to KeyGrant sends them and its Key delivery email is on.

Length up to 80 characters

How it expires

Perpetual, Subscription, Trial or Timed. See Perpetual, subscription, trial, timed.

Price

With Stripe or Paddle linked, pick the price that sells the model: its amount, currency and renewal interval come from the processor. Leave it empty for keys you only issue by hand. With neither, type the price; it is required.

Applies to perpetual, subscription and timed (timed takes a one-time price)

Processor price it maps to

The Stripe or Paddle price a customer pays to buy the app after the trial. A paid checkout on it creates a paid key of the model, perpetual or a subscription, never a trial key. See Trial keys.

Applies to trial, with Stripe or Paddle linked

Renews

Yearly or Monthly, when the price is not a Stripe or Paddle price.

Applies to subscription

Devices per license

How many devices one key may activate.

Range 1 to 1,000 ; Default 3

Keys per sale

How many keys one purchase issues. Each key is a license of its own with the model's terms, its own devices included, and the keys of one purchase are one sale. Buying two issues twice as many, up to 100 a sale. See What a checkout creates.

Range 1 to 100 ; Default 1 ; Applies to perpetual, subscription and timed, except a model sold as an upgrade

Term and trial length

Runs for

A term, or Until a date. See Timed models.

Applies to timed

Term

With A term: Days or Months (calendar months), Counted from the Purchase or the key's First use, its first activation.

Range 1 to 3,650 days or 1 to 120 months ; Default 12 months ; Applies to timed

Ends on

With Until a date: the date every key the model sells stops on, after today.

Applies to timed

Trial length, days

How long a trial key runs, from the day it is issued.

Range 1 to 3,650 ; Default 14 ; Applies to trial

Delivery, access and uses

Delivered as

Key (the customer types it into the app, the default), Key file or License file. A file is made out to the customer's email, so issuing one with no email is refused (email-required). A test key's license file is a typed key.

  • Key file: a signed file the customer drops onto the app, which activates the key online. Seats, revocation and refunds work as for a typed key.
  • License file (perpetual only): works offline for good, with no seat limit. It cannot be revoked, and a refund cannot take it back.
  • A license file has no upgrade protection and is never an upgrade offer. A leaked one works until an app update blocks its id.
Who can activate

Anyone with the key (the default), Only the buyer: they type their email, or Only the buyer: a code is emailed to them: who may activate a new device on the keys the model sells. See Who can activate.

  • Each key takes the choice when it is sold, and a key with no email, or a test license, is never locked.
  • Not for a license file or a model sold as an upgrade.
What customers are told

A description on the model's card in your dashboard, and on the key delivery email under the model's name, never for a model sold as an upgrade. See Key delivery email.

  • The dialog shows the field only while the product's License delivery tab is set to KeyGrant sends them and its Key delivery email is on, and never for a model sold as an upgrade.
  • A description written before stays on the model while the field is hidden.

Length up to 240 characters

Metered uses

What keys sold under the model can spend with use(): each meter picked from the product's Meters tab, with its Uses, whether it Comes back each billing period (subscription only; elsewhere it is Used up for good) and its Offline allowance, per device. See Metered uses.

  • Not for a license file or a model sold as an upgrade.

Uses 0 to 1,000,000,000 ; At most 8 a model

Offline, seats and grace

Offline days

How long each lease lasts: how long a key keeps working without checking in, and the longest a refunded key keeps working on a device that does not check in. See Lease format.

Range 1 to 90 ; Empty 30 for perpetual, 7 for subscription, trial and timed

Free unused seats

Off for a new model. When on, a device that goes this many days without checking in gives its seat back (once a night), so a customer who loses a machine never has to ask. Set it from the model's Offline days up to 365. See Free unused seats.

  • Not for a model sold as an upgrade of entitlements, devices or uses.
Grace after expiry, days

How many days a key keeps working after a failed renewal, a cancellation or a lapse, or, timed, after its term ends.

  • A key nobody has paid for (a free trial that never converted, or a key whose only payment was refunded) gets none once no card retry can pay for it: when its subscription is canceled, paused for want of a card, or left unpaid after Stripe's retries.

Range 0 to 365 ; Default 14 ; Applies to subscription and timed

Versions and entitlements

Versions

Version sold, Sold and later, Every version or Specific versions. See Licensing by version.

Upgrade protection

Months, counted from the sale, during which the key covers every new version. See Upgrade protection.

Range 1 to 120 months ; Default on at 12 months ; Applies to Version sold, or a Specific versions range with a highest version

Sell as an upgrade

A sale changes the key the customer already holds instead of creating one. What it changes is the choice under What it upgrades:

Applies to perpetual, with Stripe or Paddle linked

Entitlements

What keys sold under the model grant beyond the base product. See Editions & entitlements.

Keys sold under no model

A key can be issued from your server, or sold through a checkout whose metadata names the product, with only a type and no model. It takes these terms from the product's oldest model of that type, or, when the product has no model of that type, as below:

TermWith no such model
Device limit3 devices
Grace periodNo grace period
EntitlementsNo entitlements
Offline daysThe type's default
  • A device limit in the request or the checkout's metadata overrides the borrowed one.
  • A trial key that would get no entitlements takes the product's Trial entitlements instead.
  • Its versions follow the type's default: Version sold for perpetual, Every version for subscription, trial and timed.
  • A subscription or trial key issued from your server this way has no expiry unless the request sends expiresAt.
  • A timed one needs expiresAt: only a timed model names a term (400 term-required).

Timed models

A timed model sells a term once: a 1-year license, a 30-day pass, or a license that ends on a date, such as an event or a school term. A key sold under it, or issued under it by hand or from your server, runs:

  • Counted from the purchase: its term from the sale.
  • Counted from first use: with no end until its first activation, which starts its term. A key bought ahead, or as a gift, loses none of it. A purchase of several keys starts them all at the first activation of any of them.
  • Until a date: to that date.

Until a first-use key's first activation, License detail says how long it runs from first use, and the customer's key delivery email says it under the model's name, as Runs 12 months from first use.

Leases and expiry

  • Its leases carry its end, as a subscription key's do, so an app that is offline stops on time, after the grace period, and never sooner.
  • Every SDK reads them as it reads a subscription's: no SDK change is needed.
  • A key past its end and grace stops validating and stays on your Licenses list as expired, so a purchase can still find it.

Buying again extends the key

Buying again extends the same key, from the later of the day it is bought and the key's end: a key that ran out last month gets the whole term from today.

KeyGrant finds the key as it finds the key an upgrade changes (see How KeyGrant finds the key): the device's activation id when the app opens your Payment Link with upgradeUrl, a key a link names in ?client_reference_id=, or the one key of the model the buyer's address holds.

  • Only a key of the model bought: a year of Pro is not a year more of a Basic key, so a buyer who holds only another model's key gets a new key of the model they bought.
  • Nothing found: the purchase is a first one and creates a key.
  • Waiting for its first use: the key waits with the longer term.
  • Several at once: each one bought is a term, so two of a 30-day pass bought at once run 60 days, at the first purchase or later.
  • A purchase of several keys shares what was bought over its active keys, a term each; a date is bought once for each key.
  • The customer is mailed the key's new end, on the Time extended email.

When a timed sale is held

A purchase of a timed model is held when:

  • the model's date has already passed, even for a first purchase;
  • the key named cannot take time or is another model's, whatever the address holds;
  • no key was named, and the buyer's address holds this model's keys of more than one purchase;
  • the purchase's keys no longer all end on the same date;
  • the key found already runs to the model's date, or has no end;
  • a date is bought for a key still waiting for its first use;
  • the terms bought do not divide evenly over the purchase's keys, or one key would buy the same date twice;
  • it found a key, but KeyGrant cannot tell its line in the checkout: it was bought with other items, or Stripe would not give the checkout's lines.

A held sale waits for you to attach it to a key or refund it: see Held sales.

Refunds

A full refund (while Refunds revoke keys is on) or a lost dispute takes back a timed purchase as follows (see Refunds and disputes):

  • The first purchase: revokes its key, as any refund does, unless later purchases extended it and still stand. The key then stays active, since revoking it would take back time those payments bought, and your owners are told, to revoke it if the customer should lose it.
  • It is revoked once those later purchases are refunded too.
  • An extension: takes back only its time, while the key is exactly where that sale left it. A key that moved since keeps the time, and your owners are told.
  • An expiry is only ever moved later by hand, so to take the time off they revoke the key and issue one that ends when it should.

The Ends soon email

  • The Ends soon email tells the customer 14 days before the term ends.
  • Its button goes to the product's Extend license link, on its License delivery tab, for a key of the product's one timed model. For any other key, or when there is no extend link, it goes to the app link.
  • A Stripe Payment Link with ?client_reference_id= followed by {key} extends exactly the key the email was sent for.
  • Your systems hear license.expiring, with model: "timed".

Metered uses

A license can count what its customer does, such as 1,000 exports for good, or 50 renders each billing period. To set it up:

  1. Define the things to count once, on the product's Meters tab: a Code (what your app passes to use(), which never changes once made), a Name your customers see, and a description.
  2. Pick a model's meters under Metered uses.
  • A product has at most 8 meters, and a meter is removed only while no license model names it.
  • Each key a model sells copies its meters, unused, at the sale: editing the model later changes only keys sold after the edit.
  • Your app spends with use() (see Metered uses in the Electron SDK).
Comes back each billing period

For a subscription: the meter is full again on each renewal KeyGrant counts, and uses bought on top carry over until they are spent. Every other meter is Used up for good.

  • A subscription key with no Stripe subscription behind it (issued by hand or over the API) has no periods KeyGrant can see, so its meters are reset by hand, with Reset now on License detail.
Offline allowance, per device

How many uses a device may spend while KeyGrant cannot be reached. A key can run past its uses by at most the allowance times its devices, and every use past is recorded and shown as overage. The customer is never refused for it, and nothing is taken back.

Empty 10% of the meter, at least 1 ; 0 online only

Keys issued by hand

Take the model's meters. Set meters for this key on Issue license replaces them for that key alone.

  • License detail's Meters card shows what is left, lets you add uses, edit a meter or reset it, and charts a meter's uses by day.
A used-up meter

Refuses spends, and meter.used_up tells your systems so you can offer a top-up. A meter never takes the license away: nothing reads one to decide whether the app is licensed.

Not metered

A device trial has no meters, and a key sent as an offline license file carries none, since it never checks in. A trial key spends its model's meters.

Sell more uses

A model sold as an upgrade can add uses in place of versions:

  1. Turn on Sell as an upgrade, and choose Uses under What it upgrades.
  2. Set the Uses it adds for each meter one purchase brings, such as 500 more exports for $10. Buying two adds twice as many.
  • It finds the customer's key as every upgrade does: the key the checkout names (upgradeUrl puts the activation ID in client_reference_id), else the one key at the buyer's address that can take it (see How KeyGrant finds the key).
  • Perpetual, timed and subscription keys take the uses; a key that lacks the meter does not. They go on top of the key's own, where they last until they are spent.
  • The customer is mailed the More uses email, and your systems hear license.upgraded with upgrade: "uses".
  • Refunds: a full refund (while Refunds revoke keys is on) or a lost dispute takes back only the uses not yet spent, never a device or the key; what was already spent stays on the key.
  • A top-up issues no key, so no key is issued, imported or tested under it.

A top-up sale is held when:

  • It finds no key that can take the uses: neither the key the checkout named nor any key at the buyer's address.
  • The address holds more than one key that can take them, or more than 20 keys that might, and the checkout named none of them.
  • The uses would take a meter past 1,000,000,000.
  • KeyGrant cannot tell its line in the checkout: it was bought with other items, or Stripe would not give the checkout's lines.

A checkout that does not say how many were bought counts as one. A held sale waits for you to attach it to a key or refund it: see Held sales.

Archive a model

  • Archive model, in a model's menu, removes the model from the Issue license form. Keys already sold keep working, and your server can still issue keys under the model by its modelId.
  • Archiving does not stop Stripe or Paddle from selling the model's price, so KeyGrant offers to deactivate that price in Stripe, or archive it in Paddle, as you archive, unless another unarchived model still maps it.
  • Restore model brings the model back. It is refused while another unarchived model maps the same Stripe or Paddle price.