Public API
Activate license
Activate a license for a device.
licenseKeystring
The key of the license to activate.
deviceIdentifierstring
A unique identifier of the device. Must have at most 96 characters.
deviceNamestring
The name of the device. Must have at most 64 characters.
productIdstring|
The product ID of the license. Can be a single string or an array of strings.
Response Body
application/json
application/json
curl -X POST "https://keyforge.dev/api/v1/public/licenses/activate" \ -H "Content-Type: application/json" \ -d '{ "licenseKey": "ABCDE-ABCDE-ABCDE-ABCDE-ABCDE", "deviceIdentifier": "some_device_id", "deviceName": "My computer name", "productId": "p_123456" }'{
"isValid": true,
"token": "...",
"device": {
"identifier": "some_device_id",
"name": "My computer name",
"activationDate": "2024-05-19T18:39:33.000Z"
},
"license": {
"key": "ABCDE-ABCDE-ABCDE-ABCDE-ABCDE",
"productId": "p_123456",
"type": "perpetual",
"revoked": false,
"maxDevices": 5,
"expiresAt": null,
"createdAt": "2024-05-19T18:39:33.000Z"
}
}{
"error": {
"code": "license_revoked",
"message": "License is revoked."
}
}