Skip to content

Interface: ToolAnnotations

Defined in: packages/core/src/domain/ToolAnnotations.ts:22

MCP Tool Annotations — behavioral hints for LLMs.

These annotations provide metadata that helps LLMs make safer decisions about when and how to invoke a tool.

Example

typescript
import { createToolAnnotations } from '@vinkius-core/mcp-fusion';

const annotations = createToolAnnotations({
    title: 'File Reader',
    readOnlyHint: true,
    destructiveHint: false,
    idempotentHint: true,
});

See

Properties

destructiveHint?

ts
readonly optional destructiveHint: boolean;

Defined in: packages/core/src/domain/ToolAnnotations.ts:28

Hint that this tool may cause irreversible changes


idempotentHint?

ts
readonly optional idempotentHint: boolean;

Defined in: packages/core/src/domain/ToolAnnotations.ts:30

Hint that calling this tool multiple times has the same effect


openWorldHint?

ts
readonly optional openWorldHint: boolean;

Defined in: packages/core/src/domain/ToolAnnotations.ts:32

Hint that the tool may access external/uncontrolled systems


readOnlyHint?

ts
readonly optional readOnlyHint: boolean;

Defined in: packages/core/src/domain/ToolAnnotations.ts:26

Hint that this tool only reads data (no side effects)


returnDirect?

ts
readonly optional returnDirect: boolean;

Defined in: packages/core/src/domain/ToolAnnotations.ts:34

Hint that the response should be returned directly to the user


title?

ts
readonly optional title: string;

Defined in: packages/core/src/domain/ToolAnnotations.ts:24

Human-readable display title for the tool