From 03da12ad4e12adc944a13f857ddcceacd2121d24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iwo=20Strzebo=C5=84ski?= Date: Thu, 15 Oct 2026 21:44:36 +0000 Subject: [PATCH] Type the envelope's _by fields as ids, not timestamps `created_by` and `updated_by` in `continuum/common/envelope.schema.json` were `format: date-time`, copied from the `_at` lines directly above them. They are the id of whoever wrote the row. Nothing validates against this schema yet, so nothing had failed - but it is $ref'd by six continuum/v1 domain types (vendor, material, spool, printer_info, firmware_info, module_info), and the first thing to validate one of them would have rejected every real value. `format: uuid`, matching `id` in the same schema and the Supabase subject the backend already treats as the actor. No TS or Rust mirror to update: the ts-types package exports edge and ai only, and the domain envelope has no generated counterpart on either side. Co-Authored-By: Claude Opus 5 --- schemas/continuum/common/envelope.schema.json | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/schemas/continuum/common/envelope.schema.json b/schemas/continuum/common/envelope.schema.json index d0810da..1953569 100644 --- a/schemas/continuum/common/envelope.schema.json +++ b/schemas/continuum/common/envelope.schema.json @@ -2,12 +2,13 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://git.octoturge.com/Continuum/continuum-schemas/raw/branch/main/schemas/continuum/common/envelope.schema.json", "title": "MessageEnvelope", + "description": "Row provenance shared by the continuum/v1 domain types that $ref it: vendor, material, spool, printer_info, firmware_info and module_info. The _by fields are the actor's id, not a timestamp - they were typed as date-time here, copied from the _at lines above them, which would have rejected every real value the moment anything started validating against this.", "type": "object", "properties": { "id": { "type": "string", "format": "uuid" }, "created_at": { "type": "string", "format": "date-time" }, - "created_by": { "type": "string", "format": "date-time" }, + "created_by": { "type": "string", "format": "uuid" }, "updated_at": { "type": "string", "format": "date-time" }, - "updated_by": { "type": "string", "format": "date-time" } + "updated_by": { "type": "string", "format": "uuid" } } }