WebMCP Domain
Methods
Events
Types
Methods
Events
WebMCP.toolInvoked #
Event fired when a tool invocation starts.
Parameters
toolName stringName of the tool to invoke.
frameId Frame id
invocationId stringInvocation identifier.
input stringThe input parameters used for the invocation.
WebMCP.toolResponded #
Event fired when a tool invocation completes or fails.
Parameters
invocationId stringInvocation identifier.
status Status of the invocation.
outputOptional
anyOutput or error delivered as delivered to the agent. Missing if status is anything other than Success.
errorTextOptional
stringError text for protocol users.
exceptionOptional
The exception object, if the javascript tool threw an error>
Types
WebMCP.Annotation #
Tool annotations
Type: object
Properties
readOnlyOptional
booleanA hint indicating that the tool does not modify any state.
autosubmitOptional
booleanIf the declarative tool was declared with the autosubmit attribute.
WebMCP.InvocationStatus #
Represents the status of a tool invocation.
Type: string
Allowed values: Success, Canceled, Error
WebMCP.Tool #
Definition of a tool that can be invoked.
Type: object
Properties
name stringTool name.
description stringTool description.
inputSchemaOptional
objectSchema for the tool's input parameters.
annotationsOptional
Optional annotations for the tool.
frameId Frame identifier associated with the tool registration.
backendNodeIdOptional
Optional node ID for declarative tools.
stackTraceOptional
The stack trace at the time of the registration.