81 lines
1.8 KiB
JSON
81 lines
1.8 KiB
JSON
{
|
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
"$id": "https://hwlab.pikastech.local/protocol/schemas/common.json",
|
|
"title": "HWLAB Common Schema Definitions",
|
|
"type": "object",
|
|
"$defs": {
|
|
"id": {
|
|
"type": "string",
|
|
"minLength": 3,
|
|
"maxLength": 128,
|
|
"pattern": "^[a-z][a-z0-9]*_[A-Za-z0-9._:-]+$"
|
|
},
|
|
"timestamp": {
|
|
"type": "string",
|
|
"format": "date-time"
|
|
},
|
|
"environment": {
|
|
"type": "string",
|
|
"enum": ["dev"]
|
|
},
|
|
"serviceId": {
|
|
"type": "string",
|
|
"enum": [
|
|
"hwlab-cloud-api",
|
|
"hwlab-cloud-web",
|
|
"hwlab-agent-mgr",
|
|
"hwlab-agent-worker",
|
|
"hwlab-device-pod",
|
|
"hwlab-gateway",
|
|
"hwlab-edge-proxy",
|
|
"hwlab-agent-skills"
|
|
]
|
|
},
|
|
"lifecycleStatus": {
|
|
"type": "string",
|
|
"enum": ["pending", "active", "inactive", "failed", "deleted"]
|
|
},
|
|
"resourceState": {
|
|
"type": "string",
|
|
"enum": ["available", "reserved", "running", "maintenance", "offline"]
|
|
},
|
|
"operationStatus": {
|
|
"type": "string",
|
|
"enum": [
|
|
"requested",
|
|
"accepted",
|
|
"queued",
|
|
"running",
|
|
"succeeded",
|
|
"failed",
|
|
"rejected",
|
|
"canceled",
|
|
"timed_out"
|
|
]
|
|
},
|
|
"actorType": {
|
|
"type": "string",
|
|
"enum": ["user", "service", "agent", "worker", "system"]
|
|
},
|
|
"auditOutcome": {
|
|
"type": "string",
|
|
"enum": ["accepted", "succeeded", "failed", "rejected", "canceled"]
|
|
},
|
|
"traceLevel": {
|
|
"type": "string",
|
|
"enum": ["debug", "info", "warn", "error"]
|
|
},
|
|
"labels": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"type": "string",
|
|
"maxLength": 256
|
|
}
|
|
},
|
|
"jsonObject": {
|
|
"type": "object",
|
|
"additionalProperties": true
|
|
}
|
|
}
|
|
}
|