Licenses API
Manage software license keys with activation tracking, feature support, and public verification.
List Licenses
GET /api/licensesResponse 200 OK
[
{
"id": "01JQX...",
"licenseKey": "RUSTBILL-XXXX-XXXX-XXXX",
"customerId": "01JQA...",
"productId": "01JQB...",
"status": "active",
"maxActivations": 5,
"currentActivations": 2,
"features": {
"api_access": true,
"premium_support": true,
"max_users": 50
},
"expiresAt": "2027-01-15T00:00:00Z",
"createdAt": "2026-01-15T10:30:00Z"
}
]Create License
POST /api/licenses
Content-Type: application/jsonBody
| Field | Type | Required | Description |
|---|---|---|---|
customerId | UUID | Yes | License owner |
productId | UUID | Yes | Licensed product |
maxActivations | integer | No | Device limit (default: unlimited) |
features | object | No | Feature flags / limits |
expiresAt | string | No | ISO 8601 expiration date |
A unique license key is auto-generated.
Update License
PUT /api/licenses/:key
Content-Type: application/jsonNote: licenses are addressed by their key string, not UUID.
| Field | Type | Description |
|---|---|---|
status | string | active, suspended, revoked |
maxActivations | integer | Update device limit |
features | object | Update feature flags |
expiresAt | string | Update expiration |
Delete License
DELETE /api/licenses/:keyPublic Verification (No Auth Required)
These endpoints are public — designed to be called from your software’s license check:
Verify License
POST /api/licenses/verify
Content-Type: application/json
{
"licenseKey": "RUSTBILL-XXXX-XXXX-XXXX"
}Response 200 OK
{
"valid": true,
"status": "active",
"features": { "api_access": true },
"expiresAt": "2027-01-15T00:00:00Z"
}Validate and Activate
POST /api/licenses/validate
Content-Type: application/json
{
"licenseKey": "RUSTBILL-XXXX-XXXX-XXXX",
"deviceId": "device-fingerprint-hash",
"deviceName": "John's Laptop"
}Validates the license and registers a device activation. Returns an error if the activation limit is reached.
License Statuses
| Status | Description |
|---|---|
active | Valid and usable |
expired | Past expiration date |
suspended | Temporarily disabled |
revoked | Permanently disabled |
Last updated on