@frontmcp/skills 1.0.0-beta.9 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/catalog/TEMPLATE.md +69 -0
- package/catalog/frontmcp-config/SKILL.md +38 -22
- package/catalog/frontmcp-config/examples/configure-auth/multi-app-auth.md +87 -0
- package/catalog/frontmcp-config/examples/configure-auth/public-mode-setup.md +63 -0
- package/catalog/frontmcp-config/examples/configure-auth/remote-oauth-with-vault.md +76 -0
- package/catalog/frontmcp-config/examples/configure-auth-modes/local-self-signed-tokens.md +77 -0
- package/catalog/frontmcp-config/examples/configure-auth-modes/remote-enterprise-oauth.md +73 -0
- package/catalog/frontmcp-config/examples/configure-auth-modes/transparent-jwt-validation.md +64 -0
- package/catalog/frontmcp-config/examples/configure-elicitation/basic-confirmation-gate.md +83 -0
- package/catalog/frontmcp-config/examples/configure-elicitation/distributed-elicitation-redis.md +87 -0
- package/catalog/frontmcp-config/examples/configure-http/cors-restricted-origins.md +52 -0
- package/catalog/frontmcp-config/examples/configure-http/entry-path-reverse-proxy.md +72 -0
- package/catalog/frontmcp-config/examples/configure-http/unix-socket-local.md +64 -0
- package/catalog/frontmcp-config/examples/configure-session/multi-server-key-prefix.md +68 -0
- package/catalog/frontmcp-config/examples/configure-session/redis-session-store.md +52 -0
- package/catalog/frontmcp-config/examples/configure-session/vercel-kv-session.md +52 -0
- package/catalog/frontmcp-config/examples/configure-throttle/distributed-redis-throttle.md +94 -0
- package/catalog/frontmcp-config/examples/configure-throttle/per-tool-rate-limit.md +92 -0
- package/catalog/frontmcp-config/examples/configure-throttle/server-level-rate-limit.md +83 -0
- package/catalog/frontmcp-config/examples/configure-throttle-guard-config/full-guard-config.md +99 -0
- package/catalog/frontmcp-config/examples/configure-throttle-guard-config/minimal-guard-config.md +55 -0
- package/catalog/frontmcp-config/examples/configure-transport/custom-protocol-flags.md +74 -0
- package/catalog/frontmcp-config/examples/configure-transport/distributed-sessions-redis.md +86 -0
- package/catalog/frontmcp-config/examples/configure-transport/stateless-serverless.md +69 -0
- package/catalog/frontmcp-config/examples/configure-transport-protocol-presets/legacy-preset-nodejs.md +65 -0
- package/catalog/frontmcp-config/examples/configure-transport-protocol-presets/stateless-api-serverless.md +69 -0
- package/catalog/frontmcp-config/references/configure-auth-modes.md +15 -0
- package/catalog/frontmcp-config/references/configure-auth.md +15 -0
- package/catalog/frontmcp-config/references/configure-elicitation.md +14 -0
- package/catalog/frontmcp-config/references/configure-http.md +15 -0
- package/catalog/frontmcp-config/references/configure-session.md +15 -0
- package/catalog/frontmcp-config/references/configure-throttle-guard-config.md +14 -0
- package/catalog/frontmcp-config/references/configure-throttle.md +15 -0
- package/catalog/frontmcp-config/references/configure-transport-protocol-presets.md +14 -0
- package/catalog/frontmcp-config/references/configure-transport.md +15 -0
- package/catalog/frontmcp-config/references/setup-redis.md +10 -0
- package/catalog/frontmcp-config/references/setup-sqlite.md +10 -0
- package/catalog/frontmcp-deployment/SKILL.md +40 -12
- package/catalog/frontmcp-deployment/examples/build-for-browser/browser-build-with-custom-entry.md +43 -0
- package/catalog/frontmcp-deployment/examples/build-for-browser/browser-crypto-and-storage.md +85 -0
- package/catalog/frontmcp-deployment/examples/build-for-browser/react-provider-setup.md +61 -0
- package/catalog/frontmcp-deployment/examples/build-for-cli/cli-binary-build.md +66 -0
- package/catalog/frontmcp-deployment/examples/build-for-cli/unix-socket-daemon.md +76 -0
- package/catalog/frontmcp-deployment/examples/build-for-sdk/connect-openai.md +78 -0
- package/catalog/frontmcp-deployment/examples/build-for-sdk/create-flat-config.md +85 -0
- package/catalog/frontmcp-deployment/examples/build-for-sdk/multi-platform-connect.md +104 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-cloudflare/basic-worker-deploy.md +82 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-cloudflare/worker-custom-domain.md +97 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-cloudflare/worker-with-kv-storage.md +92 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-lambda/cdk-deployment.md +92 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-lambda/lambda-handler-with-cors.md +113 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-lambda/sam-template-basic.md +100 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-node/docker-compose-with-redis.md +101 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-node/pm2-with-nginx.md +79 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-node/resource-limits.md +92 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-node-dockerfile/basic-multistage-dockerfile.md +63 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-node-dockerfile/secure-nonroot-dockerfile.md +89 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-vercel/vercel-mcp-endpoint-test.md +69 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-vercel/vercel-with-kv.md +82 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-vercel/vercel-with-skills-cache.md +90 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-vercel-config/minimal-vercel-config.md +49 -0
- package/catalog/frontmcp-deployment/examples/deploy-to-vercel-config/vercel-config-with-security-headers.md +92 -0
- package/catalog/frontmcp-deployment/references/build-for-browser.md +15 -0
- package/catalog/frontmcp-deployment/references/build-for-cli.md +65 -3
- package/catalog/frontmcp-deployment/references/build-for-sdk.md +15 -0
- package/catalog/frontmcp-deployment/references/deploy-to-cloudflare.md +15 -0
- package/catalog/frontmcp-deployment/references/deploy-to-lambda.md +18 -3
- package/catalog/frontmcp-deployment/references/deploy-to-node-dockerfile.md +16 -2
- package/catalog/frontmcp-deployment/references/deploy-to-node.md +19 -4
- package/catalog/frontmcp-deployment/references/deploy-to-vercel-config.md +14 -0
- package/catalog/frontmcp-deployment/references/deploy-to-vercel.md +15 -0
- package/catalog/frontmcp-development/SKILL.md +25 -17
- package/catalog/frontmcp-development/examples/create-adapter/basic-api-adapter.md +92 -0
- package/catalog/frontmcp-development/examples/create-adapter/namespaced-adapter.md +124 -0
- package/catalog/frontmcp-development/examples/create-agent/basic-agent-with-tools.md +121 -0
- package/catalog/frontmcp-development/examples/create-agent/custom-multi-pass-agent.md +95 -0
- package/catalog/frontmcp-development/examples/create-agent/nested-agents-with-swarm.md +111 -0
- package/catalog/frontmcp-development/examples/create-agent-llm-config/anthropic-config.md +81 -0
- package/catalog/frontmcp-development/examples/create-agent-llm-config/openai-config.md +80 -0
- package/catalog/frontmcp-development/examples/create-job/basic-report-job.md +87 -0
- package/catalog/frontmcp-development/examples/create-job/job-with-permissions.md +117 -0
- package/catalog/frontmcp-development/examples/create-job/job-with-retry.md +88 -0
- package/catalog/frontmcp-development/examples/create-plugin/basic-plugin-with-provider.md +69 -0
- package/catalog/frontmcp-development/examples/create-plugin/configurable-dynamic-plugin.md +178 -0
- package/catalog/frontmcp-development/examples/create-plugin/plugin-with-context-extension.md +107 -0
- package/catalog/frontmcp-development/examples/create-plugin-hooks/basic-logging-plugin.md +69 -0
- package/catalog/frontmcp-development/examples/create-plugin-hooks/caching-with-around.md +80 -0
- package/catalog/frontmcp-development/examples/create-plugin-hooks/tool-level-hooks-and-stage-replacement.md +100 -0
- package/catalog/frontmcp-development/examples/create-prompt/basic-prompt.md +72 -0
- package/catalog/frontmcp-development/examples/create-prompt/dynamic-rag-prompt.md +92 -0
- package/catalog/frontmcp-development/examples/create-prompt/multi-turn-debug-session.md +86 -0
- package/catalog/frontmcp-development/examples/create-provider/basic-database-provider.md +113 -0
- package/catalog/frontmcp-development/examples/create-provider/config-and-api-providers.md +107 -0
- package/catalog/frontmcp-development/examples/create-resource/basic-static-resource.md +72 -0
- package/catalog/frontmcp-development/examples/create-resource/binary-and-multi-content.md +111 -0
- package/catalog/frontmcp-development/examples/create-resource/parameterized-template.md +84 -0
- package/catalog/frontmcp-development/examples/create-skill/basic-inline-skill.md +96 -0
- package/catalog/frontmcp-development/examples/create-skill/directory-based-skill.md +115 -0
- package/catalog/frontmcp-development/examples/create-skill/parameterized-skill.md +96 -0
- package/catalog/frontmcp-development/examples/create-skill-with-tools/basic-tool-orchestration.md +76 -0
- package/catalog/frontmcp-development/examples/create-skill-with-tools/directory-skill-with-tools.md +149 -0
- package/catalog/frontmcp-development/examples/create-skill-with-tools/incident-response-skill.md +92 -0
- package/catalog/frontmcp-development/examples/create-tool/basic-class-tool.md +62 -0
- package/catalog/frontmcp-development/examples/create-tool/tool-with-di-and-errors.md +84 -0
- package/catalog/frontmcp-development/examples/create-tool/tool-with-rate-limiting-and-progress.md +93 -0
- package/catalog/frontmcp-development/examples/create-tool-annotations/destructive-delete-tool.md +94 -0
- package/catalog/frontmcp-development/examples/create-tool-annotations/readonly-query-tool.md +60 -0
- package/catalog/frontmcp-development/examples/create-tool-output-schema-types/primitive-and-media-outputs.md +104 -0
- package/catalog/frontmcp-development/examples/create-tool-output-schema-types/zod-raw-shape-output.md +63 -0
- package/catalog/frontmcp-development/examples/create-tool-output-schema-types/zod-schema-advanced-output.md +103 -0
- package/catalog/frontmcp-development/examples/create-workflow/basic-deploy-pipeline.md +91 -0
- package/catalog/frontmcp-development/examples/create-workflow/parallel-validation-pipeline.md +90 -0
- package/catalog/frontmcp-development/examples/create-workflow/webhook-triggered-workflow.md +136 -0
- package/catalog/frontmcp-development/examples/decorators-guide/agent-skill-job-workflow.md +145 -0
- package/catalog/frontmcp-development/examples/decorators-guide/basic-server-with-app-and-tools.md +124 -0
- package/catalog/frontmcp-development/examples/decorators-guide/multi-app-with-plugins-and-providers.md +149 -0
- package/catalog/frontmcp-development/examples/official-adapters/authenticated-adapter-with-polling.md +84 -0
- package/catalog/frontmcp-development/examples/official-adapters/basic-openapi-adapter.md +54 -0
- package/catalog/frontmcp-development/examples/official-adapters/multi-api-hub-with-inline-spec.md +130 -0
- package/catalog/frontmcp-development/examples/official-plugins/cache-and-feature-flags.md +117 -0
- package/catalog/frontmcp-development/examples/official-plugins/production-multi-plugin-setup.md +147 -0
- package/catalog/frontmcp-development/examples/official-plugins/remember-plugin-session-memory.md +104 -0
- package/catalog/frontmcp-development/references/create-adapter.md +14 -0
- package/catalog/frontmcp-development/references/create-agent-llm-config.md +14 -0
- package/catalog/frontmcp-development/references/create-agent.md +15 -0
- package/catalog/frontmcp-development/references/create-job.md +15 -0
- package/catalog/frontmcp-development/references/create-plugin-hooks.md +51 -0
- package/catalog/frontmcp-development/references/create-plugin.md +186 -11
- package/catalog/frontmcp-development/references/create-prompt.md +17 -0
- package/catalog/frontmcp-development/references/create-provider.md +14 -0
- package/catalog/frontmcp-development/references/create-resource.md +127 -0
- package/catalog/frontmcp-development/references/create-skill-with-tools.md +126 -7
- package/catalog/frontmcp-development/references/create-skill.md +57 -12
- package/catalog/frontmcp-development/references/create-tool-annotations.md +14 -0
- package/catalog/frontmcp-development/references/create-tool-output-schema-types.md +15 -0
- package/catalog/frontmcp-development/references/create-tool.md +205 -1
- package/catalog/frontmcp-development/references/create-workflow.md +15 -0
- package/catalog/frontmcp-development/references/decorators-guide.md +155 -78
- package/catalog/frontmcp-development/references/official-adapters.md +31 -16
- package/catalog/frontmcp-development/references/official-plugins.md +62 -28
- package/catalog/frontmcp-extensibility/SKILL.md +103 -0
- package/catalog/frontmcp-extensibility/examples/vectoriadb/product-catalog-search.md +175 -0
- package/catalog/frontmcp-extensibility/examples/vectoriadb/semantic-search-with-persistence.md +138 -0
- package/catalog/frontmcp-extensibility/examples/vectoriadb/tfidf-keyword-search.md +103 -0
- package/catalog/frontmcp-extensibility/references/vectoriadb.md +299 -0
- package/catalog/frontmcp-guides/SKILL.md +7 -4
- package/catalog/frontmcp-guides/examples/example-knowledge-base/agent-and-plugin.md +160 -0
- package/catalog/frontmcp-guides/examples/example-knowledge-base/multi-app-composition.md +92 -0
- package/catalog/frontmcp-guides/examples/example-knowledge-base/vector-search-and-resources.md +135 -0
- package/catalog/frontmcp-guides/examples/example-task-manager/auth-and-crud-tools.md +135 -0
- package/catalog/frontmcp-guides/examples/example-task-manager/authenticated-e2e-tests.md +148 -0
- package/catalog/frontmcp-guides/examples/example-task-manager/redis-provider-with-di.md +129 -0
- package/catalog/frontmcp-guides/examples/example-weather-api/server-and-app-setup.md +75 -0
- package/catalog/frontmcp-guides/examples/example-weather-api/unit-and-e2e-tests.md +142 -0
- package/catalog/frontmcp-guides/examples/example-weather-api/weather-tool-with-schemas.md +74 -0
- package/catalog/frontmcp-guides/references/example-knowledge-base.md +15 -0
- package/catalog/frontmcp-guides/references/example-task-manager.md +30 -21
- package/catalog/frontmcp-guides/references/example-weather-api.md +18 -6
- package/catalog/frontmcp-observability/SKILL.md +144 -0
- package/catalog/frontmcp-observability/examples/structured-logging/stdout-logging.md +71 -0
- package/catalog/frontmcp-observability/examples/structured-logging/winston-integration.md +70 -0
- package/catalog/frontmcp-observability/examples/telemetry-api/agent-nested-tracing.md +86 -0
- package/catalog/frontmcp-observability/examples/telemetry-api/plugin-telemetry.md +93 -0
- package/catalog/frontmcp-observability/examples/telemetry-api/tool-custom-spans.md +72 -0
- package/catalog/frontmcp-observability/examples/testing-observability/test-custom-spans.md +90 -0
- package/catalog/frontmcp-observability/examples/testing-observability/test-log-correlation.md +104 -0
- package/catalog/frontmcp-observability/examples/tracing-setup/basic-tracing.md +82 -0
- package/catalog/frontmcp-observability/examples/tracing-setup/production-tracing.md +73 -0
- package/catalog/frontmcp-observability/examples/vendor-integrations/coralogix-setup.md +74 -0
- package/catalog/frontmcp-observability/references/structured-logging.md +114 -0
- package/catalog/frontmcp-observability/references/telemetry-api.md +155 -0
- package/catalog/frontmcp-observability/references/testing-observability.md +169 -0
- package/catalog/frontmcp-observability/references/tracing-setup.md +146 -0
- package/catalog/frontmcp-observability/references/vendor-integrations.md +164 -0
- package/catalog/frontmcp-production-readiness/SKILL.md +99 -0
- package/catalog/frontmcp-production-readiness/examples/common-checklist/caching-and-performance.md +102 -0
- package/catalog/frontmcp-production-readiness/examples/common-checklist/observability-setup.md +104 -0
- package/catalog/frontmcp-production-readiness/examples/common-checklist/security-hardening.md +95 -0
- package/catalog/frontmcp-production-readiness/examples/health-readiness-endpoints/basic-health-setup.md +81 -0
- package/catalog/frontmcp-production-readiness/examples/health-readiness-endpoints/custom-probes.md +136 -0
- package/catalog/frontmcp-production-readiness/examples/production-browser/browser-bundle-config.md +93 -0
- package/catalog/frontmcp-production-readiness/examples/production-browser/cross-platform-crypto.md +116 -0
- package/catalog/frontmcp-production-readiness/examples/production-browser/security-and-performance.md +128 -0
- package/catalog/frontmcp-production-readiness/examples/production-cli-binary/binary-build-config.md +109 -0
- package/catalog/frontmcp-production-readiness/examples/production-cli-binary/stdio-transport-error-handling.md +132 -0
- package/catalog/frontmcp-production-readiness/examples/production-cli-daemon/daemon-socket-config.md +82 -0
- package/catalog/frontmcp-production-readiness/examples/production-cli-daemon/graceful-shutdown-cleanup.md +107 -0
- package/catalog/frontmcp-production-readiness/examples/production-cli-daemon/security-and-permissions.md +119 -0
- package/catalog/frontmcp-production-readiness/examples/production-cloudflare/durable-objects-state.md +124 -0
- package/catalog/frontmcp-production-readiness/examples/production-cloudflare/workers-runtime-constraints.md +103 -0
- package/catalog/frontmcp-production-readiness/examples/production-cloudflare/wrangler-config.md +89 -0
- package/catalog/frontmcp-production-readiness/examples/production-lambda/cold-start-connection-reuse.md +122 -0
- package/catalog/frontmcp-production-readiness/examples/production-lambda/sam-template.md +107 -0
- package/catalog/frontmcp-production-readiness/examples/production-lambda/scaling-and-monitoring.md +138 -0
- package/catalog/frontmcp-production-readiness/examples/production-node-sdk/basic-sdk-lifecycle.md +85 -0
- package/catalog/frontmcp-production-readiness/examples/production-node-sdk/multi-instance-cleanup.md +110 -0
- package/catalog/frontmcp-production-readiness/examples/production-node-sdk/package-json-config.md +107 -0
- package/catalog/frontmcp-production-readiness/examples/production-node-server/docker-multi-stage.md +103 -0
- package/catalog/frontmcp-production-readiness/examples/production-node-server/graceful-shutdown.md +87 -0
- package/catalog/frontmcp-production-readiness/examples/production-node-server/redis-session-scaling.md +97 -0
- package/catalog/frontmcp-production-readiness/examples/production-vercel/cold-start-optimization.md +104 -0
- package/catalog/frontmcp-production-readiness/examples/production-vercel/stateless-serverless-design.md +91 -0
- package/catalog/frontmcp-production-readiness/examples/production-vercel/vercel-edge-config.md +78 -0
- package/catalog/frontmcp-production-readiness/references/common-checklist.md +175 -0
- package/catalog/frontmcp-production-readiness/references/health-readiness-endpoints.md +198 -0
- package/catalog/frontmcp-production-readiness/references/production-browser.md +56 -0
- package/catalog/frontmcp-production-readiness/references/production-cli-binary.md +71 -0
- package/catalog/frontmcp-production-readiness/references/production-cli-daemon.md +71 -0
- package/catalog/frontmcp-production-readiness/references/production-cloudflare.md +62 -0
- package/catalog/frontmcp-production-readiness/references/production-lambda.md +63 -0
- package/catalog/frontmcp-production-readiness/references/production-node-sdk.md +76 -0
- package/catalog/frontmcp-production-readiness/references/production-node-server.md +71 -0
- package/catalog/frontmcp-production-readiness/references/production-vercel.md +62 -0
- package/catalog/frontmcp-setup/SKILL.md +19 -14
- package/catalog/frontmcp-setup/examples/frontmcp-skills-usage/bundle-presets-scaffolding.md +61 -0
- package/catalog/frontmcp-setup/examples/frontmcp-skills-usage/install-and-search-skills.md +83 -0
- package/catalog/frontmcp-setup/examples/multi-app-composition/local-apps-with-shared-tools.md +87 -0
- package/catalog/frontmcp-setup/examples/multi-app-composition/per-app-auth-and-isolation.md +88 -0
- package/catalog/frontmcp-setup/examples/multi-app-composition/remote-and-esm-apps.md +81 -0
- package/catalog/frontmcp-setup/examples/nx-workflow/build-test-affected.md +77 -0
- package/catalog/frontmcp-setup/examples/nx-workflow/multi-server-deployment.md +93 -0
- package/catalog/frontmcp-setup/examples/nx-workflow/scaffold-and-generate.md +62 -0
- package/catalog/frontmcp-setup/examples/project-structure-nx/nx-generator-scaffolding.md +73 -0
- package/catalog/frontmcp-setup/examples/project-structure-nx/nx-workspace-with-apps.md +85 -0
- package/catalog/frontmcp-setup/examples/project-structure-nx/shared-library-usage.md +89 -0
- package/catalog/frontmcp-setup/examples/project-structure-standalone/dev-workflow-commands.md +64 -0
- package/catalog/frontmcp-setup/examples/project-structure-standalone/feature-folder-organization.md +111 -0
- package/catalog/frontmcp-setup/examples/project-structure-standalone/minimal-standalone-layout.md +73 -0
- package/catalog/frontmcp-setup/examples/readme-guide/node-server-readme.md +89 -0
- package/catalog/frontmcp-setup/examples/readme-guide/vercel-deployment-readme.md +90 -0
- package/catalog/frontmcp-setup/examples/setup-project/basic-node-server.md +99 -0
- package/catalog/frontmcp-setup/examples/setup-project/cli-scaffold-with-flags.md +77 -0
- package/catalog/frontmcp-setup/examples/setup-project/vercel-serverless-server.md +89 -0
- package/catalog/frontmcp-setup/examples/setup-redis/docker-redis-local-dev.md +88 -0
- package/catalog/frontmcp-setup/examples/setup-redis/hybrid-vercel-kv-with-pubsub.md +78 -0
- package/catalog/frontmcp-setup/examples/setup-redis/vercel-kv-serverless.md +78 -0
- package/catalog/frontmcp-setup/examples/setup-sqlite/basic-sqlite-setup.md +75 -0
- package/catalog/frontmcp-setup/examples/setup-sqlite/encrypted-sqlite-storage.md +55 -0
- package/catalog/frontmcp-setup/examples/setup-sqlite/unix-socket-daemon.md +70 -0
- package/catalog/frontmcp-setup/references/frontmcp-skills-usage.md +33 -9
- package/catalog/frontmcp-setup/references/multi-app-composition.md +15 -0
- package/catalog/frontmcp-setup/references/nx-workflow.md +15 -0
- package/catalog/frontmcp-setup/references/project-structure-nx.md +15 -0
- package/catalog/frontmcp-setup/references/project-structure-standalone.md +15 -0
- package/catalog/frontmcp-setup/references/readme-guide.md +235 -0
- package/catalog/frontmcp-setup/references/setup-project.md +16 -1
- package/catalog/frontmcp-setup/references/setup-redis.md +15 -0
- package/catalog/frontmcp-setup/references/setup-sqlite.md +15 -0
- package/catalog/frontmcp-testing/SKILL.md +41 -27
- package/catalog/frontmcp-testing/examples/setup-testing/fixture-based-e2e-test.md +70 -0
- package/catalog/frontmcp-testing/examples/setup-testing/jest-config-with-coverage.md +59 -0
- package/catalog/frontmcp-testing/examples/setup-testing/unit-test-tool-resource-prompt.md +115 -0
- package/catalog/frontmcp-testing/examples/test-auth/oauth-flow-test.md +78 -0
- package/catalog/frontmcp-testing/examples/test-auth/role-based-access-test.md +88 -0
- package/catalog/frontmcp-testing/examples/test-auth/token-factory-test.md +71 -0
- package/catalog/frontmcp-testing/examples/test-browser-build/browser-bundle-validation.md +58 -0
- package/catalog/frontmcp-testing/examples/test-browser-build/playwright-browser-test.md +69 -0
- package/catalog/frontmcp-testing/examples/test-cli-binary/binary-startup-test.md +77 -0
- package/catalog/frontmcp-testing/examples/test-cli-binary/js-bundle-import-test.md +56 -0
- package/catalog/frontmcp-testing/examples/test-direct-client/basic-create-test.md +74 -0
- package/catalog/frontmcp-testing/examples/test-direct-client/openai-claude-format-test.md +79 -0
- package/catalog/frontmcp-testing/examples/test-e2e-handler/basic-e2e-test.md +67 -0
- package/catalog/frontmcp-testing/examples/test-e2e-handler/manual-client-with-transport.md +72 -0
- package/catalog/frontmcp-testing/examples/test-e2e-handler/tool-call-and-error-e2e.md +73 -0
- package/catalog/frontmcp-testing/examples/test-tool-unit/basic-tool-test.md +69 -0
- package/catalog/frontmcp-testing/examples/test-tool-unit/schema-validation-test.md +82 -0
- package/catalog/frontmcp-testing/examples/test-tool-unit/tool-error-handling-test.md +92 -0
- package/catalog/frontmcp-testing/references/setup-testing.md +17 -0
- package/catalog/frontmcp-testing/references/test-auth.md +15 -0
- package/catalog/frontmcp-testing/references/test-browser-build.md +14 -0
- package/catalog/frontmcp-testing/references/test-cli-binary.md +14 -0
- package/catalog/frontmcp-testing/references/test-direct-client.md +14 -0
- package/catalog/frontmcp-testing/references/test-e2e-handler.md +15 -0
- package/catalog/frontmcp-testing/references/test-tool-unit.md +15 -0
- package/catalog/skills-manifest.json +2849 -32
- package/package.json +2 -2
- package/src/index.d.ts +1 -1
- package/src/index.js.map +1 -1
- package/src/loader.js +0 -1
- package/src/loader.js.map +1 -1
- package/src/manifest.d.ts +36 -1
- package/src/manifest.js +6 -1
- package/src/manifest.js.map +1 -1
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: readme-guide
|
|
3
|
+
description: Generate deployment-target-aware README.md files for FrontMCP MCP servers
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# FrontMCP README Generator
|
|
7
|
+
|
|
8
|
+
Generate deployment-target-aware README.md files for FrontMCP MCP servers. The README adapts its content based on how the project is intended to be consumed — as an npm package, CLI tool, browser SDK, or serverless deployment.
|
|
9
|
+
|
|
10
|
+
## When to Use This Skill
|
|
11
|
+
|
|
12
|
+
### Must Use
|
|
13
|
+
|
|
14
|
+
- Creating a new FrontMCP project that will be published or shared
|
|
15
|
+
- Preparing an open-source release of an MCP server
|
|
16
|
+
- Updating README after adding tools, prompts, resources, or changing deployment targets
|
|
17
|
+
|
|
18
|
+
### Recommended
|
|
19
|
+
|
|
20
|
+
- After significant changes to tools, resources, or server configuration
|
|
21
|
+
- When switching deployment targets (e.g., from Node to Vercel)
|
|
22
|
+
- Before publishing a new version to npm
|
|
23
|
+
|
|
24
|
+
### Skip When
|
|
25
|
+
|
|
26
|
+
- Internal project with no external users
|
|
27
|
+
- The README is already comprehensive and manually maintained
|
|
28
|
+
|
|
29
|
+
> **Decision:** Use this skill whenever the project's README needs to reflect its current tools, capabilities, and deployment instructions. Always ask the user which deployment target they're publishing for.
|
|
30
|
+
|
|
31
|
+
## Step 1: Determine the Deployment Target
|
|
32
|
+
|
|
33
|
+
Ask the user how the project will be consumed. This determines the README structure:
|
|
34
|
+
|
|
35
|
+
| Target | README Focus |
|
|
36
|
+
| ------------------------------- | -------------------------------------------------------------- |
|
|
37
|
+
| **npm package** (direct client) | Installation via npm, SDK usage, `create()` API examples |
|
|
38
|
+
| **CLI binary** | Global install, CLI commands, configuration, usage examples |
|
|
39
|
+
| **Browser SDK** | CDN/bundler import, browser-compatible API, framework examples |
|
|
40
|
+
| **Node server** (Docker) | Docker setup, environment variables, health checks, deployment |
|
|
41
|
+
| **Vercel** | One-click deploy, `vercel.json` config, environment setup |
|
|
42
|
+
| **Lambda** | SAM template, deployment commands, API Gateway config |
|
|
43
|
+
| **Cloudflare Workers** | `wrangler.toml` config, deploy commands, edge runtime notes |
|
|
44
|
+
|
|
45
|
+
## Step 2: Gather Project Information
|
|
46
|
+
|
|
47
|
+
Read these files to understand the project:
|
|
48
|
+
|
|
49
|
+
1. **`src/main.ts`** — Server name, version, registered apps
|
|
50
|
+
2. **`src/**/\*.app.ts`\*\* — App names and their tools/resources/prompts
|
|
51
|
+
3. **`src/tools/*.tool.ts`** — Tool names, descriptions, input/output schemas
|
|
52
|
+
4. **`src/resources/*.resource.ts`** — Resource URIs and descriptions
|
|
53
|
+
5. **`package.json`** — Name, version, scripts, dependencies
|
|
54
|
+
6. **`.env.example`** — Required environment variables
|
|
55
|
+
7. **`ci/`** — Dockerfile, docker-compose.yml if present
|
|
56
|
+
|
|
57
|
+
## Step 3: Generate README Sections
|
|
58
|
+
|
|
59
|
+
### Common Sections (all targets)
|
|
60
|
+
|
|
61
|
+
```markdown
|
|
62
|
+
# {Project Name}
|
|
63
|
+
|
|
64
|
+
{One-line description from @FrontMcp info}
|
|
65
|
+
|
|
66
|
+
## Features
|
|
67
|
+
|
|
68
|
+
- {Tool 1 name} — {description}
|
|
69
|
+
- {Tool 2 name} — {description}
|
|
70
|
+
- {Resource 1} — {description}
|
|
71
|
+
|
|
72
|
+
## Quick Start
|
|
73
|
+
|
|
74
|
+
{Target-specific install + run instructions}
|
|
75
|
+
|
|
76
|
+
## Tools
|
|
77
|
+
|
|
78
|
+
| Tool | Description | Input |
|
|
79
|
+
| -------- | ------------- | ------------------------ |
|
|
80
|
+
| `{name}` | {description} | `{input schema summary}` |
|
|
81
|
+
|
|
82
|
+
## Resources
|
|
83
|
+
|
|
84
|
+
| URI | Description |
|
|
85
|
+
| ------------------- | ------------- |
|
|
86
|
+
| `{uri or template}` | {description} |
|
|
87
|
+
|
|
88
|
+
## Environment Variables
|
|
89
|
+
|
|
90
|
+
| Variable | Required | Description |
|
|
91
|
+
| -------- | -------- | ------------- |
|
|
92
|
+
| `{VAR}` | {yes/no} | {description} |
|
|
93
|
+
|
|
94
|
+
## Development
|
|
95
|
+
|
|
96
|
+
{How to run locally, test, inspect}
|
|
97
|
+
|
|
98
|
+
## License
|
|
99
|
+
|
|
100
|
+
{License from package.json}
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
### Target-Specific Sections
|
|
104
|
+
|
|
105
|
+
**npm package (direct client):**
|
|
106
|
+
|
|
107
|
+
```markdown
|
|
108
|
+
## Installation
|
|
109
|
+
|
|
110
|
+
npm install {package-name}
|
|
111
|
+
|
|
112
|
+
## Usage
|
|
113
|
+
|
|
114
|
+
import { create } from '{package-name}';
|
|
115
|
+
|
|
116
|
+
const server = await create({
|
|
117
|
+
// configuration
|
|
118
|
+
});
|
|
119
|
+
const client = await server.connect();
|
|
120
|
+
const tools = await client.listTools();
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
**CLI binary:**
|
|
124
|
+
|
|
125
|
+
```markdown
|
|
126
|
+
## Installation
|
|
127
|
+
|
|
128
|
+
npm install -g {package-name}
|
|
129
|
+
|
|
130
|
+
## Usage
|
|
131
|
+
|
|
132
|
+
{package-name} --help
|
|
133
|
+
{package-name} [command] [options]
|
|
134
|
+
|
|
135
|
+
## Commands
|
|
136
|
+
|
|
137
|
+
| Command | Description |
|
|
138
|
+
| ------- | ------------- |
|
|
139
|
+
| `{cmd}` | {description} |
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
**Docker / Node server:**
|
|
143
|
+
|
|
144
|
+
```markdown
|
|
145
|
+
## Docker
|
|
146
|
+
|
|
147
|
+
docker compose up
|
|
148
|
+
|
|
149
|
+
## Manual Deployment
|
|
150
|
+
|
|
151
|
+
docker build -f ci/Dockerfile -t {name}:latest .
|
|
152
|
+
docker run -p 3000:3000 {name}:latest
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
**Vercel:**
|
|
156
|
+
|
|
157
|
+
```markdown
|
|
158
|
+
## Deploy to Vercel
|
|
159
|
+
|
|
160
|
+
npm i -g vercel
|
|
161
|
+
frontmcp build --target vercel
|
|
162
|
+
vercel deploy --prebuilt
|
|
163
|
+
|
|
164
|
+
## Configuration
|
|
165
|
+
|
|
166
|
+
See `vercel.json` for route configuration and environment variables.
|
|
167
|
+
Set secrets via: `vercel env add REDIS_URL`
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
**AWS Lambda:**
|
|
171
|
+
|
|
172
|
+
```markdown
|
|
173
|
+
## Deploy to AWS Lambda
|
|
174
|
+
|
|
175
|
+
frontmcp build --target lambda
|
|
176
|
+
cd dist && sam build && sam deploy --guided
|
|
177
|
+
|
|
178
|
+
## Configuration
|
|
179
|
+
|
|
180
|
+
- SAM template: `template.yaml` defines the Lambda function, API Gateway, and DynamoDB table
|
|
181
|
+
- Environment variables: Set via `sam deploy` parameters or AWS Console
|
|
182
|
+
- API Gateway: Streamable HTTP endpoint at `https://{api-id}.execute-api.{region}.amazonaws.com/mcp`
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
**Cloudflare Workers:**
|
|
186
|
+
|
|
187
|
+
```markdown
|
|
188
|
+
## Deploy to Cloudflare Workers
|
|
189
|
+
|
|
190
|
+
frontmcp build --target cloudflare
|
|
191
|
+
npx wrangler deploy
|
|
192
|
+
|
|
193
|
+
## Configuration
|
|
194
|
+
|
|
195
|
+
- Workers config: `wrangler.toml` defines the worker name, routes, and KV bindings
|
|
196
|
+
- Secrets: `npx wrangler secret put REDIS_URL`
|
|
197
|
+
- KV namespace: Create via `npx wrangler kv:namespace create SESSION_STORE`
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
## Step 4: Update Existing README
|
|
201
|
+
|
|
202
|
+
When updating (not creating), preserve:
|
|
203
|
+
|
|
204
|
+
- Custom sections the user added manually
|
|
205
|
+
- Badges, logos, and branding
|
|
206
|
+
- Contributing guidelines, code of conduct links
|
|
207
|
+
|
|
208
|
+
Only update:
|
|
209
|
+
|
|
210
|
+
- Tool/resource tables (regenerate from source)
|
|
211
|
+
- Quick start instructions (if deployment target changed)
|
|
212
|
+
- Environment variables (if .env.example changed)
|
|
213
|
+
|
|
214
|
+
## Verification Checklist
|
|
215
|
+
|
|
216
|
+
- [ ] README includes all tools with descriptions from source code
|
|
217
|
+
- [ ] README includes all resources and their URIs
|
|
218
|
+
- [ ] Installation instructions match the deployment target
|
|
219
|
+
- [ ] Environment variables match `.env.example`
|
|
220
|
+
- [ ] Development section includes `frontmcp dev`, `frontmcp test`, `frontmcp inspect`
|
|
221
|
+
- [ ] License matches `package.json`
|
|
222
|
+
|
|
223
|
+
## Examples
|
|
224
|
+
|
|
225
|
+
| Example | Level | Description |
|
|
226
|
+
| ---------------------------------------------------------------------------------- | ------------ | ------------------------------------------------------------------------------------------------------ |
|
|
227
|
+
| [`node-server-readme`](../examples/readme-guide/node-server-readme.md) | Basic | Generate a README for a FrontMCP server deployed as a Docker/Node.js service with tools and resources. |
|
|
228
|
+
| [`vercel-deployment-readme`](../examples/readme-guide/vercel-deployment-readme.md) | Intermediate | Generate a README for a FrontMCP server deployed to Vercel with Vercel KV storage. |
|
|
229
|
+
|
|
230
|
+
> See all examples in [`examples/readme-guide/`](../examples/readme-guide/)
|
|
231
|
+
|
|
232
|
+
## Reference
|
|
233
|
+
|
|
234
|
+
- Related skills: `frontmcp-deployment` (for target-specific deployment details)
|
|
235
|
+
- Related skills: `frontmcp-setup` (for project structure)
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: setup-project
|
|
3
|
+
description: Scaffold a new FrontMCP project with CLI or manual setup, decorators, apps, and deployment config
|
|
4
|
+
---
|
|
5
|
+
|
|
1
6
|
# Scaffold and Configure a New FrontMCP Project
|
|
2
7
|
|
|
3
8
|
## When to Use This Skill
|
|
@@ -159,7 +164,7 @@ import { FrontMcp } from '@frontmcp/sdk';
|
|
|
159
164
|
// tools?: ToolType[] - shared tools available to all apps
|
|
160
165
|
// resources?: ResourceType[] - shared resources available to all apps
|
|
161
166
|
// skills?: SkillType[] - shared skills available to all apps
|
|
162
|
-
// skillsConfig?: { enabled: boolean,
|
|
167
|
+
// skillsConfig?: { enabled: boolean, mcpResources?: boolean, cache?: {...}, auth?: 'api-key' | 'bearer' }
|
|
163
168
|
// elicitation?: { enabled: boolean }
|
|
164
169
|
// pubsub?: { provider: 'redis', host: string, ... }
|
|
165
170
|
// pagination?: { ... }
|
|
@@ -487,6 +492,16 @@ Run with: `nx serve <projectName>`.
|
|
|
487
492
|
| Build fails with "Cannot find module '@frontmcp/sdk'" | Dependencies were not installed after scaffolding | Run `yarn install` (or `npm install` / `pnpm install`) in the project root |
|
|
488
493
|
| Vercel deploy returns 500 on `/mcp` endpoint | Transport not set to `modern` or storage not configured for Vercel KV | Set `transport: { protocol: 'modern' }` and `redis: { provider: 'vercel-kv' }` in `@FrontMcp` metadata |
|
|
489
494
|
|
|
495
|
+
## Examples
|
|
496
|
+
|
|
497
|
+
| Example | Level | Description |
|
|
498
|
+
| ----------------------------------------------------------------------------------- | ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
499
|
+
| [`basic-node-server`](../examples/setup-project/basic-node-server.md) | Basic | Scaffold a minimal FrontMCP server with one app and one tool, running on Node.js with HTTP transport. |
|
|
500
|
+
| [`cli-scaffold-with-flags`](../examples/setup-project/cli-scaffold-with-flags.md) | Basic | Use the `frontmcp create` CLI to scaffold a complete project non-interactively with explicit flags for deployment target, Redis, and package manager. |
|
|
501
|
+
| [`vercel-serverless-server`](../examples/setup-project/vercel-serverless-server.md) | Intermediate | Configure a FrontMCP server for Vercel deployment with Vercel KV storage and modern transport protocol. |
|
|
502
|
+
|
|
503
|
+
> See all examples in [`examples/setup-project/`](../examples/setup-project/)
|
|
504
|
+
|
|
490
505
|
## Reference
|
|
491
506
|
|
|
492
507
|
- [Getting Started Quickstart](https://docs.agentfront.dev/frontmcp/getting-started/quickstart)
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: setup-redis
|
|
3
|
+
description: Provision and configure Redis or Vercel KV for session storage and distributed state
|
|
4
|
+
---
|
|
5
|
+
|
|
1
6
|
# Configure Redis for Session Storage and Distributed State
|
|
2
7
|
|
|
3
8
|
## When to Use This Skill
|
|
@@ -352,6 +357,16 @@ You should see session keys like `mcp:session:<session-id>`.
|
|
|
352
357
|
| Vercel KV `401 Unauthorized` | Missing or invalid KV tokens in the environment | Verify `KV_REST_API_URL` and `KV_REST_API_TOKEN` in the Vercel dashboard and redeploy |
|
|
353
358
|
| Sessions lost after container restart | Redis running without append-only persistence | Add `--appendonly yes` to the Redis command in docker-compose or use a managed Redis with persistence enabled |
|
|
354
359
|
|
|
360
|
+
## Examples
|
|
361
|
+
|
|
362
|
+
| Example | Level | Description |
|
|
363
|
+
| ----------------------------------------------------------------------------------------- | ------------ | --------------------------------------------------------------------------------------------------- |
|
|
364
|
+
| [`docker-redis-local-dev`](../examples/setup-redis/docker-redis-local-dev.md) | Basic | Provision Redis with Docker Compose and connect a FrontMCP server for local session storage. |
|
|
365
|
+
| [`hybrid-vercel-kv-with-pubsub`](../examples/setup-redis/hybrid-vercel-kv-with-pubsub.md) | Advanced | Use Vercel KV for session storage and a separate Redis instance for pub/sub resource subscriptions. |
|
|
366
|
+
| [`vercel-kv-serverless`](../examples/setup-redis/vercel-kv-serverless.md) | Intermediate | Configure a FrontMCP server with Vercel KV as the session store for serverless deployment. |
|
|
367
|
+
|
|
368
|
+
> See all examples in [`examples/setup-redis/`](../examples/setup-redis/)
|
|
369
|
+
|
|
355
370
|
## Reference
|
|
356
371
|
|
|
357
372
|
- [Redis Setup Docs](https://docs.agentfront.dev/frontmcp/deployment/redis-setup)
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: setup-sqlite
|
|
3
|
+
description: Configure SQLite with WAL mode and optional encryption for local single-instance deployments
|
|
4
|
+
---
|
|
5
|
+
|
|
1
6
|
# Configure SQLite for Local and Single-Instance Deployments
|
|
2
7
|
|
|
3
8
|
## When to Use This Skill
|
|
@@ -341,6 +346,16 @@ The change in `src/main.ts`:
|
|
|
341
346
|
| WAL errors on network mount | WAL mode requires a local filesystem with shared-memory support | Move the database to a local disk or set `walMode: false` |
|
|
342
347
|
| Encrypted data unreadable after restart | Encryption secret changed or missing | The secret must be identical across restarts; if the original secret is lost, delete the database and let it be recreated |
|
|
343
348
|
|
|
349
|
+
## Examples
|
|
350
|
+
|
|
351
|
+
| Example | Level | Description |
|
|
352
|
+
| ---------------------------------------------------------------------------------- | ------------ | ------------------------------------------------------------------------------------------------- |
|
|
353
|
+
| [`basic-sqlite-setup`](../examples/setup-sqlite/basic-sqlite-setup.md) | Basic | Configure a FrontMCP server with SQLite for local session storage with WAL mode enabled. |
|
|
354
|
+
| [`encrypted-sqlite-storage`](../examples/setup-sqlite/encrypted-sqlite-storage.md) | Intermediate | Enable AES-256-GCM at-rest encryption for sensitive session data stored in SQLite. |
|
|
355
|
+
| [`unix-socket-daemon`](../examples/setup-sqlite/unix-socket-daemon.md) | Advanced | Configure a FrontMCP daemon that listens on a unix socket and uses SQLite for persistent storage. |
|
|
356
|
+
|
|
357
|
+
> See all examples in [`examples/setup-sqlite/`](../examples/setup-sqlite/)
|
|
358
|
+
|
|
344
359
|
## Reference
|
|
345
360
|
|
|
346
361
|
- **Docs:** [SQLite Setup Guide](https://docs.agentfront.dev/frontmcp/deployment/sqlite-setup)
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: frontmcp-testing
|
|
3
|
-
description:
|
|
3
|
+
description: 'Use when you want to write tests, run tests, add e2e tests, improve test coverage, test a tool, test a resource, or learn how to test any FrontMCP component. The skill for ALL testing needs.'
|
|
4
4
|
tags: [router, testing, jest, e2e, coverage, quality, guide]
|
|
5
|
+
category: testing
|
|
6
|
+
targets: [all]
|
|
7
|
+
bundle: [recommended, full]
|
|
5
8
|
priority: 10
|
|
6
9
|
visibility: both
|
|
7
10
|
license: Apache-2.0
|
|
@@ -37,37 +40,48 @@ Entry point for testing FrontMCP applications. This skill helps you navigate tes
|
|
|
37
40
|
|
|
38
41
|
## Scenario Routing Table
|
|
39
42
|
|
|
40
|
-
| Scenario | Skill / Section
|
|
41
|
-
| --------------------------------------- |
|
|
42
|
-
| Set up Jest, coverage, and test harness | `setup-testing`
|
|
43
|
-
| Write unit tests for a tool | `setup-testing` (Unit Testing)
|
|
44
|
-
| Write unit tests for a resource | `setup-testing` (Unit Testing)
|
|
45
|
-
| Write unit tests for a prompt | `setup-testing` (Unit Testing)
|
|
46
|
-
| Write E2E protocol-level tests | `setup-testing` (E2E Testing)
|
|
47
|
-
| Test authenticated endpoints | `
|
|
48
|
-
| Test deployment builds | `setup-testing` + `deploy-to-*`
|
|
43
|
+
| Scenario | Skill / Section | Description |
|
|
44
|
+
| --------------------------------------- | ------------------------------- | ------------------------------------------------------------ |
|
|
45
|
+
| Set up Jest, coverage, and test harness | `setup-testing` | Full Jest config, test utilities, and coverage thresholds |
|
|
46
|
+
| Write unit tests for a tool | `setup-testing` (Unit Testing) | Mock DI, validate input/output, test error paths |
|
|
47
|
+
| Write unit tests for a resource | `setup-testing` (Unit Testing) | Test URI resolution, template params, read results |
|
|
48
|
+
| Write unit tests for a prompt | `setup-testing` (Unit Testing) | Test argument handling, message generation |
|
|
49
|
+
| Write E2E protocol-level tests | `setup-testing` (E2E Testing) | Real MCP client/server, full protocol flow |
|
|
50
|
+
| Test authenticated endpoints | `test-auth` | E2E with OAuth tokens, session validation, role-based access |
|
|
51
|
+
| Test deployment builds | `setup-testing` + `deploy-to-*` | Smoke tests against built output |
|
|
52
|
+
| Test browser builds | `test-browser-build` | Testing browser builds |
|
|
53
|
+
| Test CLI binary builds | `test-cli-binary` | Testing CLI binary builds |
|
|
54
|
+
| Test with the direct API client | `test-direct-client` | Testing with the direct API client |
|
|
55
|
+
| Write E2E test handler patterns | `test-e2e-handler` | E2E test handler patterns |
|
|
56
|
+
| Unit test individual tools | `test-tool-unit` | Unit testing individual tools |
|
|
49
57
|
|
|
50
58
|
## Testing Strategy by Component Type
|
|
51
59
|
|
|
52
|
-
| Component | Unit Test Focus | E2E Test Focus | Key Assertions
|
|
53
|
-
| --------- | -------------------------------------------------------- | ---------------------------------- |
|
|
54
|
-
| Tool | Input validation, execute logic, error paths, DI mocking | `tools/call` via MCP client | Output matches schema, errors return MCP codes
|
|
55
|
-
| Resource | URI resolution, read content, template param handling | `resources/read` via MCP client | Content type correct, URI patterns resolve
|
|
56
|
-
| Prompt | Argument validation, message generation, multi-turn | `prompts/get` via MCP client | Messages match expected structure
|
|
57
|
-
| Agent | LLM config, tool selection, handoff logic | Agent loop via MCP client | Tools called in order, result synthesized
|
|
58
|
-
| Provider | Lifecycle hooks, factory output, singleton behavior | Indirectly via tool/resource tests | Instance reuse, cleanup on scope disposal
|
|
59
|
-
| Job | Progress tracking, retry logic, attempt counting | Job execution via test harness | Progress events emitted, retries respected
|
|
60
|
+
| Component | Unit Test Focus | E2E Test Focus | Key Assertions |
|
|
61
|
+
| --------- | -------------------------------------------------------- | ---------------------------------- | ----------------------------------------------------------------------- |
|
|
62
|
+
| Tool | Input validation, execute logic, error paths, DI mocking | `tools/call` via MCP client | Output matches schema, errors return MCP codes |
|
|
63
|
+
| Resource | URI resolution, read content, template param handling | `resources/read` via MCP client | Content type correct, URI patterns resolve |
|
|
64
|
+
| Prompt | Argument validation, message generation, multi-turn | `prompts/get` via MCP client | Messages match expected structure |
|
|
65
|
+
| Agent | LLM config, tool selection, handoff logic | Agent loop via MCP client | Tools called in order, result synthesized |
|
|
66
|
+
| Provider | Lifecycle hooks, factory output, singleton behavior | Indirectly via tool/resource tests | Instance reuse, cleanup on scope disposal |
|
|
67
|
+
| Job | Progress tracking, retry logic, attempt counting | Job execution via test harness | Progress events emitted, retries respected |
|
|
68
|
+
| Workflow | Step dependencies, conditions, input mapping functions | Workflow run via test harness | Steps execute in order, conditions evaluated, continueOnError respected |
|
|
69
|
+
| Skill | Instruction loading (inline/file/url), tool validation | Skill discovery via MCP/HTTP | Instructions resolve, tool refs validated per `toolValidation` mode |
|
|
70
|
+
| Plugin | Context extensions, provider registration, hook firing | Indirectly via tool tests | Extensions available on `this`, hooks fire at correct stages |
|
|
60
71
|
|
|
61
72
|
## Cross-Cutting Testing Patterns
|
|
62
73
|
|
|
63
|
-
| Pattern | Rule
|
|
64
|
-
| ------------------ |
|
|
65
|
-
| File naming | Always `.spec.ts` (not `.test.ts`); E2E uses `.e2e.spec.ts`
|
|
66
|
-
|
|
|
67
|
-
| Test
|
|
68
|
-
|
|
|
69
|
-
|
|
|
70
|
-
|
|
|
74
|
+
| Pattern | Rule |
|
|
75
|
+
| ------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
76
|
+
| File naming | Always `.spec.ts` (not `.test.ts`); E2E uses `.e2e.spec.ts` |
|
|
77
|
+
| File organization | Split E2E tests by app/feature: `e2e/calc.e2e.spec.ts`, `e2e/ecommerce.e2e.spec.ts`. Never put all tests in a single `server.e2e.spec.ts` |
|
|
78
|
+
| Test runner | Use `frontmcp test` (not `jest --config ...`). It auto-generates the correct Jest/SWC config |
|
|
79
|
+
| Coverage threshold | 95%+ across statements, branches, functions, lines |
|
|
80
|
+
| Test descriptions | Plain English, no prefixes like "PT-001"; describe behavior not implementation |
|
|
81
|
+
| Mocking | Mock providers via DI token replacement, never mock the framework |
|
|
82
|
+
| httpMock scope | `httpMock` intercepts HTTP in the **test process** only, NOT in the MCP server subprocess. Do not use httpMock to intercept server-to-API calls — those happen in the child process. Use httpMock for verifying client-to-server request shapes or mocking external APIs called from the test itself |
|
|
83
|
+
| Error testing | Assert `instanceof` specific error class AND MCP error code |
|
|
84
|
+
| Async | Always `await` async operations; use `expect(...).rejects.toThrow()` for async errors |
|
|
71
85
|
|
|
72
86
|
## Common Patterns
|
|
73
87
|
|
|
@@ -110,7 +124,7 @@ Entry point for testing FrontMCP applications. This skill helps you navigate tes
|
|
|
110
124
|
| Problem | Cause | Solution |
|
|
111
125
|
| ---------------------------------- | ------------------------------------------------------- | -------------------------------------------------------------------------------------- |
|
|
112
126
|
| Jest not finding test files | Wrong file extension (`.test.ts` instead of `.spec.ts`) | Rename to `.spec.ts`; check `testMatch` in jest.config |
|
|
113
|
-
| Coverage below 95% | Untested error paths or conditional branches | Run `
|
|
127
|
+
| Coverage below 95% | Untested error paths or conditional branches | Run `frontmcp test --coverage` and inspect uncovered lines in the report |
|
|
114
128
|
| E2E test timeout | Server startup too slow or port conflict | Increase Jest timeout; use random port allocation |
|
|
115
129
|
| DI resolution fails in tests | Provider not registered in test scope | Register mock providers before creating the test context |
|
|
116
130
|
| Istanbul shows 0% on async methods | TypeScript source-map mismatch with Istanbul | Known issue with some TS compilation settings; verify coverage with actual test output |
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: fixture-based-e2e-test
|
|
3
|
+
reference: setup-testing
|
|
4
|
+
level: advanced
|
|
5
|
+
description: 'Write E2E tests using the fixture API from `@frontmcp/testing` that manages server lifecycle automatically and uses MCP-specific custom matchers.'
|
|
6
|
+
tags: [testing, jest, e2e, setup, fixture, based]
|
|
7
|
+
features:
|
|
8
|
+
- 'Using `test.use()` to configure server path and port for automatic lifecycle management'
|
|
9
|
+
- 'Importing `test` and `expect` from `@frontmcp/testing` (not from Jest) to access MCP-specific matchers'
|
|
10
|
+
- 'Custom matchers: `toContainTool()`, `toBeSuccessful()`, `toHaveTextContent()` for MCP assertions'
|
|
11
|
+
- 'Testing all three MCP primitives (tools, resources, prompts) in a single E2E suite'
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
# Fixture-Based E2E Test with Custom Matchers
|
|
15
|
+
|
|
16
|
+
Write E2E tests using the fixture API from `@frontmcp/testing` that manages server lifecycle automatically and uses MCP-specific custom matchers.
|
|
17
|
+
|
|
18
|
+
## Code
|
|
19
|
+
|
|
20
|
+
```typescript
|
|
21
|
+
// my-server.e2e.spec.ts
|
|
22
|
+
import { test, expect } from '@frontmcp/testing';
|
|
23
|
+
|
|
24
|
+
test.use({
|
|
25
|
+
server: './src/main.ts',
|
|
26
|
+
port: 3003,
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
test('server exposes expected tools', async ({ mcp }) => {
|
|
30
|
+
const tools = await mcp.tools.list();
|
|
31
|
+
expect(tools).toContainTool('create_record');
|
|
32
|
+
expect(tools).toContainTool('delete_record');
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
test('create_record tool returns success', async ({ mcp }) => {
|
|
36
|
+
const result = await mcp.tools.call('create_record', {
|
|
37
|
+
name: 'Test Record',
|
|
38
|
+
type: 'example',
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
expect(result).toBeSuccessful();
|
|
42
|
+
expect(result).toHaveTextContent('created');
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
test('reading a resource returns valid content', async ({ mcp }) => {
|
|
46
|
+
const result = await mcp.resources.read('config://server-info');
|
|
47
|
+
|
|
48
|
+
expect(result.contents).toHaveLength(1);
|
|
49
|
+
expect(result.contents[0]).toHaveProperty('mimeType', 'application/json');
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
test('prompts return well-formed messages', async ({ mcp }) => {
|
|
53
|
+
const result = await mcp.prompts.get('summarize', { topic: 'testing' });
|
|
54
|
+
|
|
55
|
+
expect(result.messages).toBeDefined();
|
|
56
|
+
expect(result.messages.length).toBeGreaterThan(0);
|
|
57
|
+
});
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## What This Demonstrates
|
|
61
|
+
|
|
62
|
+
- Using `test.use()` to configure server path and port for automatic lifecycle management
|
|
63
|
+
- Importing `test` and `expect` from `@frontmcp/testing` (not from Jest) to access MCP-specific matchers
|
|
64
|
+
- Custom matchers: `toContainTool()`, `toBeSuccessful()`, `toHaveTextContent()` for MCP assertions
|
|
65
|
+
- Testing all three MCP primitives (tools, resources, prompts) in a single E2E suite
|
|
66
|
+
|
|
67
|
+
## Related
|
|
68
|
+
|
|
69
|
+
- See `setup-testing` for the full testing setup reference
|
|
70
|
+
- See `test-e2e-handler` for manual `McpTestClient` E2E patterns
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: jest-config-with-coverage
|
|
3
|
+
reference: setup-testing
|
|
4
|
+
level: basic
|
|
5
|
+
description: 'Set up a Jest configuration file that enforces 95%+ coverage across all metrics for a FrontMCP library.'
|
|
6
|
+
tags: [testing, jest, setup, config, coverage]
|
|
7
|
+
features:
|
|
8
|
+
- 'How to configure Jest with `ts-jest` for TypeScript test files'
|
|
9
|
+
- 'Setting 95%+ coverage thresholds required by FrontMCP standards'
|
|
10
|
+
- 'Proper `tsconfig.spec.json` that extends the base config and includes `.spec.ts` files'
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
# Jest Configuration with Coverage Thresholds
|
|
14
|
+
|
|
15
|
+
Set up a Jest configuration file that enforces 95%+ coverage across all metrics for a FrontMCP library.
|
|
16
|
+
|
|
17
|
+
## Code
|
|
18
|
+
|
|
19
|
+
```typescript
|
|
20
|
+
// jest.config.ts
|
|
21
|
+
export default {
|
|
22
|
+
displayName: 'my-lib',
|
|
23
|
+
preset: '../../jest.preset.js',
|
|
24
|
+
transform: {
|
|
25
|
+
'^.+\\.tsx?$': ['ts-jest', { tsconfig: '<rootDir>/tsconfig.spec.json' }],
|
|
26
|
+
},
|
|
27
|
+
coverageThreshold: {
|
|
28
|
+
global: {
|
|
29
|
+
statements: 95,
|
|
30
|
+
branches: 95,
|
|
31
|
+
functions: 95,
|
|
32
|
+
lines: 95,
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
};
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
```json
|
|
39
|
+
// tsconfig.spec.json
|
|
40
|
+
{
|
|
41
|
+
"extends": "./tsconfig.json",
|
|
42
|
+
"compilerOptions": {
|
|
43
|
+
"outDir": "../../dist/out-tsc",
|
|
44
|
+
"module": "commonjs",
|
|
45
|
+
"types": ["jest", "node"]
|
|
46
|
+
},
|
|
47
|
+
"include": ["jest.config.ts", "src/**/*.spec.ts", "src/**/*.spec.tsx"]
|
|
48
|
+
}
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## What This Demonstrates
|
|
52
|
+
|
|
53
|
+
- How to configure Jest with `ts-jest` for TypeScript test files
|
|
54
|
+
- Setting 95%+ coverage thresholds required by FrontMCP standards
|
|
55
|
+
- Proper `tsconfig.spec.json` that extends the base config and includes `.spec.ts` files
|
|
56
|
+
|
|
57
|
+
## Related
|
|
58
|
+
|
|
59
|
+
- See `setup-testing` for the full testing setup reference
|