跳到正文
TakoAPI
返回技能列表

web-mcp

由 slemo54 提供

Web & Frontend Development
466下载量由 clawskills.sh 提供
0浏览量
0 个赞登录后即可为这个技能点赞
—暂无评分
你的评分

简介

WebMCP - Enable AI agents to interact with your web applications through structured tools.

描述

该技能的功能

WebMCP is a standard for exposing web application functionality to AI agents through structured, typed tools. Pages register named tools with JSON Schema definitions that agents discover and call via navigator.modelContext, instead of using DOM selectors or screen scraping. A CLI, React hooks, and an event bridge pattern handle tool registration and lifecycle in Next.js apps.

Agents get a stable, typed contract that survives UI redesigns, unlike CSS selectors or screenshot parsing.

何时使用

  • Letting an AI agent search products on an e-commerce site without DOM access
  • Exposing cart management actions as typed, callable tools for agents
  • Building an agent-navigable dashboard with filter and export tools
  • Adding structured agent access to a blog's search and comment features
  • Wrapping internal web app actions so agents can trigger them reliably

示例工作流

输入

User asks: Add the blue sneakers to my cart

智能体
  1. 1

    Reads available tools from navigator.modelContext on the current page

  2. 2

    Calls searchProducts with query 'blue sneakers'

  3. 3

    Identifies the product ID from returned results

  4. 4

    Calls addToCart with the product ID

  5. 5

    Receives tool completion event confirming the item was added

输出

Blue sneakers added to cart successfully

安装

clawhub install slemo54/web-mcp

运行 CLI 命令,或把这段提示词粘贴到 Claude Code、Cursor、Codex 或你在用的任意编程智能体里。

链接