MCPcopy Index your code
hub / github.com/simstudioai/sim / enqueueEvent

Function enqueueEvent

apps/sim/app/api/copilot/chat/stream/route.ts:296–306  ·  view source on GitHub ↗
(payload: unknown)

Source from the content-addressed store, hash-verified

294 }
295
296 const enqueueEvent = (payload: unknown) => {
297 if (controllerClosed) return false
298 try {
299 controller.enqueue(encodeSSEEnvelope(payload))
300 lastWriteTime = Date.now()
301 return true
302 } catch {
303 controllerClosed = true
304 return false
305 }
306 }
307
308 const enqueueComment = (comment: string) => {
309 if (controllerClosed) return false

Callers 3

flushEventsFunction · 0.85
emitTerminalIfMissingFunction · 0.85
startInnerFunction · 0.85

Calls 2

encodeSSEEnvelopeFunction · 0.90
enqueueMethod · 0.65

Tested by

no test coverage detected