MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / handleList

Function handleList

packages/server/src/routes/fs.ts:330–344  ·  view source on GitHub ↗
(
  ix: IInstantiationService,
  sessionId: string,
  req: { id: string; body: unknown },
  reply: { send(payload: unknown): unknown },
)

Source from the content-addressed store, hash-verified

328}
329
330async function handleList(
331 ix: IInstantiationService,
332 sessionId: string,
333 req: { id: string; body: unknown },
334 reply: { send(payload: unknown): unknown },
335): Promise<void> {
336 const parsed = fsListRequestSchema.safeParse(req.body ?? {});
337 if (!parsed.success) {
338 reply.send(buildValidationEnvelope(parsed.error.issues, req.id));
339 return;
340 }
341 const body: FsListRequest = parsed.data;
342 const data = await ix.invokeFunction((a) => a.get(IFsService).list(sessionId, body));
343 reply.send(okEnvelope(data, req.id));
344}
345
346async function handleRead(
347 ix: IInstantiationService,

Callers 1

registerFsRoutesFunction · 0.85

Calls 6

okEnvelopeFunction · 0.90
buildValidationEnvelopeFunction · 0.70
sendMethod · 0.65
invokeFunctionMethod · 0.65
listMethod · 0.65
getMethod · 0.65

Tested by

no test coverage detected