From 5e588ebcfca79c65f8295f2ecf1380768347ff97 Mon Sep 17 00:00:00 2001 From: thetek Date: Mon, 13 May 2024 15:06:29 +0200 Subject: [PATCH] feat: add conversation id --- schema-types.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/schema-types.ts b/schema-types.ts index ce03029..e17346b 100644 --- a/schema-types.ts +++ b/schema-types.ts @@ -11,7 +11,8 @@ export type SimToCmMessage = { export type Message = RequestApprovalToAttack | AcaFuelLow | MissileToOwnshipDetected | AcaDefect | AcaHeadingToBase; export type BaseMessage = { - id: MessageId, + id: Uuid, + conversationId: Uuid, priority: Priority, kind: TKind, data: TData, @@ -52,7 +53,7 @@ export type AcaHeadingToBase = BaseMessage<"AcaHeadingToBase", { /* utility types **********************************************************************************/ export type Id = number & tags.Type<"uint64">; -export type MessageId = string & tags.Format<"uuid">; +export type Uuid = string & tags.Format<"uuid">; export type Priority = DiscreteRange<0, 10>; export type Range = number & tags.Type<"float"> & tags.Minimum & tags.Maximum; export type DiscreteRange = number & tags.Type<"int64"> & tags.Minimum & tags.Maximum;