- v1 licenses — opaque license keys tracked server-side. Simple generate/validate/revoke.
- v2 license artifacts — signed JSON documents (JWT-like structure: header, payload, signatures) that carry their own entitlements, validity window, grace period, device binding, and revocation epoch. Artifacts can be validated offline because the signature travels with the license.
v1 licenses
Generate
end_customer_id is required. The response contains license_key, the feature list, valid_until, the signature, and provenance metadata for the key material (execution mode and, when a quantum entropy source was used, its evidence status).
For batches, POST /api/v1/licenses/bulk accepts end_customer_ids (a list) with shared features and valid_days.
Validate
valid, the features, and expiry.
Revoke
quantumlock:keys scope.
Hybrid validation (no API key)
POST /api/v1/licenses/validate/hybrid is deliberately unauthenticated: it exists so an application running on an end user’s machine can check revocation and expiry without embedding your API key. The license key itself is the credential.
signatureis optional; when present it is verified against the service signing keys.- The response carries a
revokedflag read from the durable revocation record — theHybridLicenseValidatorkeys its persistent local revocation cache off this flag. - If the revocation record cannot be read, the endpoint answers
503rather than defaulting to “not revoked”. - The response never discloses the issuing tenant:
customer_idis echoed from the request, not read from the database, so the endpoint cannot be used to enumerate tenants.
v2 license artifacts
All artifact paths live under/api/v1/v2/ (the v2 router is mounted under the v1 prefix — use the paths exactly as written).
Create an artifact
subject (required), days_valid, grace_days, entitlements, binding, metadata, sign_pqc, revocation_epoch. The response returns the full artifact (header with kid/alg/alg_pqc, payload with jti/sub/iat/nbf/exp, and the signature block) plus a compact single-string form.
Validate an artifact
artifact_json or artifact_compact. Validation checks, in order: signatures, timestamps (nbf/exp/grace), device binding (when the artifact has one and a fingerprint is supplied), revocation, and the anti-rollback epoch.
Revocation and epochs
Revocation is epoch-based: every revocation advances a monotonically increasing epoch number. Clients persist the highest epoch they have seen; a revocation set with a lower epoch than the stored one is rejected as a rollback. This prevents an attacker from replaying an old (pre-revocation) revocation list at an offline client.
Both revoke and un-revoke are tenant-scoped: you can only revoke licenses you issued.
Status proofs
Verification keys
public_key material only for asymmetric keys (ML-DSA); each entry states whether offline_verification is possible. If the deployment holds no publishable public key, the endpoint answers 503 instead of returning keys that cannot verify anything.