[{"data":1,"prerenderedAt":600},["ShallowReactive",2],{"content-query-xxbDszZl4f":3},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":5,"title":7,"description":8,"head":9,"body":20,"_type":594,"_id":595,"_source":596,"_file":597,"_stem":598,"_extension":599},"/ai","",false,"EASYGIF-AI 接入","easygif.cn 通过 WebMCP 让 AI / Agent 直接调用 GIF 制作能力",{"meta":10},[11,14,17],{"name":12,"content":13},"keywords","WebMCP,AI制作GIF,MCP,agent调用GIF,codex,Claude Code,AI接入",{"name":15,"content":16},"og:title","easygif.cn-AI 接入",{"name":18,"content":19},"og:description","easygif.cn-让 AI 直接帮你制作 GIF",{"type":21,"children":22,"toc":584},"root",[23,32,46,55,61,88,93,116,122,127,157,164,169,229,235,240,246,268,286,298,308,319,325,337,343,348,369,374,379,568],{"type":24,"tag":25,"props":26,"children":28},"element","h1",{"id":27},"让-ai-帮你做-gif",[29],{"type":30,"value":31},"text","让 AI 帮你做 GIF",{"type":24,"tag":33,"props":34,"children":35},"p",{},[36,38,44],{"type":30,"value":37},"EasyGIF 把「图片转 GIF」「视频转 GIF」的能力，以 ",{"type":24,"tag":39,"props":40,"children":41},"strong",{},[42],{"type":30,"value":43},"WebMCP",{"type":30,"value":45}," 标准暴露成了 AI 可调用的工具。也就是说，你不用再手动点页面，而是可以让你的 Codex/Claude Code/Workbuddy 等 AI 工具直接帮你生成 GIF，结果会自动下载到本地。",{"type":24,"tag":47,"props":48,"children":49},"blockquote",{},[50],{"type":24,"tag":33,"props":51,"children":52},{},[53],{"type":30,"value":54},"WebMCP 是由 W3C 社区推进、Google/Microsoft 共同提出的浏览器标准，让网页可以主动向 AI 暴露「工具」，而不是让 AI 去截图猜按钮。",{"type":24,"tag":56,"props":57,"children":59},"h3",{"id":58},"理解原理",[60],{"type":30,"value":58},{"type":24,"tag":62,"props":63,"children":64},"ul",{},[65,71,76],{"type":24,"tag":66,"props":67,"children":68},"li",{},[69],{"type":30,"value":70},"你打开本站任意页面时，本站会自动把工具注册到浏览器里（无需任何操作）。",{"type":24,"tag":66,"props":72,"children":73},{},[74],{"type":30,"value":75},"你的 Agent 只要「够得着」这个页面，就能发现并调用这些工具。",{"type":24,"tag":66,"props":77,"children":78},{},[79,81,86],{"type":30,"value":80},"GIF 在",{"type":24,"tag":39,"props":82,"children":83},{},[84],{"type":30,"value":85},"你自己的浏览器里",{"type":30,"value":87},"完成编码，本站不上传你的图片/视频，也不经过服务器。",{"type":24,"tag":56,"props":89,"children":91},{"id":90},"谁现在就能用",[92],{"type":30,"value":90},{"type":24,"tag":62,"props":94,"children":95},{},[96,106],{"type":24,"tag":66,"props":97,"children":98},{},[99,104],{"type":24,"tag":39,"props":100,"children":101},{},[102],{"type":30,"value":103},"浏览器内的 AI",{"type":30,"value":105},"（开启了 WebMCP 的 Chrome、或装了支持 WebMCP 的扩展）：打开页面即可被发现，无需额外配置。",{"type":24,"tag":66,"props":107,"children":108},{},[109,114],{"type":24,"tag":39,"props":110,"children":111},{},[112],{"type":30,"value":113},"命令行 / 桌面 Agent",{"type":30,"value":115},"（Codex、Claude Code、WorkBuddy 等）：需要按下面第二节做一次本地配置。",{"type":24,"tag":56,"props":117,"children":119},{"id":118},"一浏览器内-ai推荐零配置",[120],{"type":30,"value":121},"一、浏览器内 AI（推荐，零配置）",{"type":24,"tag":33,"props":123,"children":124},{},[125],{"type":30,"value":126},"如果你的浏览器自带 AI 或装了 WebMCP 扩展：",{"type":24,"tag":128,"props":129,"children":130},"ol",{},[131,147,152],{"type":24,"tag":66,"props":132,"children":133},{},[134,136,145],{"type":30,"value":135},"打开 ",{"type":24,"tag":137,"props":138,"children":142},"a",{"href":139,"rel":140},"https://easygif.cn",[141],"nofollow",[143],{"type":30,"value":144},"easygif.cn",{"type":30,"value":146}," 任意制作页面（如「图片转 GIF」「视频转 GIF」）。",{"type":24,"tag":66,"props":148,"children":149},{},[150],{"type":30,"value":151},"直接对你的 AI 助手说，例如：「把这几张图做成一张 GIF」。",{"type":24,"tag":66,"props":153,"children":154},{},[155],{"type":30,"value":156},"AI 会调用本站工具，GIF 自动下载到你的「下载」目录。",{"type":24,"tag":158,"props":159,"children":161},"h4",{"id":160},"开启-chrome-原生支持实验阶段",[162],{"type":30,"value":163},"开启 Chrome 原生支持（实验阶段）",{"type":24,"tag":33,"props":165,"children":166},{},[167],{"type":30,"value":168},"目前 Chrome 的 WebMCP 还在实验阶段，需要手动开启：",{"type":24,"tag":128,"props":170,"children":171},{},[172,177,211,216],{"type":24,"tag":66,"props":173,"children":174},{},[175],{"type":30,"value":176},"确认 Chrome 版本 ≥ 146。",{"type":24,"tag":66,"props":178,"children":179},{},[180,182,187,189],{"type":30,"value":181},"地址栏分别打开并设为 ",{"type":24,"tag":39,"props":183,"children":184},{},[185],{"type":30,"value":186},"Enabled",{"type":30,"value":188},"：\n",{"type":24,"tag":62,"props":190,"children":191},{},[192,202],{"type":24,"tag":66,"props":193,"children":194},{},[195],{"type":24,"tag":196,"props":197,"children":199},"code",{"className":198},[],[200],{"type":30,"value":201},"chrome://flags/#enable-webmcp-testing",{"type":24,"tag":66,"props":203,"children":204},{},[205],{"type":24,"tag":196,"props":206,"children":208},{"className":207},[],[209],{"type":30,"value":210},"chrome://flags/#devtools-webmcp-support",{"type":24,"tag":66,"props":212,"children":213},{},[214],{"type":30,"value":215},"重启浏览器。",{"type":24,"tag":66,"props":217,"children":218},{},[219,221,227],{"type":30,"value":220},"打开任意页面，按 F12 在控制台输入 ",{"type":24,"tag":196,"props":222,"children":224},{"className":223},[],[225],{"type":30,"value":226},"navigator.modelContext",{"type":30,"value":228},"，能看到对象即为成功。",{"type":24,"tag":56,"props":230,"children":232},{"id":231},"二命令行-桌面-agentcodex-claude-code-workbuddy",[233],{"type":30,"value":234},"二、命令行 / 桌面 Agent（codex / Claude Code / WorkBuddy）",{"type":24,"tag":33,"props":236,"children":237},{},[238],{"type":30,"value":239},"这类 Agent 运行在浏览器之外，需要一个本地「中继」把浏览器里的工具桥接出去。配置一次即可。",{"type":24,"tag":56,"props":241,"children":243},{"id":242},"_1-给你的-agent-添加中继-mcp",[244],{"type":30,"value":245},"1. 给你的 Agent 添加中继 MCP",{"type":24,"tag":33,"props":247,"children":248},{},[249,251,258,260,266],{"type":30,"value":250},"中继由开源项目 ",{"type":24,"tag":137,"props":252,"children":255},{"href":253,"rel":254},"https://www.npmjs.com/package/@mcp-b/webmcp-local-relay",[141],[256],{"type":30,"value":257},"@mcp-b/webmcp-local-relay",{"type":30,"value":259}," 提供，用 ",{"type":24,"tag":196,"props":261,"children":263},{"className":262},[],[264],{"type":30,"value":265},"npx",{"type":30,"value":267}," 即可运行，无需全局安装。",{"type":24,"tag":33,"props":269,"children":270},{},[271,276,278,284],{"type":24,"tag":39,"props":272,"children":273},{},[274],{"type":30,"value":275},"codex",{"type":30,"value":277},"（编辑 ",{"type":24,"tag":196,"props":279,"children":281},{"className":280},[],[282],{"type":30,"value":283},"~/.codex/config.toml",{"type":30,"value":285},"）：",{"type":24,"tag":287,"props":288,"children":293},"pre",{"className":289,"code":291,"language":292,"meta":5},[290],"language-toml","[mcp_servers.webmcp_relay]\ncommand = \"npx\"\nargs = [\"-y\", \"@mcp-b/webmcp-local-relay@latest\"]\nstartup_timeout_sec = 120\n","toml",[294],{"type":24,"tag":196,"props":295,"children":296},{"__ignoreMap":5},[297],{"type":30,"value":291},{"type":24,"tag":33,"props":299,"children":300},{},[301,306],{"type":24,"tag":39,"props":302,"children":303},{},[304],{"type":30,"value":305},"Claude Code / Claude Desktop / WorkBuddy 等",{"type":30,"value":307},"（JSON 格式的 MCP 配置）：",{"type":24,"tag":287,"props":309,"children":314},{"className":310,"code":312,"language":313,"meta":5},[311],"language-json","{\n  \"mcpServers\": {\n    \"webmcp_relay\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@mcp-b/webmcp-local-relay@latest\"]\n    }\n  }\n}\n","json",[315],{"type":24,"tag":196,"props":316,"children":317},{"__ignoreMap":5},[318],{"type":30,"value":312},{"type":24,"tag":158,"props":320,"children":322},{"id":321},"_2-打开本站页面",[323],{"type":30,"value":324},"2. 打开本站页面",{"type":24,"tag":33,"props":326,"children":327},{},[328,330,335],{"type":30,"value":329},"在浏览器打开 ",{"type":24,"tag":137,"props":331,"children":333},{"href":139,"rel":332},[141],[334],{"type":30,"value":144},{"type":30,"value":336}," 的任意制作页面并保持开着——工具依附于这个标签页，关掉就没了。",{"type":24,"tag":158,"props":338,"children":340},{"id":339},"_3-在-agent-里调用",[341],{"type":30,"value":342},"3. 在 Agent 里调用",{"type":24,"tag":33,"props":344,"children":345},{},[346],{"type":30,"value":347},"启动你的 Agent，它会自动拉起中继并发现页面。你可以让它：",{"type":24,"tag":62,"props":349,"children":350},{},[351,364],{"type":24,"tag":66,"props":352,"children":353},{},[354,356,362],{"type":30,"value":355},"列出可用工具（会看到 ",{"type":24,"tag":196,"props":357,"children":359},{"className":358},[],[360],{"type":30,"value":361},"easygif_*",{"type":30,"value":363},"）；",{"type":24,"tag":66,"props":365,"children":366},{},[367],{"type":30,"value":368},"调用工具生成 GIF。例如让它执行「图片转 GIF」并传入图片地址。",{"type":24,"tag":33,"props":370,"children":371},{},[372],{"type":30,"value":373},"GIF 会在浏览器自动下载，同时工具也会把 GIF 字节返回给 Agent。",{"type":24,"tag":56,"props":375,"children":377},{"id":376},"可用工具一览",[378],{"type":30,"value":376},{"type":24,"tag":380,"props":381,"children":382},"table",{},[383,407],{"type":24,"tag":384,"props":385,"children":386},"thead",{},[387],{"type":24,"tag":388,"props":389,"children":390},"tr",{},[391,397,402],{"type":24,"tag":392,"props":393,"children":394},"th",{},[395],{"type":30,"value":396},"工具",{"type":24,"tag":392,"props":398,"children":399},{},[400],{"type":30,"value":401},"作用",{"type":24,"tag":392,"props":403,"children":404},{},[405],{"type":30,"value":406},"主要参数",{"type":24,"tag":408,"props":409,"children":410},"tbody",{},[411,434,496],{"type":24,"tag":388,"props":412,"children":413},{},[414,424,429],{"type":24,"tag":415,"props":416,"children":417},"td",{},[418],{"type":24,"tag":196,"props":419,"children":421},{"className":420},[],[422],{"type":30,"value":423},"easygif_list_tools",{"type":24,"tag":415,"props":425,"children":426},{},[427],{"type":30,"value":428},"列出本站全部可用工具",{"type":24,"tag":415,"props":430,"children":431},{},[432],{"type":30,"value":433},"无",{"type":24,"tag":388,"props":435,"children":436},{},[437,446,451],{"type":24,"tag":415,"props":438,"children":439},{},[440],{"type":24,"tag":196,"props":441,"children":443},{"className":442},[],[444],{"type":30,"value":445},"easygif_create_gif_from_images",{"type":24,"tag":415,"props":447,"children":448},{},[449],{"type":30,"value":450},"多张图片合成 GIF",{"type":24,"tag":415,"props":452,"children":453},{},[454,460,462,468,469,475,476,482,483,489,490],{"type":24,"tag":196,"props":455,"children":457},{"className":456},[],[458],{"type":30,"value":459},"imageUrls",{"type":30,"value":461},"、",{"type":24,"tag":196,"props":463,"children":465},{"className":464},[],[466],{"type":30,"value":467},"width",{"type":30,"value":461},{"type":24,"tag":196,"props":470,"children":472},{"className":471},[],[473],{"type":30,"value":474},"height",{"type":30,"value":461},{"type":24,"tag":196,"props":477,"children":479},{"className":478},[],[480],{"type":30,"value":481},"delay",{"type":30,"value":461},{"type":24,"tag":196,"props":484,"children":486},{"className":485},[],[487],{"type":30,"value":488},"maxColors",{"type":30,"value":461},{"type":24,"tag":196,"props":491,"children":493},{"className":492},[],[494],{"type":30,"value":495},"background",{"type":24,"tag":388,"props":497,"children":498},{},[499,508,513],{"type":24,"tag":415,"props":500,"children":501},{},[502],{"type":24,"tag":196,"props":503,"children":505},{"className":504},[],[506],{"type":30,"value":507},"easygif_video_to_gif",{"type":24,"tag":415,"props":509,"children":510},{},[511],{"type":30,"value":512},"视频转 GIF（FFmpeg）",{"type":24,"tag":415,"props":514,"children":515},{},[516,522,523,528,529,534,535,541,542,548,549,554,555,561,562],{"type":24,"tag":196,"props":517,"children":519},{"className":518},[],[520],{"type":30,"value":521},"videoUrl",{"type":30,"value":461},{"type":24,"tag":196,"props":524,"children":526},{"className":525},[],[527],{"type":30,"value":467},{"type":30,"value":461},{"type":24,"tag":196,"props":530,"children":532},{"className":531},[],[533],{"type":30,"value":474},{"type":30,"value":461},{"type":24,"tag":196,"props":536,"children":538},{"className":537},[],[539],{"type":30,"value":540},"fps",{"type":30,"value":461},{"type":24,"tag":196,"props":543,"children":545},{"className":544},[],[546],{"type":30,"value":547},"speed",{"type":30,"value":461},{"type":24,"tag":196,"props":550,"children":552},{"className":551},[],[553],{"type":30,"value":488},{"type":30,"value":461},{"type":24,"tag":196,"props":556,"children":558},{"className":557},[],[559],{"type":30,"value":560},"start",{"type":30,"value":461},{"type":24,"tag":196,"props":563,"children":565},{"className":564},[],[566],{"type":30,"value":567},"duration",{"type":24,"tag":47,"props":569,"children":570},{},[571],{"type":24,"tag":33,"props":572,"children":573},{},[574,576,582],{"type":30,"value":575},"所有工具默认会在浏览器直接触发 GIF 下载（可用参数 ",{"type":24,"tag":196,"props":577,"children":579},{"className":578},[],[580],{"type":30,"value":581},"download: false",{"type":30,"value":583}," 关闭），同时返回 GIF 图片字节（base64）。",{"title":5,"searchDepth":585,"depth":585,"links":586},2,[587,589,590,591,592,593],{"id":58,"depth":588,"text":58},3,{"id":90,"depth":588,"text":90},{"id":118,"depth":588,"text":121},{"id":231,"depth":588,"text":234},{"id":242,"depth":588,"text":245},{"id":376,"depth":588,"text":376},"markdown","content:ai.md","content","ai.md","ai","md",1782579676843]