MCPcopy Create free account
hub / github.com/Linen-dev/linen.dev / serializeTopic

Function serializeTopic

packages/serializers/src/thread.ts:118–130  ·  view source on GitHub ↗
(topic: {
  id: string;
  threadId: string | null;
  sentAt: Date;
  usersId: string | null;
})

Source from the content-addressed store, hash-verified

116}
117
118export function serializeTopic(topic: {
119 id: string;
120 threadId: string | null;
121 sentAt: Date;
122 usersId: string | null;
123}): SerializedTopic {
124 return {
125 messageId: topic.id,
126 threadId: topic.threadId!,
127 sentAt: new Date(topic.sentAt).toISOString(),
128 usersId: topic.usersId,
129 };
130}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected