SDKs
Public client SDKs for the Runtime plane (runtime.<domain>).
Management / Vendor Console APIs are not covered by these packages.
Compatibility matrix, package coordinates, language floors, and examples links: SDK compatibility matrix.
Local lease verify (fetch JWKS → verify JWS → enforce claims): Verify trust (JWKS) · snippets in Developer Quick Start.
Validate responses may include densified featureGrants. Consume them only after
a trusted allow; never soft-allow features on deny/degraded or when signature
trust fails.
The .NET, JavaScript/TypeScript, Java, Go, Rust, and C++ SDKs are packable as 0.1.0-preview.1; Python as 0.1.0a1.
nuget.org, npmjs, Maven Central, PyPI, proxy.golang.org / version-tag, crates.io, and vcpkg/Conan publish are gated — install from a local/CI package (or a replace / @main / path pin) until an intentional release.
Available
| Language | Package | Status | Source | Examples |
|---|---|---|---|---|
| .NET | MyHoreca.Licensing.Sdk | Preview 0.1.0-preview.1 (net10.0) | igorpooh1978/myhoreca-licensing-sdk-dotnet | QuickStart |
| JavaScript / TypeScript | @myhoreca/licensing-sdk | Preview 0.1.0-preview.1 (Node 20+ / modern browsers) | igorpooh1978/myhoreca-licensing-sdk-js | quickstart |
| Python | myhoreca-licensing-sdk | Alpha 0.1.0a1 (Python 3.11+) | igorpooh1978/myhoreca-licensing-sdk-python | quickstart |
| Java | com.myhoreca:licensing-sdk | Preview 0.1.0-preview.1 (Java 17+) | igorpooh1978/myhoreca-licensing-sdk-java | quickstart |
| Go | github.com/igorpooh1978/myhoreca-licensing-sdk-go | Preview 0.1.0-preview.1 (Go 1.23+) | igorpooh1978/myhoreca-licensing-sdk-go | quickstart |
| Rust | myhoreca-licensing-sdk | Preview 0.1.0-preview.1 (Rust 1.86+) | igorpooh1978/myhoreca-licensing-sdk-rust | quickstart |
| C++ | myhoreca-licensing-sdk | Preview 0.1.0-preview.1 (C++20 / CMake 3.20+) | igorpooh1978/myhoreca-licensing-sdk-cpp | quickstart |
.NET Quick Start
Repository (Apache-2.0): myhoreca-licensing-sdk-dotnet
Changelog: CHANGELOG.md
Compatibility: COMPATIBILITY.md
Install (preview)
Until nuget.org publish is approved, pack from source or download the CI artifact:
git clone https://github.com/igorpooh1978/myhoreca-licensing-sdk-dotnet.git
cd myhoreca-licensing-sdk-dotnet
pwsh ./tools/pack.ps1
# → artifacts/nuget/MyHoreca.Licensing.Sdk.0.1.0-preview.1.nupkg
Add a local feed / PackageReference to that nupkg in your app.
Do not treat CI artifacts as a stable public registry.
Minimal usage
using MyHoreca.Licensing.Sdk;
var client = LicensingClient.Create(new LicensingClientOptions
{
BaseUrl = new Uri("https://runtime.example"),
TenantId = tenantId,
// LicenseKey = "...", // optional — never log
});
var activated = await client.ActivateAsync(licenseId, cancellationToken);
var validated = await client.ValidateAsync(new ValidateRequest
{
LicenseId = licenseId,
LeaseToken = activated.LeaseToken
}, cancellationToken);
if (validated.IsAllowed) { /* grant feature after server decision */ }
// Local trust: fetch JWKS (inside SDK) → verify Compact JWS → enforce claims
var verified = await client.VerifyLeaseAsync(
activated.LeaseToken!,
new LeaseVerificationOptions { ExpectedAudience = "myhoreca.runtime" },
cancellationToken);
if (!verified.IsAccepted) { /* deny — see Verify trust (JWKS) */ }
Also available: RefreshLeaseAsync, RegisterDeviceAsync. Narrative: Verify trust (JWKS).
Runnable sample: examples/QuickStart
(set MYHORECA_RUNTIME_BASE_URL, MYHORECA_TENANT_ID, MYHORECA_LICENSE_ID).
Runtime surface (v1)
| Operation | SDK API |
|---|---|
| Activate | ActivateAsync |
| Validate | ValidateAsync |
| Refresh lease | RefreshLeaseAsync |
| Register device | RegisterDeviceAsync |
| JWKS / verify lease | VerifyLeaseAsync |
JavaScript / TypeScript Quick Start
Repository (Apache-2.0): myhoreca-licensing-sdk-js
Changelog: CHANGELOG.md
Compatibility: COMPATIBILITY.md
Install (preview)
Until npmjs publish is approved, pack from source or download the CI artifact:
git clone https://github.com/igorpooh1978/myhoreca-licensing-sdk-js.git
cd myhoreca-licensing-sdk-js
pnpm install
pnpm pack:local
# → artifacts/npm/myhoreca-licensing-sdk-0.1.0-preview.1.tgz
Add a local / file dependency on that tarball in your app (or a file:../myhoreca-licensing-sdk-js path during development).
Do not treat CI artifacts as a stable public registry.
npmjs publish is gated — see NPM-PUBLISH.md.
After an intentional npmjs release:
pnpm add @myhoreca/licensing-sdk
Minimal usage
import { createLicensingClient } from "@myhoreca/licensing-sdk";
const client = createLicensingClient({
baseUrl: "https://runtime.example",
tenantId,
// licenseKey: "...", // optional — never log
});
const activated = await client.activate(licenseId);
const validated = await client.validate({
licenseId,
leaseToken: activated.leaseToken,
});
if (validated.isAllowed) {
/* grant feature after server decision */
}
// Local trust: fetch JWKS (inside SDK) → verify Compact JWS → enforce claims
const verified = await client.verifyLease(activated.leaseToken!, {
expectedAudience: "myhoreca.runtime",
});
if (!verified.isAccepted) {
/* deny — see Verify trust (JWKS) */
}
Also available: refreshLease, registerDevice. Narrative: Verify trust (JWKS).
Runnable sample: examples/quickstart
(set MYHORECA_RUNTIME_BASE_URL, MYHORECA_TENANT_ID, MYHORECA_LICENSE_ID).
Runtime surface (v1)
| Operation | SDK API |
|---|---|
| Activate | activate |
| Validate | validate |
| Refresh lease | refreshLease |
| Register device | registerDevice |
| JWKS / verify lease | verifyLease / verifyLeaseToken |
Python Quick Start
Repository (Apache-2.0): myhoreca-licensing-sdk-python
Changelog: CHANGELOG.md
Compatibility: COMPATIBILITY.md
Install (alpha)
Until PyPI publish is approved, install from source or a packed wheel:
git clone https://github.com/igorpooh1978/myhoreca-licensing-sdk-python.git
cd myhoreca-licensing-sdk-python
python -m pip install -e .
# or pack:
python -m pip install build
python scripts/pack.py
# → artifacts/pypi/myhoreca_licensing_sdk-0.1.0a1-py3-none-any.whl
python -m pip install artifacts/pypi/myhoreca_licensing_sdk-0.1.0a1-py3-none-any.whl
Do not treat CI artifacts as a stable public registry.
PyPI publish is gated — see PYPI-PUBLISH.md.
After an intentional PyPI release:
python -m pip install myhoreca-licensing-sdk
Minimal usage
from myhoreca_licensing_sdk import (
LicensingClientOptions,
ValidateRequest,
create_licensing_client,
)
client = create_licensing_client(
LicensingClientOptions(
base_url="https://runtime.example",
tenant_id=tenant_id,
# license_key="...", # optional — never log
)
)
try:
activated = await client.activate(license_id)
validated = await client.validate(
ValidateRequest(license_id=license_id, lease_token=activated.lease_token)
)
if validated.is_allowed:
... # grant feature
finally:
await client.aclose()
Also available: refresh_lease, verify_lease / verify_lease_token (local ES256 via JWKS),
register_device, and sync facade create_licensing_client_sync (do not call from a running event loop).
Runnable sample: examples/quickstart
(set MYHORECA_RUNTIME_BASE_URL, MYHORECA_TENANT_ID, MYHORECA_LICENSE_ID).
Runtime surface (v1)
| Operation | SDK API |
|---|---|
| Activate | activate |
| Validate | validate |
| Refresh lease | refresh_lease |
| Register device | register_device |
| JWKS / verify lease | verify_lease / verify_lease_token |
Java Quick Start
Repository (Apache-2.0): myhoreca-licensing-sdk-java
Changelog: CHANGELOG.md
Compatibility: COMPATIBILITY.md
Install (preview)
Until Maven Central publish is approved, pack from source or download the CI artifact:
git clone https://github.com/igorpooh1978/myhoreca-licensing-sdk-java.git
cd myhoreca-licensing-sdk-java
pwsh ./tools/pack.ps1
# → artifacts/maven/com/myhoreca/licensing-sdk/0.1.0-preview.1/
./gradlew publishToMavenLocal
Depend on com.myhoreca:licensing-sdk:0.1.0-preview.1 from Maven Local (or a file-based Maven repo pointing at artifacts/maven).
Do not treat CI artifacts as a stable public registry.
Maven Central publish is gated — see MAVEN-PUBLISH.md.
After an intentional Maven Central release:
<dependency>
<groupId>com.myhoreca</groupId>
<artifactId>licensing-sdk</artifactId>
<version>0.1.0-preview.1</version>
</dependency>
Minimal usage
try (var client = LicensingClient.create(
LicensingClientOptions.builder()
.baseUrl("https://runtime.example")
.tenantId(tenantId)
// .licenseKey("...") // optional — never log
.build())) {
var activated = client.activate(licenseId);
var validated = client.validate(ValidateRequest.builder()
.licenseId(licenseId)
.leaseToken(activated.getLeaseToken())
.build());
if (validated.isAllowed()) {
/* grant feature */
}
}
Also available: refreshLease, verifyLease (local ES256 via JWKS), registerDevice.
Runnable sample: examples/quickstart
(set MYHORECA_RUNTIME_BASE_URL, MYHORECA_TENANT_ID, MYHORECA_LICENSE_ID).
Runtime surface (v1)
| Operation | SDK API |
|---|---|
| Activate | activate |
| Validate | validate |
| Refresh lease | refreshLease |
| Register device | registerDevice |
| JWKS / verify lease | verifyLease / LeaseVerifier |
Go Quick Start
Repository (Apache-2.0): myhoreca-licensing-sdk-go
Changelog: CHANGELOG.md
Compatibility: COMPATIBILITY.md
Install (preview)
Until a public version tag / proxy.golang.org index is approved, clone and pack from source (or pin @main / a replace directive during development):
git clone https://github.com/igorpooh1978/myhoreca-licensing-sdk-go.git
cd myhoreca-licensing-sdk-go
pwsh ./tools/pack.ps1
# → artifacts/module/github.com/igorpooh1978/myhoreca-licensing-sdk-go/@v/v0.1.0-preview.1.zip
Do not treat CI artifacts as a stable public module proxy.
Version-tag / proxy.golang.org publish is gated — see MODULE-PUBLISH.md.
After an intentional tagged release:
go get github.com/igorpooh1978/myhoreca-licensing-sdk-go@v0.1.0-preview.1
Minimal usage
client, err := licensing.NewClient(licensing.Options{
BaseURL: "https://runtime.example",
TenantID: &tenantID,
// LicenseKey: "...", // optional — never log
})
if err != nil { /* … */ }
defer client.Close()
activated, err := client.Activate(ctx, licenseID)
if err != nil { /* … */ }
validated, err := client.Validate(ctx, licensing.ValidateRequest{
LicenseID: &licenseID,
LeaseToken: activated.LeaseToken,
})
if err != nil { /* … */ }
if validated.Allowed() { /* grant feature */ }
Also available: RefreshLease, VerifyLease (local ES256 via JWKS), RegisterDevice.
Runnable sample: examples/quickstart
(set MYHORECA_RUNTIME_BASE_URL, MYHORECA_TENANT_ID, MYHORECA_LICENSE_ID).
Runtime surface (v1)
| Operation | SDK API |
|---|---|
| Activate | Activate / ActivateRequest |
| Validate | Validate |
| Refresh lease | RefreshLease |
| Register device | RegisterDevice |
| JWKS / verify lease | VerifyLease / VerifyLeaseOffline |
Rust Quick Start
Repository (Apache-2.0): myhoreca-licensing-sdk-rust
Changelog: CHANGELOG.md
Compatibility: COMPATIBILITY.md
Install (preview)
Until crates.io publish is approved, clone and pack from source (or depend on a path / git dependency during development). Cargo.toml keeps publish = false:
git clone https://github.com/igorpooh1978/myhoreca-licensing-sdk-rust.git
cd myhoreca-licensing-sdk-rust
pwsh ./tools/pack.ps1
# → artifacts/crate/myhoreca-licensing-sdk/myhoreca-licensing-sdk-0.1.0-preview.1.crate
In your app Cargo.toml (path pin example):
myhoreca-licensing-sdk = { path = "../myhoreca-licensing-sdk-rust" }
Do not treat CI artifacts as a stable public registry.
crates.io publish is gated — see CRATES-PUBLISH.md.
After an intentional crates.io release:
myhoreca-licensing-sdk = "0.1.0-preview.1"
Minimal usage
use myhoreca_licensing_sdk::{LicensingClient, Options, ValidateRequest};
let client = LicensingClient::new(Options {
base_url: "https://runtime.example".into(),
tenant_id: Some(tenant_id),
// license_key: Some("...".into()), // optional — never log
..Default::default()
})?;
let activated = client.activate(license_id).await?;
let validated = client
.validate(ValidateRequest {
license_id: Some(license_id),
lease_token: Some(activated.lease_token.clone()),
..Default::default()
})
.await?;
if validated.is_allowed() { /* grant feature */ }
Also available: refresh_lease, verify_lease / verify_lease_offline (local ES256 via JWKS), register_device.
Runnable sample: examples/quickstart
(set MYHORECA_RUNTIME_BASE_URL, MYHORECA_TENANT_ID, MYHORECA_LICENSE_ID).
Runtime surface (v1)
| Operation | SDK API |
|---|---|
| Activate | activate / activate_request |
| Validate | validate |
| Refresh lease | refresh_lease |
| Register device | register_device |
| JWKS / verify lease | verify_lease / verify_lease_offline |
C++ Quick Start
Repository (Apache-2.0): myhoreca-licensing-sdk-cpp
Changelog: CHANGELOG.md
Compatibility: COMPATIBILITY.md
Install (preview)
Until vcpkg / Conan publish is approved, clone and build from source (or consume a local CMake install / pack artifact during development):
git clone https://github.com/igorpooh1978/myhoreca-licensing-sdk-cpp.git
cd myhoreca-licensing-sdk-cpp
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --config Release
pwsh ./tools/pack.ps1
# → artifacts/cmake-package/myhoreca-licensing-sdk/myhoreca-licensing-sdk-0.1.0-preview.1-*.zip
In your app CMakeLists.txt (add_subdirectory / path pin example):
add_subdirectory(../myhoreca-licensing-sdk-cpp sdk EXCLUDE_FROM_ALL)
target_link_libraries(app PRIVATE myhoreca::licensing)
Do not treat CI artifacts as a stable public registry.
vcpkg / Conan publish is gated — see REGISTRY-PUBLISH.md.
After an intentional registry release:
find_package(myhoreca-licensing-sdk CONFIG REQUIRED)
target_link_libraries(app PRIVATE myhoreca::licensing)
Minimal usage
#include <myhoreca/licensing/client.hpp>
auto client = myhoreca::licensing::LicensingClient::Create({
.baseUrl = "https://runtime.example",
.tenantId = tenantId,
// .licenseKey = "...", // optional — never log
});
auto activated = client->Activate(licenseId);
auto validated = client->Validate({
.licenseId = licenseId,
.leaseToken = activated.leaseToken,
});
if (validated.IsAllowed()) { /* grant feature */ }
Also available: RefreshLease, VerifyLease / VerifyLeaseOffline (local ES256 via JWKS), RegisterDevice.
Runnable sample: examples/quickstart
(set MYHORECA_RUNTIME_BASE_URL, MYHORECA_TENANT_ID, MYHORECA_LICENSE_ID).
Runtime surface (v1)
| Operation | SDK API |
|---|---|
| Activate | Activate / ActivateRequest |
| Validate | Validate |
| Refresh lease | RefreshLease |
| Register device | RegisterDevice |
| JWKS / verify lease | VerifyLease / VerifyLeaseOffline |
Rules
- Install only from the official public repository / approved registry after release.
- Never embed private signing keys, license keys, or
platform.jsonsecrets in apps or docs samples. - Point Runtime clients at
runtime.<domain>, not Management UI hostnames. - Prefer typed SDK errors / diagnostics; do not log lease tokens or device digests.
See Choose your path for vendor vs integrator roles.