[{"data":1,"prerenderedAt":614},["ShallowReactive",2],{"navigation_docs":3,"-resources-overview":272,"-resources-overview-surround":609},[4,40,70,99,122,151,184,243],{"title":5,"path":6,"stem":7,"children":8,"page":39},"Getting Started","\u002Fgetting-started","1.getting-started",[9,14,19,24,29,34],{"title":10,"path":11,"stem":12,"icon":13},"Introduction","\u002Fgetting-started\u002Fintroduction","1.getting-started\u002F1.introduction","i-lucide-book-open",{"title":15,"path":16,"stem":17,"icon":18},"Installation","\u002Fgetting-started\u002Finstallation","1.getting-started\u002F2.installation","i-lucide-download",{"title":20,"path":21,"stem":22,"icon":23},"Configuration","\u002Fgetting-started\u002Fconfiguration","1.getting-started\u002F3.configuration","i-lucide-settings",{"title":25,"path":26,"stem":27,"icon":28},"MCP Inspector","\u002Fgetting-started\u002Finspector","1.getting-started\u002F4.inspector","i-lucide-circuit-board",{"title":30,"path":31,"stem":32,"icon":33},"Connection","\u002Fgetting-started\u002Fconnection","1.getting-started\u002F5.connection","i-lucide-plug",{"title":35,"path":36,"stem":37,"icon":38},"Agent Skills","\u002Fgetting-started\u002Fagent-skills","1.getting-started\u002F6.agent-skills","i-lucide-sparkles",false,{"title":41,"path":42,"stem":43,"children":44,"page":39},"Tools","\u002Ftools","2.tools",[45,50,55,60,65],{"title":46,"path":47,"stem":48,"icon":49},"Overview","\u002Ftools\u002Foverview","2.tools\u002F0.overview","i-lucide-wrench",{"title":51,"path":52,"stem":53,"icon":54},"Schema, handler & returns","\u002Ftools\u002Fschema-handler","2.tools\u002F1.schema-handler","i-lucide-braces",{"title":56,"path":57,"stem":58,"icon":59},"Annotations & input examples","\u002Ftools\u002Fannotations","2.tools\u002F2.annotations","i-lucide-badge-info",{"title":61,"path":62,"stem":63,"icon":64},"Errors & caching","\u002Ftools\u002Ferrors-caching","2.tools\u002F3.errors-caching","i-lucide-shield",{"title":66,"path":67,"stem":68,"icon":69},"Groups, files & dynamic registration","\u002Ftools\u002Fgroups-organization","2.tools\u002F4.groups-organization","i-lucide-tags",{"title":71,"path":72,"stem":73,"children":74,"page":39},"Resources","\u002Fresources","3.resources",[75,79,84,89,94],{"title":46,"path":76,"stem":77,"icon":78},"\u002Fresources\u002Foverview","3.resources\u002F0.overview","i-lucide-package",{"title":80,"path":81,"stem":82,"icon":83},"Static resources & structure","\u002Fresources\u002Fstatic-and-structure","3.resources\u002F1.static-and-structure","i-lucide-file-stack",{"title":85,"path":86,"stem":87,"icon":88},"Templates & handlers","\u002Fresources\u002Ftemplates-and-handlers","3.resources\u002F2.templates-and-handlers","i-lucide-git-branch",{"title":90,"path":91,"stem":92,"icon":93},"Metadata, content & errors","\u002Fresources\u002Fcontent-metadata-errors","3.resources\u002F3.content-metadata-errors","i-lucide-layers",{"title":95,"path":96,"stem":97,"icon":98},"Groups & organization","\u002Fresources\u002Forganization","3.resources\u002F4.organization","i-lucide-folder-tree",{"title":100,"path":101,"stem":102,"children":103,"page":39},"Prompts","\u002Fprompts","4.prompts",[104,108,113,117],{"title":46,"path":105,"stem":106,"icon":107},"\u002Fprompts\u002Foverview","4.prompts\u002F0.overview","i-lucide-message-square",{"title":109,"path":110,"stem":111,"icon":112},"Authoring & structure","\u002Fprompts\u002Fauthoring","4.prompts\u002F1.authoring","i-lucide-pen-line",{"title":114,"path":115,"stem":116,"icon":93},"Input, handler & messages","\u002Fprompts\u002Finput-handler-messages","4.prompts\u002F2.input-handler-messages",{"title":118,"path":119,"stem":120,"icon":121},"Patterns & advanced","\u002Fprompts\u002Fpatterns-advanced","4.prompts\u002F3.patterns-advanced","i-lucide-line-chart",{"title":123,"path":124,"stem":125,"children":126,"page":39},"Handlers","\u002Fhandlers","5.handlers",[127,131,136,141,146],{"title":46,"path":128,"stem":129,"icon":130},"\u002Fhandlers\u002Foverview","5.handlers\u002F0.overview","i-lucide-server",{"title":132,"path":133,"stem":134,"icon":135},"Default & custom handlers","\u002Fhandlers\u002Fdefault-and-custom","5.handlers\u002F1.default-and-custom","i-lucide-toggle-left",{"title":137,"path":138,"stem":139,"icon":140},"Structure & options","\u002Fhandlers\u002Fstructure-and-options","5.handlers\u002F2.structure-and-options","i-lucide-sliders-horizontal",{"title":142,"path":143,"stem":144,"icon":145},"Examples & routing","\u002Fhandlers\u002Fexamples-routing","5.handlers\u002F3.examples-routing","i-lucide-route",{"title":147,"path":148,"stem":149,"icon":150},"Sharing & practices","\u002Fhandlers\u002Fsharing-practices","5.handlers\u002F4.sharing-practices","i-lucide-share-2",{"title":152,"path":153,"stem":154,"children":155,"page":39},"Apps","\u002Fapps","6.apps",[156,160,165,170,174,179],{"title":46,"path":157,"stem":158,"icon":159},"\u002Fapps\u002Foverview","6.apps\u002F0.overview","i-lucide-app-window",{"title":161,"path":162,"stem":163,"icon":164},"Authoring & defineMcpApp","\u002Fapps\u002Fauthoring","6.apps\u002F1.authoring","i-lucide-code-2",{"title":166,"path":167,"stem":168,"icon":169},"useMcpApp() bridge","\u002Fapps\u002Fuse-mcp-app","6.apps\u002F2.use-mcp-app","i-lucide-message-circle",{"title":171,"path":172,"stem":173,"icon":64},"CSP & build pipeline","\u002Fapps\u002Fcsp-and-wiring","6.apps\u002F3.csp-and-wiring",{"title":175,"path":176,"stem":177,"icon":178},"Testing & publishing","\u002Fapps\u002Ftesting-publishing","6.apps\u002F4.testing-publishing","i-lucide-rocket",{"title":180,"path":181,"stem":182,"icon":183},"Patterns & limits","\u002Fapps\u002Fpatterns-reference","6.apps\u002F5.patterns-reference","i-lucide-book-marked",{"title":185,"path":186,"stem":187,"children":188,"page":39},"Advanced Topics","\u002Fadvanced","7.advanced",[189,194,199,204,208,213,218,223,228,233,238],{"title":190,"path":191,"stem":192,"icon":193},"Custom Paths","\u002Fadvanced\u002Fcustom-paths","7.advanced\u002F1.custom-paths","i-lucide-folder",{"title":195,"path":196,"stem":197,"icon":198},"Logging","\u002Fadvanced\u002Flogging","7.advanced\u002F10.logging","i-lucide-scroll-text",{"title":200,"path":201,"stem":202,"icon":203},"MCP Apps Internals","\u002Fadvanced\u002Fmcp-apps-internals","7.advanced\u002F11.mcp-apps-internals","i-lucide-cog",{"title":205,"path":206,"stem":207,"icon":64},"Middleware","\u002Fadvanced\u002Fmiddleware","7.advanced\u002F2.middleware",{"title":209,"path":210,"stem":211,"icon":212},"TypeScript","\u002Fadvanced\u002Ftypescript","7.advanced\u002F3.typescript","i-lucide-type",{"title":214,"path":215,"stem":216,"icon":217},"Hooks","\u002Fadvanced\u002Fhooks","7.advanced\u002F4.hooks","i-lucide-webhook",{"title":219,"path":220,"stem":221,"icon":222},"MCP Evals","\u002Fadvanced\u002Fevals","7.advanced\u002F5.evals","i-lucide-flask-conical",{"title":224,"path":225,"stem":226,"icon":227},"Sessions","\u002Fadvanced\u002Fsessions","7.advanced\u002F6.sessions","i-lucide-database",{"title":229,"path":230,"stem":231,"icon":232},"Dynamic Definitions","\u002Fadvanced\u002Fdynamic-definitions","7.advanced\u002F7.dynamic-definitions","i-lucide-toggle-right",{"title":234,"path":235,"stem":236,"icon":237},"Code Mode","\u002Fadvanced\u002Fcode-mode","7.advanced\u002F8.code-mode","i-lucide-code",{"title":239,"path":240,"stem":241,"icon":242},"Elicitation","\u002Fadvanced\u002Felicitation","7.advanced\u002F9.elicitation","i-lucide-message-square-quote",{"title":244,"path":245,"stem":246,"children":247,"page":39},"Examples","\u002Fexamples","8.examples",[248,253,258,263,268],{"title":249,"path":250,"stem":251,"icon":252},"Authentication","\u002Fexamples\u002Fauthentication","8.examples\u002F1.authentication","i-lucide-shield-check",{"title":254,"path":255,"stem":256,"icon":257},"API Integration","\u002Fexamples\u002Fapi-integration","8.examples\u002F2.api-integration","i-lucide-globe",{"title":259,"path":260,"stem":261,"icon":262},"Common Patterns","\u002Fexamples\u002Fcommon-patterns","8.examples\u002F3.common-patterns","i-lucide-lightbulb",{"title":264,"path":265,"stem":266,"icon":267},"File Operations","\u002Fexamples\u002Ffile-operations","8.examples\u002F4.file-operations","i-lucide-file",{"title":269,"path":270,"stem":271,"icon":107},"Prompt Examples","\u002Fexamples\u002Fprompt-examples","8.examples\u002F5.prompt-examples",{"id":273,"title":71,"body":274,"description":593,"extension":594,"links":595,"meta":604,"navigation":605,"path":76,"seo":606,"stem":77,"__hash__":608},"docs\u002F3.resources\u002F0.overview.md",{"type":275,"value":276,"toc":585},"minimark",[277,282,291,338,354,366,370,373,458,463,474,479,490,494,500,535,540,544,579],[278,279,281],"h2",{"id":280},"what-are-resources","What are Resources?",[283,284,285,286,290],"p",{},"Resources are a standardized way for MCP servers to expose ",[287,288,289],"strong",{},"read-only data"," to clients. They provide contextual information that can help AI models understand your application, such as files, database schemas, configuration, or any data accessible via a URI.",[292,293,296,299,329],"prompt",{":actions":294,"description":295,"icon":78},"[\"copy\",\"cursor\",\"windsurf\"]","Scaffold a new MCP resource",[283,297,298],{},"Create a new MCP resource in my Nuxt app using @nuxtjs\u002Fmcp-toolkit.",[300,301,302,306,309,312,320,323,326],"ul",{},[303,304,305],"li",{},"Create a file in server\u002Fmcp\u002Fresources\u002F (e.g. server\u002Fmcp\u002Fresources\u002Freadme.ts)",[303,307,308],{},"Use defineMcpResource (auto-imported) with a description",[303,310,311],{},"For local files, use the file property: file: 'README.md' (URI, MIME type, and handler are auto-generated)",[303,313,314,315,319],{},"For custom data, define uri and handler manually, returning { contents: ",[316,317,318],"span",{},"{ uri, text, mimeType }"," }",[303,321,322],{},"For dynamic resources, use ResourceTemplate from @modelcontextprotocol\u002Fsdk\u002Fserver\u002Fmcp.js with URI variables",[303,324,325],{},"Name and title are auto-generated from the filename",[303,327,328],{},"Use subdirectories to auto-infer groups (e.g. resources\u002Fconfig\u002Fapp.ts → group: 'config')",[283,330,331,332],{},"Docs: ",[333,334,335],"a",{"href":335,"rel":336},"https:\u002F\u002Fmcp-toolkit.nuxt.dev\u002Fresources\u002Foverview",[337],"nofollow",[339,340,342,345,346,349,350,353],"callout",{"color":341,"icon":262},"primary",[287,343,344],{},"Key concept",": Unlike ",[333,347,348],{"href":47},"tools"," which are invoked directly by the AI to perform actions, resources are ",[287,351,352],{},"application-driven",". The host application (not the AI) decides when and how to fetch and include resource content in the conversation.",[283,355,356,357,361,362,365],{},"Each resource is uniquely identified by a URI (e.g., ",[358,359,360],"code",{},"file:\u002F\u002F\u002Fproject\u002FREADME.md"," or ",[358,363,364],{},"api:\u002F\u002Fusers\u002F123",").",[278,367,369],{"id":368},"resources-vs-tools","Resources vs Tools",[283,371,372],{},"Understanding the difference between resources and tools is essential:",[374,375,376,390],"table",{},[377,378,379],"thead",{},[380,381,382,386,388],"tr",{},[383,384,385],"th",{},"Aspect",[383,387,71],{},[383,389,41],{},[391,392,393,407,420,433,446],"tbody",{},[380,394,395,401,404],{},[396,397,398],"td",{},[287,399,400],{},"Purpose",[396,402,403],{},"Provide context and data",[396,405,406],{},"Perform actions",[380,408,409,414,417],{},[396,410,411],{},[287,412,413],{},"Invocation",[396,415,416],{},"Application-driven (user or app selects)",[396,418,419],{},"AI-driven (model decides to call)",[380,421,422,427,430],{},[396,423,424],{},[287,425,426],{},"Nature",[396,428,429],{},"Read-only data access",[396,431,432],{},"Can read and modify state",[380,434,435,440,443],{},[396,436,437],{},[287,438,439],{},"Control",[396,441,442],{},"User\u002Fapplication controls what's included",[396,444,445],{},"AI decides when to use",[380,447,448,452,455],{},[396,449,450],{},[287,451,244],{},[396,453,454],{},"Files, configs, DB schemas, logs",[396,456,457],{},"Send email, create file, query API",[283,459,460],{},[287,461,462],{},"When to use resources:",[300,464,465,468,471],{},[303,466,467],{},"Exposing project files or documentation",[303,469,470],{},"Sharing database schemas or configurations",[303,472,473],{},"Providing logs or system information as context",[283,475,476],{},[287,477,478],{},"When to use tools:",[300,480,481,484,487],{},[303,482,483],{},"Performing actions that modify state",[303,485,486],{},"Executing operations the AI should decide to trigger",[303,488,489],{},"Interacting with external APIs or services",[278,491,493],{"id":492},"how-resources-are-used","How Resources are Used",[283,495,496,497,499],{},"Resources follow an ",[287,498,352],{}," model. The typical flow:",[501,502,503,513,519,529],"ol",{},[303,504,505,508,509,512],{},[287,506,507],{},"Discovery"," — the host application calls ",[358,510,511],{},"resources\u002Flist"," to discover available resources.",[303,514,515,518],{},[287,516,517],{},"Selection"," — the host displays resources in a UI (tree view, search, list) and the user (or application logic) picks which ones to include.",[303,520,521,524,525,528],{},[287,522,523],{},"Reading"," — the host fetches the selected URIs via ",[358,526,527],{},"resources\u002Fread",".",[303,530,531,534],{},[287,532,533],{},"Context inclusion"," — the host injects the contents into the AI conversation as context.",[339,536,539],{"color":537,"icon":538},"info","i-lucide-info","The AI model never directly requests resources. It's always the application that decides which resources to include based on user selection, heuristics, or automatic context detection.",[278,541,543],{"id":542},"guides","Guides",[545,546,547,556,562,565],"card-group",{},[548,549,551,552,555],"card",{"color":550,"icon":83,"title":80,"to":81},"neutral","File-backed resources, custom handlers, naming, and the ",[358,553,554],{},"defineMcpResource"," shape.",[548,557,558,561],{"color":550,"icon":88,"title":85,"to":86},[358,559,560],{},"ResourceTemplate",", URI variables, and handler signatures.",[548,563,564],{"color":550,"icon":93,"title":90,"to":91},"MIME types, binary payloads, and error results.",[548,566,567,570,571,574,575,578],{"color":550,"icon":98,"title":95,"to":96},[358,568,569],{},"group"," \u002F ",[358,572,573],{},"tags",", directories, URI schemes, and ",[358,576,577],{},"enabled"," guards.",[283,580,581,582,584],{},"If you are new to MCP in Nuxt, start with ",[333,583,41],{"href":47}," — resources complement tools but follow a different discovery model.",{"title":586,"searchDepth":587,"depth":587,"links":588},"",2,[589,590,591,592],{"id":280,"depth":587,"text":281},{"id":368,"depth":587,"text":369},{"id":492,"depth":587,"text":493},{"id":542,"depth":587,"text":543},"Expose read-only data sources as MCP resources to provide context to AI models.","md",[596,599,600,602],{"label":597,"icon":83,"to":81,"color":550,"variant":598},"Static & structure","subtle",{"label":85,"icon":88,"to":86,"color":550,"variant":598},{"label":601,"icon":93,"to":91,"color":550,"variant":598},"Metadata & content",{"label":603,"icon":98,"to":96,"color":550,"variant":598},"Organization",{},{"title":46,"icon":78},{"title":71,"description":607},"Create MCP resources to expose read-only data sources with static or dynamic URIs.","Jx1jdTTN6fDtBhuRqajM56b2bVb9owP3F-_HdcIeqq8",[610,612],{"title":66,"path":67,"stem":68,"description":611,"icon":69,"children":-1},"group and tags, directory layout, type safety, and enabled guards for tools.",{"title":80,"path":81,"stem":82,"description":613,"icon":83,"children":-1},"File-backed resources, naming, and the shape of defineMcpResource.",1777306543054]