toolmark-monorepo / @toolmark/core/webmcp / WebMcpToolDescriptor
Interface: WebMcpToolDescriptor
Defined in: packages/core/src/webmcp/model-context.ts:32
Experimental
The tool descriptor handed to ModelContext.registerTool. WebMCP is an origin-trial API; this adapter is outside semver (D28).
Properties
annotations?
optionalannotations?:WebMcpToolAnnotations
Defined in: packages/core/src/webmcp/model-context.ts:42
Experimental
Behaviour annotations.
description
description:
string
Defined in: packages/core/src/webmcp/model-context.ts:38
Experimental
Natural-language description.
inputSchema?
optionalinputSchema?:object
Defined in: packages/core/src/webmcp/model-context.ts:40
Experimental
Input JSON Schema.
name
name:
string
Defined in: packages/core/src/webmcp/model-context.ts:34
Experimental
Tool name (1–128 characters: ASCII alphanumerics, _, -, .).
title?
optionaltitle?:string
Defined in: packages/core/src/webmcp/model-context.ts:36
Experimental
Human-readable title.
Methods
execute()
execute(
input,options?):Promise<unknown>
Defined in: packages/core/src/webmcp/model-context.ts:48
Experimental
Runs the tool. Resolves the result object; the browser or polyfill serializes it once.
Parameters
input
unknown
The input object (a JSON string is also accepted).
options?
Execution options (absent under the polyfill).
Returns
Promise<unknown>