{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://yovision.local/contracts/machine-identity/v1/machine-token.schema.json", "title": "YoVision machine token claims v1", "type": "object", "additionalProperties": false, "required": ["ver", "iss", "sub", "aud", "scope", "iat", "nbf", "exp", "jti", "htm", "htu", "body_sha256"], "properties": { "ver": {"const": "yovision.machine-identity/v1"}, "iss": {"type": "string", "pattern": "^yv:(sense|brain|bell):[a-z0-9][a-z0-9.-]{0,62}$"}, "sub": {"type": "string", "pattern": "^yv:(sense|brain|bell):[a-z0-9][a-z0-9.-]{0,62}$"}, "aud": {"enum": ["yovision-sense", "yovision-brain", "yovision-bell"]}, "scope": { "type": "array", "minItems": 1, "maxItems": 4, "uniqueItems": true, "items": {"enum": ["source-config:write", "runtime-status:write", "events:ingest", "evidence:read"]} }, "iat": {"type": "integer", "minimum": 0}, "nbf": {"type": "integer", "minimum": 0}, "exp": {"type": "integer", "minimum": 0}, "jti": {"type": "string", "pattern": "^[A-Za-z0-9_-]{22,64}$"}, "htm": {"type": "string", "pattern": "^(GET|POST|PUT|PATCH|DELETE)$"}, "htu": {"type": "string", "pattern": "^/[A-Za-z0-9._~!$&'()*+,;=:@%/-]*$"}, "body_sha256": {"type": "string", "pattern": "^[a-f0-9]{64}$"} } }