[{"data":1,"prerenderedAt":259},["ShallowReactive",2],{"page:\u002Fdocs\u002F5.x\u002Freference\u002Fcommands\u002Fmcp":3},{"id":4,"title":5,"body":6,"description":241,"extension":242,"frontmatter":243,"heading":5,"meta":250,"navigation":252,"order":247,"path":253,"seo":254,"sitemap":255,"source":256,"stem":257,"__hash__":258},"docs\u002Fdocs\u002F5.x\u002Freference\u002Fcommands\u002Fmcp.md","kubb mcp",{"type":7,"value":8,"toc":234},"minimark",[9,27,32,38,46,51,210,214],[10,11,12,13,16,17,22,23,26],"p",{},"Run ",[14,15,5],"code",{}," to start a ",[18,19,21],"a",{"href":20},"https:\u002F\u002Fmodelcontextprotocol.io\u002F","Model Context Protocol"," server. AI clients such as Claude Code, Claude Desktop, Cursor, and VS Code can then validate your spec, scaffold a ",[14,24,25],{},"kubb.config.ts",", and run generation.",[28,29,31],"blockquote",{"as":30},"warning","This feature is under active development. Use it with caution and expect breaking changes.",[33,34],"terminal",{"command":5,":output":35},[36,37],"⏳ Starting MCP server...","This feature is still under development, use with caution",[10,39,40,41,45],{},"The server uses the stdio transport, so the client starts it as a local process. ",[18,42,44],{"href":43},"\u002Fdocs\u002F5.x\u002Fai\u002Fmcp","Set up the MCP server"," shows the client configuration.",[47,48,50],"h2",{"id":49},"tools","Tools",[52,53,54,70],"table",{},[55,56,57],"thead",{},[58,59,60,64,67],"tr",{},[61,62,63],"th",{},"Tool",[61,65,66],{},"Parameters",[61,68,69],{},"Description",[71,72,73,155,171],"tbody",{},[58,74,75,81,152],{},[76,77,78],"td",{},[14,79,80],{},"generate",[76,82,83,86,87,90,91,94,95,98,99,102,103,102,106,102,109,102,112,102,115,118,119,122,123,126,127,130,131,134,135,138,139,102,142,102,145,148,149,151],{},[14,84,85],{},"config?"," (path to a config file inside the working directory. When omitted, the server searches the same way ",[14,88,89],{},"kubb generate"," does: ",[14,92,93],{},".kubbrc"," then ",[14,96,97],{},"kubb.config"," with the ",[14,100,101],{},"ts",", ",[14,104,105],{},"mts",[14,107,108],{},"cts",[14,110,111],{},"js",[14,113,114],{},"mjs",[14,116,117],{},"cjs"," extensions, in the working directory, its ",[14,120,121],{},".config\u002F"," and ",[14,124,125],{},"configs\u002F"," folders, then each parent folder), ",[14,128,129],{},"input?"," (spec path, overrides the config), ",[14,132,133],{},"output?"," (output directory, overrides the config), ",[14,136,137],{},"logLevel?"," (",[14,140,141],{},"silent",[14,143,144],{},"info",[14,146,147],{},"verbose",", default ",[14,150,144],{},", passed to a config that exports a function)",[76,153,154],{},"Runs the Kubb pipeline. On success, it returns the file count and the warnings and diagnostics raised. On failure, it returns each diagnostic with its code, fix, and docs link instead. A config that exports an array runs its first entry.",[58,156,157,162,168],{},[76,158,159],{},[14,160,161],{},"validate",[76,163,164,167],{},[14,165,166],{},"input"," (path or URL, required)",[76,169,170],{},"Validates an OpenAPI or Swagger document with the bundled OpenAPI adapter.",[58,172,173,178,193],{},[76,174,175],{},[14,176,177],{},"init",[76,179,180,182,183,186,187,182,189,192],{},[14,181,129],{}," (default ",[14,184,185],{},".\u002Fopenapi.yaml","), ",[14,188,133],{},[14,190,191],{},".\u002Fsrc\u002Fgen",")",[76,194,195,196,198,199,202,203,206,207,209],{},"Writes a ",[14,197,25],{}," with an empty ",[14,200,201],{},"plugins"," array in the working directory without prompts. It does not install packages or add plugins: its reply tells the agent to run ",[14,204,205],{},"kubb add \u003Cid> --yes"," for each one. It fails when ",[14,208,25],{}," already exists.",[47,211,213],{"id":212},"working-directory","Working directory",[10,215,216,217,219,220,223,224,226,227,229,230,233],{},"The server runs in the folder the client starts it in. ",[14,218,80],{}," looks for its config there, then in its parent folders, and rejects a ",[14,221,222],{},"config"," path outside it, and ",[14,225,177],{}," writes ",[14,228,25],{}," there. ",[18,231,44],{"href":232},"\u002Fdocs\u002F5.x\u002Fai\u002Fmcp#working-directory"," shows how to start the server in your project.",{"title":235,"searchDepth":236,"depth":236,"links":237},"",5,[238,240],{"id":49,"depth":239,"text":50},2,{"id":212,"depth":239,"text":213},"The mcp command starts a Model Context Protocol server so AI clients can validate your spec, scaffold a config, and run generation.","md",{"layout":244,"title":5,"description":241,"outline":245,"order":247,"navigation":248},"doc",[239,246],3,4,{"title":5,"icon":249},"i-simple-icons-modelcontextprotocol",{"layout":244,"outline":251},[239,246],{"title":5,"icon":249},"\u002Fdocs\u002F5.x\u002Freference\u002Fcommands\u002Fmcp",{"title":5,"description":241},{"loc":253},"kubb-labs\u002Fkubb\u002Fdocs\u002F5.x\u002Freference\u002Fcommands\u002Fmcp.md","docs\u002F5.x\u002Freference\u002Fcommands\u002Fmcp","G6b96sbiBu0gEKTyZOky8WzNzzHxjtGZxmYmuJaIHzw",1793288240760]