WebMCPApi class

Constructors

WebMCPApi(Client _client)

Properties

hashCode int
The hash code for this object.
no setterinherited
onToolInvoked Stream<ToolInvokedEvent>
Event fired when a tool invocation starts.
no setter
onToolResponded Stream<ToolRespondedEvent>
Event fired when a tool invocation completes or fails.
no setter
onToolsAdded Stream<List<Tool>>
Event fired when new tools are added.
no setter
onToolsRemoved Stream<List<RemovedTool>>
Event fired when tools are removed.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

cancelInvocation(String invocationId) Future<void>
Cancels a pending tool invocation. invocationId Invocation identifier to cancel.
disable() Future<void>
Disables the WebMCP domain.
enable() Future<void>
Enables the WebMCP domain, allowing events to be sent. Enabling the domain will trigger a toolsAdded event for all currently registered tools.
invokeTool(FrameId frameId, String toolName, Map<String, dynamic> input) Future<String>
Invokes a registered tool. frameId Frame in which to invoke the tool. toolName Name of the tool to invoke. input Input parameters for the tool, matching the tool's inputSchema. Returns: Unique identifier for this invocation. Response is sent before tool events.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited