webmcpThis skill should be used when browsing or automating web pages that expose tools via the WebMCP API (window.navigator.modelContext). It teaches agents how to discover, inspect, and invoke WebMCP tools on websites instead of relying on DOM scraping or UI actuation.
Install via ClawdBot CLI:
clawdbot install brunobuddy/webmcpWebMCP is a browser API that lets websites expose JavaScript functions as structured tools for AI agents. Pages register tools via window.navigator.modelContext, each with a name, description, JSON Schema input, and an execute callback. Think of it as an MCP server running inside the web page itself.
Spec: https://github.com/webmachinelearning/webmcp
Before interacting with tools, check whether the current page supports WebMCP:
const supported = "modelContext" in window.navigator;
If false, the page does not expose WebMCP tools — fall back to DOM interaction or actuation.
Tools are registered by the page via provideContext() or registerTool(). The browser mediates access. To list available tools from an agent's perspective, evaluate:
// Browser-specific — the exact discovery API depends on the agent runtime.
// Typically the browser exposes registered tools to connected agents automatically.
// From page-script perspective, tools are registered like this:
window.navigator.modelContext.provideContext({
tools: [
{
name: "tool-name",
description: "What this tool does",
inputSchema: { type: "object", properties: { /* ... */ }, required: [] },
execute: (params, agent) => { /* ... */ }
}
]
});
Key points:
name, description, inputSchema (JSON Schema), and execute.provideContext() replaces all previously registered tools (useful for SPA state changes).registerTool() / unregisterTool() add/remove individual tools without resetting.Tool input schemas follow JSON Schema (aligned with MCP SDK and Prompt API tool use):
{
name: "add-stamp",
description: "Add a new stamp to the collection",
inputSchema: {
type: "object",
properties: {
name: { type: "string", description: "The name of the stamp" },
year: { type: "number", description: "Year the stamp was issued" },
imageUrl: { type: "string", description: "Optional image URL" }
},
required: ["name", "year"]
},
execute({ name, year, imageUrl }, agent) {
// Implementation — updates UI and app state
return {
content: [{ type: "text", text: `Stamp "${name}" added.` }]
};
}
}
When connected as an agent, send a tool call by name with parameters matching inputSchema. The execute callback runs on the page's main thread, can update the UI, and returns a structured response:
// Response format from execute():
{
content: [
{ type: "text", text: "Result description" }
]
}
execute may be async (returns a Promise).agent provides agent.requestUserInteraction() for user confirmation flows.Tools can request user confirmation before sensitive actions:
async function buyProduct({ product_id }, agent) {
const confirmed = await agent.requestUserInteraction(async () => {
return confirm(`Buy product ${product_id}?`);
});
if (!confirmed) throw new Error("Cancelled by user.");
executePurchase(product_id);
return { content: [{ type: "text", text: `Product ${product_id} purchased.` }] };
}
Always respect user denials — do not retry cancelled tool calls.
"modelContext" in window.navigator to confirm WebMCP support.inputSchema.Generated Mar 1, 2026
An AI agent can use WebMCP tools to add products to a shopping cart, apply discount codes, or complete checkout steps on e-commerce sites that expose these functions. This avoids fragile DOM scraping of dynamic product pages and ensures reliable cart updates even during SPA navigation.
On banking or investment platforms, an agent can invoke WebMCP tools to fetch portfolio summaries, execute trades with user confirmation, or generate reports. This provides structured access to sensitive financial actions without simulating clicks on complex, security-sensitive UI elements.
For websites with WebMCP-enabled admin panels, agents can directly call tools to create blog posts, upload media, or update page content using structured schemas. This bypasses the need to automate form filling and button clicks in dynamic CMS interfaces.
On travel sites, agents can use WebMCP tools to search flights, select seats, and book reservations with built-in user confirmation flows. This ensures reliable booking automation as tools adapt to real-time availability changes without DOM dependency.
Within helpdesk software, agents can invoke WebMCP tools to create tickets, assign priorities, or add notes based on customer queries. This allows precise interaction with ticket systems that update dynamically as agents navigate between support queues.
Offer a subscription-based platform where businesses integrate WebMCP into their web apps, enabling AI agents to perform tasks like data entry, customer support, or transaction processing. Revenue comes from tiered plans based on tool usage volume and support levels.
Provide consulting and development services to large companies for embedding WebMCP tools into their internal web applications (e.g., HR systems, inventory management). Revenue is generated through project-based contracts and ongoing maintenance fees.
Create a marketplace for browser extensions that leverage WebMCP tools to enhance user productivity on supported websites. Revenue is earned via paid extensions, freemium models, or commissions on sales, targeting users who automate repetitive web tasks.
💬 Integration Tip
Start by adding WebMCP to key user actions like form submissions or data queries, and use provideContext() during SPA state changes to keep tools updated without requiring page reloads.
Use the mcporter CLI to list, configure, auth, and call MCP servers/tools directly (HTTP or stdio), including ad-hoc servers, config edits, and CLI/type generation.
Connect to 100+ APIs (Google Workspace, Microsoft 365, GitHub, Notion, Slack, Airtable, HubSpot, etc.) with managed OAuth. Use this skill when users want to...
Build, debug, and deploy websites using HTML, CSS, JavaScript, and modern frameworks following production best practices.
YouTube Data API integration with managed OAuth. Search videos, manage playlists, access channel data, and interact with comments. Use this skill when users want to interact with YouTube. For other third party apps, use the api-gateway skill (https://clawhub.ai/byungkyu/api-gateway).
Scaffold, test, document, and debug REST and GraphQL APIs. Use when the user needs to create API endpoints, write integration tests, generate OpenAPI specs, test with curl, mock APIs, or troubleshoot HTTP issues.
Search for jobs across LinkedIn, Indeed, Glassdoor, ZipRecruiter, Google Jobs, Bayt, Naukri, and BDJobs using the JobSpy MCP server.