Index of every page on this site: llms.txt
All skills
mcp-use avatar

/mcp-apps-builder

@338b9a7 official
by Manufactmcp-use/mcp-use11k stars
1,535
Run it yourself

Build, modify, debug, migrate, review, or verify TypeScript MCP servers and MCP Apps with mcp-use. Use for tools, resources, prompts, middleware, Views, authentication, Skills over MCP, scaffolding, and advanced features.

Use this Skill: https://skilld.dev/gh/mcp-use/mcp-use/mcp-apps-builder

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencesauth.md

≈697 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Authentication

Choose an integration

Configure OAuth when a server must identify callers or authorize access by user, organization, role, scope, or permission.

  • Use a built-in provider adapter when the identity provider supports the expected resource-server and Dynamic Client Registration flow.
  • Use oauthCustomProvider from mcp-use/oauth for another compatible provider.
  • Use the OAuth proxy and verifier helpers when the upstream authorization server uses preregistered credentials rather than Dynamic Client Registration.
  • Inspect the installed adapter declarations and current provider documentation for required options and environment variables.

Import adapters from explicit subpaths:

import { MCPServer } from "mcp-use";
import { oauthAuth0Provider } from "mcp-use/oauth/auth0";

const server = new MCPServer({
  name: "secure-server",
  version: "1.0.0",
  oauth: oauthAuth0Provider({ domain: process.env.AUTH0_DOMAIN! }),
});

Validate configuration at startup in production instead of relying on non-null assertions.

Use verified request identity

With OAuth configured, callbacks receive:

  • ctx.auth.user: provider-normalized verified identity. Built-in users have id; optional fields vary.
  • ctx.auth.scopes: grants from verified auth information.
  • ctx.auth.permissions: provider-mapped application permissions.
  • ctx.auth.payload: verified claims or introspection data.
  • ctx.auth.accessToken: the bearer token, for intentional downstream delegation only.
  • ctx.auth.clientId, expiresAt, and resource when available.

Authorize the specific action rather than checking only that a user exists:

async ({ documentId }, ctx) => {
  if (!ctx.auth.permissions.includes("documents:delete")) {
    return {
      isError: true,
      content: [{ type: "text", text: "Forbidden" }],
    };
  }

  await deleteOwnedDocument(documentId, ctx.auth.user.id);
  return { content: [{ type: "text", text: "Document deleted" }] };
};

Prefer normalized user fields. Read raw payload claims only when the provider does not map a required verified value.

Security boundaries

  • Never treat ctx.client.user(), locale, location, subject, conversation ID, or other request metadata as authenticated identity.
  • Keep authorization next to sensitive operations or in narrowly scoped MCP middleware.
  • Forward an access token only to the intended upstream resource and never log or return it.
  • Do not include client secrets, tokens, full claims, or provider payloads in examples, logs, tool content, structured output, _meta, or View state.
  • Keep multi-request state in a trusted external store. Use verified request state for sensitive elicitation flows; do not infer continuity from module globals or transport details.

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

1 warning11d5 checks · Risk SAFE
  • Gen Agent Trust Hub11d

    This skill provides comprehensive instructions for building and maintaining TypeScript MCP servers using the mcp-use framework, including scaffolding, authentication, and UI components.

  • Socket11d

    No alerts

  • Snyk11d

    Risk: LOW · No issues

  • Runlayer8mo

    6/20 files flagged

  • ZeroLeaks6mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at 338b9a7. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 6 days ago.

Activeupdated 2 weeks ago
  • MCP
  • TypeScript
  • mcp-use
  • server
  • tools
  • resources
  • prompts
  • widgets
  • authentication

README badge

README badge for mcp-use/mcp-use/mcp-apps-builder

Provides architecture patterns, best practices, and reference guides for building MCP servers with the mcp-use framework, covering tools, resources, prompts, widgets, authentication, and deployment. Essential reading before implementing any MCP server feature—use the navigation guide to find the specific reference file for your task.

Generated from the current SKILL.md.

Is this skill for building MCP servers or using them?
This skill is for building MCP servers with mcp-use. It provides architecture patterns, authentication setup, and implementation guides for tools, resources, prompts, and widgets.
Do I need to read all the reference files before starting?
No. Start with concepts.md and architecture.md for foundations, then read only the specific reference file for the feature you're implementing (e.g., tools.md for creating a tool, authentication/overview.md for adding auth).
Can I manually create MCP server boilerplate instead of using the CLI?
No. Always use `npx create-mcp-use-app` to scaffold new projects. The CLI sets up TypeScript, dev scripts, inspector integration, and widget compilation that are difficult to replicate manually.
How do I test my MCP server without the inspector UI?
Use the `mcp-use client` CLI tool to drive your server from the terminal. Commands like `npx mcp-use client connect dev http://localhost:3000/mcp` let you list and call tools directly, optionally saving a screenshot with `--screenshot`.
Does this cover widget development?
Yes. The skill includes guides for building React-based widgets covering basics, state management, interactivity, theming, file uploads, and keeping the AI model aware of UI state.

Generated from the current SKILL.md. These answers refresh after source changes.