Docs

Think of this as the quickstart.

This is a static documentation preview for FastDRM. The code examples are here to show how a real SDK could feel — they are not wired to any live API.

Quickstart overview

In a real product, you would create an API key in the dashboard, install a language SDK, and call validate() at launch. FastDRM would return license validity, tier, and entitlements in a single round‑trip.

Code examples

ts static example
import { FastDrmClient } from "fastdrm";

const client = new FastDrmClient({ apiKey: process.env.FASTDRM_KEY! });

const result = await client.validate({
  licenseKey: "FD-XXXX-XXXX-XXXX",
  productId: "desktop_pro",
  deviceFingerprint: "device-123"
});

if (!result.valid) {
  throw new Error("License invalid or expired");
}
ts static example
const entitlements = await client.getEntitlements({
  licenseKey: "FD-XXXX-XXXX-XXXX"
});

if (entitlements.features.includes("advanced-reporting")) {
  enableAdvancedReporting();
}
json static example
{
  "id": "evt_01H...",
  "type": "license.upgraded",
  "data": {
    "license_key": "FD-XXXX-XXXX-XXXX",
    "previous_plan": "starter",
    "new_plan": "pro"
  }
}

Webhook events

In production, FastDRM would fire webhook events for upgrades, downgrades, and suspicious usage so your billing and support tools stay up to date.