Add tool annotations to all Everything server tools

Previously only get-annotated-message had ToolAnnotations. Now all 18
tools explicitly declare readOnlyHint, destructiveHint, idempotentHint,
and openWorldHint so the server serves as a complete reference for
developers implementing tool annotations per the MCP spec.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
olaservo 2026-02-06 05:35:51 -07:00
commit baf99300a2
17 changed files with 102 additions and 0 deletions

View file

@ -13,6 +13,12 @@ const config = {
title: "Echo Tool",
description: "Echoes back the input string",
inputSchema: EchoSchema,
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -8,6 +8,12 @@ const config = {
description:
"Returns all environment variables, helpful for debugging MCP server configuration",
inputSchema: {},
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -25,6 +25,12 @@ const config = {
description:
"Returns up to ten resource links that reference different types of resources",
inputSchema: GetResourceLinksSchema,
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -28,6 +28,12 @@ const config = {
title: "Get Resource Reference Tool",
description: "Returns a resource reference that can be used by MCP clients",
inputSchema: GetResourceReferenceSchema,
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -9,6 +9,12 @@ const config = {
description:
"Lists the current MCP roots provided by the client. Demonstrates the roots protocol capability even though this server doesn't access files.",
inputSchema: {},
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -27,6 +27,12 @@ const config = {
"Returns structured content along with an output schema for client data validation",
inputSchema: GetStructuredContentInputSchema,
outputSchema: GetStructuredContentOutputSchema,
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -14,6 +14,12 @@ const config = {
title: "Get Sum Tool",
description: "Returns the sum of two numbers",
inputSchema: GetSumSchema,
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -11,6 +11,12 @@ const config = {
title: "Get Tiny Image Tool",
description: "Returns a tiny MCP logo image.",
inputSchema: {},
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -48,6 +48,12 @@ const config = {
description:
"Compresses a single file using gzip compression. Depending upon the selected output type, returns either the compressed data as a gzipped resource or a resource link, allowing it to be downloaded in a subsequent request during the current session.",
inputSchema: GZipFileAsResourceSchema,
annotations: {
readOnlyHint: false,
destructiveHint: false,
idempotentHint: true,
openWorldHint: true,
},
};
/**

View file

@ -255,6 +255,12 @@ export const registerSimulateResearchQueryTool = (server: McpServer) => {
"If 'ambiguous' is true and client supports elicitation, sends an elicitation request for clarification.",
inputSchema: SimulateResearchQuerySchema,
execution: { taskSupport: "required" },
annotations: {
readOnlyHint: false,
destructiveHint: false,
idempotentHint: false,
openWorldHint: false,
},
},
{
/**

View file

@ -11,6 +11,12 @@ const config = {
title: "Toggle Simulated Logging",
description: "Toggles simulated, random-leveled logging on or off.",
inputSchema: {},
annotations: {
readOnlyHint: false,
destructiveHint: false,
idempotentHint: false,
openWorldHint: false,
},
};
// Track enabled clients by session id

View file

@ -11,6 +11,12 @@ const config = {
title: "Toggle Subscriber Updates",
description: "Toggles simulated resource subscription updates on or off.",
inputSchema: {},
annotations: {
readOnlyHint: false,
destructiveHint: false,
idempotentHint: false,
openWorldHint: false,
},
};
// Track enabled clients by session id

View file

@ -11,6 +11,12 @@ const config = {
"Demonstrates bidirectional MCP tasks where the server sends an elicitation request and " +
"the client handles user input asynchronously, allowing the server to poll for completion.",
inputSchema: {},
annotations: {
readOnlyHint: false,
destructiveHint: false,
idempotentHint: false,
openWorldHint: false,
},
};
// Poll interval in milliseconds

View file

@ -10,6 +10,12 @@ const config = {
title: "Trigger Elicitation Request Tool",
description: "Trigger a Request from the Server for User Elicitation",
inputSchema: {},
annotations: {
readOnlyHint: false,
destructiveHint: false,
idempotentHint: false,
openWorldHint: false,
},
};
/**

View file

@ -17,6 +17,12 @@ const config = {
title: "Trigger Long Running Operation Tool",
description: "Demonstrates a long running operation with progress updates.",
inputSchema: TriggerLongRunningOperationSchema,
annotations: {
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true,
openWorldHint: false,
},
};
/**

View file

@ -23,6 +23,12 @@ const config = {
"Demonstrates bidirectional MCP tasks where the server sends a request and the client " +
"executes it asynchronously, allowing the server to poll for progress and results.",
inputSchema: TriggerSamplingRequestAsyncSchema,
annotations: {
readOnlyHint: false,
destructiveHint: false,
idempotentHint: false,
openWorldHint: true,
},
};
// Poll interval in milliseconds

View file

@ -21,6 +21,12 @@ const config = {
title: "Trigger Sampling Request Tool",
description: "Trigger a Request from the Server for LLM Sampling",
inputSchema: TriggerSamplingRequestSchema,
annotations: {
readOnlyHint: false,
destructiveHint: false,
idempotentHint: false,
openWorldHint: true,
},
};
/**