MCPcopy Index your code
hub / github.com/Waishnav/devspace / logFailedToolResponse

Function logFailedToolResponse

src/server.ts:300–312  ·  view source on GitHub ↗
(
  config: ServerConfig,
  fields: Omit<ToolLogFields, "success" | "durationMs" | "error">,
  content: ToolContent[],
  startedAt: number,
)

Source from the content-addressed store, hash-verified

298}
299
300function logFailedToolResponse(
301 config: ServerConfig,
302 fields: Omit<ToolLogFields, "success" | "durationMs" | "error">,
303 content: ToolContent[],
304 startedAt: number,
305): void {
306 logToolCall(config, {
307 ...fields,
308 success: false,
309 durationMs: Math.round(performance.now() - startedAt),
310 error: toolErrorPreview(content),
311 });
312}
313
314function textBlock(text: string): ToolContent {
315 return { type: "text", text };

Callers 1

createMcpServerFunction · 0.85

Calls 2

logToolCallFunction · 0.85
toolErrorPreviewFunction · 0.85

Tested by

no test coverage detected