For the complete documentation index, see llms.txt. This page is also available as Markdown.

Deactivate License (Offline Method)

Currently we support trial, perpetual and consumption license types for offline deactivation purposes

Endpoint

  • Method: POST

  • Path: /api/v4/deactivate_offline

  • Description: Deactivates a license using the offline flow (base64 payload).

Authentication

Required headers

  • Date (string) — RFC7231 GMT date string

  • Authorization (string) — signature or bearer token

  • Accept: application/json

Request

Body

The request body is a base64-encoded, stringified JSON object (see schema below).


Schema

Request Body

The request body is a string representing a base64-encoded JSON object containing all the required activation data.

Request schema (TypeScript + JSON Schema)

TypeScript

JSON Schema


Signature

The signature value is constructed from a specific signing string and then encrypted using HMAC-SHA256 with the company shared key (or client secret for OAuth). Use the following steps to build the signing string:

1

Step

Concatenate the string "licenseSpring" plus a newline.

2

Step

Add the string "date: " plus the "date" value from the license payload object, plus a newline.

3

Step

Add either the "license_key" or "username" value from the request payload (whichever is present), plus a newline.

4

Step

Add the "hardware_id" value from the request payload, plus a newline.

5

Step

Add the "api_key" value from the request payload.

Encrypt the complete string with HMAC-SHA256 using the signing key (Shared Key for API key authorization; Client Secret for OAuth). Example in Node.js:


Finalized payload

This object is then stringified and encoded to base64.


Response Body

If the request succeeds, the endpoint responds with HTTP 200 and the string:

license_deactivated


Consumption pools and offline checkouts

When the device holds an offline checkout from a consumption pool (see offline_checkout in the offline activation response), the deactivation settles that checkout: the reported consumptions are added to the usage already synced, and the unused part of the checkout returns to the pool. Sending the same deactivation file again does not settle the checkout a second time.


License Authorization Method

There are two types of product licenses based on how the client application authorizes itself to interact with a license.

Key-based product licenses

  • Client provides property license_key in the request body.

  • The license response object will contain license_key.

  • product_details.authorization_method will be "license_key".

User-based product licenses

  • Product uses a license user instead of a license key.

  • Access methods include:

    • Providing username and password

    • Providing id_token and customer_account_code (Implicit grant SSO)

    • Providing code and customer_account_code (Authorization code grant SSO)

In responses, product_details.authorization_method will be "user" and the response will contain the user object with information on the license user.


Errors

If an error occurs, the response will have HTTP status code >= 400 and the body will contain an error description:

JSON Schema:

List of exceptions

missing_headers (400): some headers are missing

  • when missing authorization or date headers

missing_parameters (400): some parameters are missing in the request

  • when no request body at all or no file found in request body

authorization_missing_params (400): some parameters are missing in authorization

  • when the request body is not properly base64 encoded

  • when file is missing in request body

  • when license_key or hardware_id body parameters are missing

  • when data body parameter is missing

  • when api_key parameter is missing

tpm_invalid_public_key (400): The TPM public key sent is not valid

tpm_signature_required (400): The TPM signature is missing from the body/license file and TPM usage is enforced

tpm_signature_missmatch (400): The TPM signature/algorithm is not ES256 and the signature can't be verified against the TPM public key

pool_quota_exhausted (400): The consumption pool has no quota left

invalid_pool_type (400): The consumption pool type does not match this entity


Guide on using Offline Licenses

If any aspect of the offline licensing model remains unclear, see Offline License Activation.

Last updated

Was this helpful?