GET/api/v1/licensing/keys

List License Keys

Retrieve all license keys issued for the current organization. Keys are returned with masked values for security. Only the organization owner can list keys.

Request

Headers

HeaderRequiredDescription
AuthorizationYesBearer token

Example Request

curl https://app.storno.ro/api/v1/licensing/keys \
  -H "Authorization: Bearer {token}"

Response

Success Response (200 OK)

{
  "keys": [
    {
      "id": "019c8a12-4567-7abc-def0-123456789abc",
      "licenseKey": "a1b2c3d4...e5f6a1b2",
      "instanceName": "Production Server",
      "instanceUrl": "https://factura.mycompany.ro",
      "active": true,
      "lastValidatedAt": "2026-02-20T08:00:00+00:00",
      "activatedAt": "2026-02-01T12:00:00+00:00",
      "createdAt": "2026-02-01T10:30:00+00:00"
    },
    {
      "id": "019c8b34-5678-7def-0123-456789abcdef",
      "licenseKey": "b2c3d4e5...f6a1b2c3",
      "instanceName": "Staging",
      "instanceUrl": null,
      "active": true,
      "lastValidatedAt": null,
      "activatedAt": null,
      "createdAt": "2026-02-15T14:00:00+00:00"
    }
  ]
}
FieldTypeDescription
idstringUUID of the license key
licenseKeystringMasked key (first 8 + last 8 characters)
instanceNamestring|nullHuman-readable instance label
instanceUrlstring|nullURL reported by the self-hosted instance during validation
activebooleanWhether the key is active
lastValidatedAtstring|nullLast time this key was validated by a self-hosted instance
activatedAtstring|nullWhen the key was first used
createdAtstringISO 8601 creation timestamp

Error Codes

CodeDescription
401Unauthorized — Missing or invalid token
403Forbidden — User is not the organization owner
404Not Found — Organization not found

Usage Notes

  • License keys are masked in list responses — only the first and last 8 characters are shown
  • Use lastValidatedAt to verify that a self-hosted instance is actively running
  • Keys with lastValidatedAt: null have been created but never used
  • Inactive keys (revoked) are still returned in the list with active: false