using System.Text.Json; namespace Nexus.Api.Models; /// /// Transport-safe reference to a Nexus or OpenClaw-owned entity. Routing stays /// a frontend concern, so this contract deliberately contains no URL. /// public sealed record EntityRefDto( string Type, string Id, string? Label = null); public sealed record OperationResultDto( string OperationId, string Status, int Revision, EntityRefDto? PrimaryRef, IReadOnlyList AffectedRefs, string? TraceId); /// /// Content-minimized event sent to authenticated Mission Control clients. /// Payloads may carry state and correlation metadata, but never prompts, /// credentials, markdown content, tool arguments, or entity names. /// public sealed record DomainEventDto( long Sequence, string EventType, EntityRefDto Entity, int EntityRevision, DateTimeOffset OccurredAt, JsonElement Payload); public static class DomainEventTypes { public const string ResyncRequired = "resync_required"; }