@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.
Files changed (284) hide show
  1. package/README.md +2 -2
  2. package/catalog/TEMPLATE.md +69 -0
  3. package/catalog/frontmcp-config/SKILL.md +38 -22
  4. package/catalog/frontmcp-config/examples/configure-auth/multi-app-auth.md +87 -0
  5. package/catalog/frontmcp-config/examples/configure-auth/public-mode-setup.md +63 -0
  6. package/catalog/frontmcp-config/examples/configure-auth/remote-oauth-with-vault.md +76 -0
  7. package/catalog/frontmcp-config/examples/configure-auth-modes/local-self-signed-tokens.md +77 -0
  8. package/catalog/frontmcp-config/examples/configure-auth-modes/remote-enterprise-oauth.md +73 -0
  9. package/catalog/frontmcp-config/examples/configure-auth-modes/transparent-jwt-validation.md +64 -0
  10. package/catalog/frontmcp-config/examples/configure-elicitation/basic-confirmation-gate.md +83 -0
  11. package/catalog/frontmcp-config/examples/configure-elicitation/distributed-elicitation-redis.md +87 -0
  12. package/catalog/frontmcp-config/examples/configure-http/cors-restricted-origins.md +52 -0
  13. package/catalog/frontmcp-config/examples/configure-http/entry-path-reverse-proxy.md +72 -0
  14. package/catalog/frontmcp-config/examples/configure-http/unix-socket-local.md +64 -0
  15. package/catalog/frontmcp-config/examples/configure-session/multi-server-key-prefix.md +68 -0
  16. package/catalog/frontmcp-config/examples/configure-session/redis-session-store.md +52 -0
  17. package/catalog/frontmcp-config/examples/configure-session/vercel-kv-session.md +52 -0
  18. package/catalog/frontmcp-config/examples/configure-throttle/distributed-redis-throttle.md +94 -0
  19. package/catalog/frontmcp-config/examples/configure-throttle/per-tool-rate-limit.md +92 -0
  20. package/catalog/frontmcp-config/examples/configure-throttle/server-level-rate-limit.md +83 -0
  21. package/catalog/frontmcp-config/examples/configure-throttle-guard-config/full-guard-config.md +99 -0
  22. package/catalog/frontmcp-config/examples/configure-throttle-guard-config/minimal-guard-config.md +55 -0
  23. package/catalog/frontmcp-config/examples/configure-transport/custom-protocol-flags.md +74 -0
  24. package/catalog/frontmcp-config/examples/configure-transport/distributed-sessions-redis.md +86 -0
  25. package/catalog/frontmcp-config/examples/configure-transport/stateless-serverless.md +69 -0
  26. package/catalog/frontmcp-config/examples/configure-transport-protocol-presets/legacy-preset-nodejs.md +65 -0
  27. package/catalog/frontmcp-config/examples/configure-transport-protocol-presets/stateless-api-serverless.md +69 -0
  28. package/catalog/frontmcp-config/references/configure-auth-modes.md +15 -0
  29. package/catalog/frontmcp-config/references/configure-auth.md +15 -0
  30. package/catalog/frontmcp-config/references/configure-elicitation.md +14 -0
  31. package/catalog/frontmcp-config/references/configure-http.md +15 -0
  32. package/catalog/frontmcp-config/references/configure-session.md +15 -0
  33. package/catalog/frontmcp-config/references/configure-throttle-guard-config.md +14 -0
  34. package/catalog/frontmcp-config/references/configure-throttle.md +15 -0
  35. package/catalog/frontmcp-config/references/configure-transport-protocol-presets.md +14 -0
  36. package/catalog/frontmcp-config/references/configure-transport.md +15 -0
  37. package/catalog/frontmcp-config/references/setup-redis.md +10 -0
  38. package/catalog/frontmcp-config/references/setup-sqlite.md +10 -0
  39. package/catalog/frontmcp-deployment/SKILL.md +40 -12
  40. package/catalog/frontmcp-deployment/examples/build-for-browser/browser-build-with-custom-entry.md +43 -0
  41. package/catalog/frontmcp-deployment/examples/build-for-browser/browser-crypto-and-storage.md +85 -0
  42. package/catalog/frontmcp-deployment/examples/build-for-browser/react-provider-setup.md +61 -0
  43. package/catalog/frontmcp-deployment/examples/build-for-cli/cli-binary-build.md +66 -0
  44. package/catalog/frontmcp-deployment/examples/build-for-cli/unix-socket-daemon.md +76 -0
  45. package/catalog/frontmcp-deployment/examples/build-for-sdk/connect-openai.md +78 -0
  46. package/catalog/frontmcp-deployment/examples/build-for-sdk/create-flat-config.md +85 -0
  47. package/catalog/frontmcp-deployment/examples/build-for-sdk/multi-platform-connect.md +104 -0
  48. package/catalog/frontmcp-deployment/examples/deploy-to-cloudflare/basic-worker-deploy.md +82 -0
  49. package/catalog/frontmcp-deployment/examples/deploy-to-cloudflare/worker-custom-domain.md +97 -0
  50. package/catalog/frontmcp-deployment/examples/deploy-to-cloudflare/worker-with-kv-storage.md +92 -0
  51. package/catalog/frontmcp-deployment/examples/deploy-to-lambda/cdk-deployment.md +92 -0
  52. package/catalog/frontmcp-deployment/examples/deploy-to-lambda/lambda-handler-with-cors.md +113 -0
  53. package/catalog/frontmcp-deployment/examples/deploy-to-lambda/sam-template-basic.md +100 -0
  54. package/catalog/frontmcp-deployment/examples/deploy-to-node/docker-compose-with-redis.md +101 -0
  55. package/catalog/frontmcp-deployment/examples/deploy-to-node/pm2-with-nginx.md +79 -0
  56. package/catalog/frontmcp-deployment/examples/deploy-to-node/resource-limits.md +92 -0
  57. package/catalog/frontmcp-deployment/examples/deploy-to-node-dockerfile/basic-multistage-dockerfile.md +63 -0
  58. package/catalog/frontmcp-deployment/examples/deploy-to-node-dockerfile/secure-nonroot-dockerfile.md +89 -0
  59. package/catalog/frontmcp-deployment/examples/deploy-to-vercel/vercel-mcp-endpoint-test.md +69 -0
  60. package/catalog/frontmcp-deployment/examples/deploy-to-vercel/vercel-with-kv.md +82 -0
  61. package/catalog/frontmcp-deployment/examples/deploy-to-vercel/vercel-with-skills-cache.md +90 -0
  62. package/catalog/frontmcp-deployment/examples/deploy-to-vercel-config/minimal-vercel-config.md +49 -0
  63. package/catalog/frontmcp-deployment/examples/deploy-to-vercel-config/vercel-config-with-security-headers.md +92 -0
  64. package/catalog/frontmcp-deployment/references/build-for-browser.md +15 -0
  65. package/catalog/frontmcp-deployment/references/build-for-cli.md +65 -3
  66. package/catalog/frontmcp-deployment/references/build-for-sdk.md +15 -0
  67. package/catalog/frontmcp-deployment/references/deploy-to-cloudflare.md +15 -0
  68. package/catalog/frontmcp-deployment/references/deploy-to-lambda.md +18 -3
  69. package/catalog/frontmcp-deployment/references/deploy-to-node-dockerfile.md +16 -2
  70. package/catalog/frontmcp-deployment/references/deploy-to-node.md +19 -4
  71. package/catalog/frontmcp-deployment/references/deploy-to-vercel-config.md +14 -0
  72. package/catalog/frontmcp-deployment/references/deploy-to-vercel.md +15 -0
  73. package/catalog/frontmcp-development/SKILL.md +25 -17
  74. package/catalog/frontmcp-development/examples/create-adapter/basic-api-adapter.md +92 -0
  75. package/catalog/frontmcp-development/examples/create-adapter/namespaced-adapter.md +124 -0
  76. package/catalog/frontmcp-development/examples/create-agent/basic-agent-with-tools.md +121 -0
  77. package/catalog/frontmcp-development/examples/create-agent/custom-multi-pass-agent.md +95 -0
  78. package/catalog/frontmcp-development/examples/create-agent/nested-agents-with-swarm.md +111 -0
  79. package/catalog/frontmcp-development/examples/create-agent-llm-config/anthropic-config.md +81 -0
  80. package/catalog/frontmcp-development/examples/create-agent-llm-config/openai-config.md +80 -0
  81. package/catalog/frontmcp-development/examples/create-job/basic-report-job.md +87 -0
  82. package/catalog/frontmcp-development/examples/create-job/job-with-permissions.md +117 -0
  83. package/catalog/frontmcp-development/examples/create-job/job-with-retry.md +88 -0
  84. package/catalog/frontmcp-development/examples/create-plugin/basic-plugin-with-provider.md +69 -0
  85. package/catalog/frontmcp-development/examples/create-plugin/configurable-dynamic-plugin.md +178 -0
  86. package/catalog/frontmcp-development/examples/create-plugin/plugin-with-context-extension.md +107 -0
  87. package/catalog/frontmcp-development/examples/create-plugin-hooks/basic-logging-plugin.md +69 -0
  88. package/catalog/frontmcp-development/examples/create-plugin-hooks/caching-with-around.md +80 -0
  89. package/catalog/frontmcp-development/examples/create-plugin-hooks/tool-level-hooks-and-stage-replacement.md +100 -0
  90. package/catalog/frontmcp-development/examples/create-prompt/basic-prompt.md +72 -0
  91. package/catalog/frontmcp-development/examples/create-prompt/dynamic-rag-prompt.md +92 -0
  92. package/catalog/frontmcp-development/examples/create-prompt/multi-turn-debug-session.md +86 -0
  93. package/catalog/frontmcp-development/examples/create-provider/basic-database-provider.md +113 -0
  94. package/catalog/frontmcp-development/examples/create-provider/config-and-api-providers.md +107 -0
  95. package/catalog/frontmcp-development/examples/create-resource/basic-static-resource.md +72 -0
  96. package/catalog/frontmcp-development/examples/create-resource/binary-and-multi-content.md +111 -0
  97. package/catalog/frontmcp-development/examples/create-resource/parameterized-template.md +84 -0
  98. package/catalog/frontmcp-development/examples/create-skill/basic-inline-skill.md +96 -0
  99. package/catalog/frontmcp-development/examples/create-skill/directory-based-skill.md +115 -0
  100. package/catalog/frontmcp-development/examples/create-skill/parameterized-skill.md +96 -0
  101. package/catalog/frontmcp-development/examples/create-skill-with-tools/basic-tool-orchestration.md +76 -0
  102. package/catalog/frontmcp-development/examples/create-skill-with-tools/directory-skill-with-tools.md +149 -0
  103. package/catalog/frontmcp-development/examples/create-skill-with-tools/incident-response-skill.md +92 -0
  104. package/catalog/frontmcp-development/examples/create-tool/basic-class-tool.md +62 -0
  105. package/catalog/frontmcp-development/examples/create-tool/tool-with-di-and-errors.md +84 -0
  106. package/catalog/frontmcp-development/examples/create-tool/tool-with-rate-limiting-and-progress.md +93 -0
  107. package/catalog/frontmcp-development/examples/create-tool-annotations/destructive-delete-tool.md +94 -0
  108. package/catalog/frontmcp-development/examples/create-tool-annotations/readonly-query-tool.md +60 -0
  109. package/catalog/frontmcp-development/examples/create-tool-output-schema-types/primitive-and-media-outputs.md +104 -0
  110. package/catalog/frontmcp-development/examples/create-tool-output-schema-types/zod-raw-shape-output.md +63 -0
  111. package/catalog/frontmcp-development/examples/create-tool-output-schema-types/zod-schema-advanced-output.md +103 -0
  112. package/catalog/frontmcp-development/examples/create-workflow/basic-deploy-pipeline.md +91 -0
  113. package/catalog/frontmcp-development/examples/create-workflow/parallel-validation-pipeline.md +90 -0
  114. package/catalog/frontmcp-development/examples/create-workflow/webhook-triggered-workflow.md +136 -0
  115. package/catalog/frontmcp-development/examples/decorators-guide/agent-skill-job-workflow.md +145 -0
  116. package/catalog/frontmcp-development/examples/decorators-guide/basic-server-with-app-and-tools.md +124 -0
  117. package/catalog/frontmcp-development/examples/decorators-guide/multi-app-with-plugins-and-providers.md +149 -0
  118. package/catalog/frontmcp-development/examples/official-adapters/authenticated-adapter-with-polling.md +84 -0
  119. package/catalog/frontmcp-development/examples/official-adapters/basic-openapi-adapter.md +54 -0
  120. package/catalog/frontmcp-development/examples/official-adapters/multi-api-hub-with-inline-spec.md +130 -0
  121. package/catalog/frontmcp-development/examples/official-plugins/cache-and-feature-flags.md +117 -0
  122. package/catalog/frontmcp-development/examples/official-plugins/production-multi-plugin-setup.md +147 -0
  123. package/catalog/frontmcp-development/examples/official-plugins/remember-plugin-session-memory.md +104 -0
  124. package/catalog/frontmcp-development/references/create-adapter.md +14 -0
  125. package/catalog/frontmcp-development/references/create-agent-llm-config.md +14 -0
  126. package/catalog/frontmcp-development/references/create-agent.md +15 -0
  127. package/catalog/frontmcp-development/references/create-job.md +15 -0
  128. package/catalog/frontmcp-development/references/create-plugin-hooks.md +51 -0
  129. package/catalog/frontmcp-development/references/create-plugin.md +186 -11
  130. package/catalog/frontmcp-development/references/create-prompt.md +17 -0
  131. package/catalog/frontmcp-development/references/create-provider.md +14 -0
  132. package/catalog/frontmcp-development/references/create-resource.md +127 -0
  133. package/catalog/frontmcp-development/references/create-skill-with-tools.md +126 -7
  134. package/catalog/frontmcp-development/references/create-skill.md +57 -12
  135. package/catalog/frontmcp-development/references/create-tool-annotations.md +14 -0
  136. package/catalog/frontmcp-development/references/create-tool-output-schema-types.md +15 -0
  137. package/catalog/frontmcp-development/references/create-tool.md +205 -1
  138. package/catalog/frontmcp-development/references/create-workflow.md +15 -0
  139. package/catalog/frontmcp-development/references/decorators-guide.md +155 -78
  140. package/catalog/frontmcp-development/references/official-adapters.md +31 -16
  141. package/catalog/frontmcp-development/references/official-plugins.md +62 -28
  142. package/catalog/frontmcp-extensibility/SKILL.md +103 -0
  143. package/catalog/frontmcp-extensibility/examples/vectoriadb/product-catalog-search.md +175 -0
  144. package/catalog/frontmcp-extensibility/examples/vectoriadb/semantic-search-with-persistence.md +138 -0
  145. package/catalog/frontmcp-extensibility/examples/vectoriadb/tfidf-keyword-search.md +103 -0
  146. package/catalog/frontmcp-extensibility/references/vectoriadb.md +299 -0
  147. package/catalog/frontmcp-guides/SKILL.md +7 -4
  148. package/catalog/frontmcp-guides/examples/example-knowledge-base/agent-and-plugin.md +160 -0
  149. package/catalog/frontmcp-guides/examples/example-knowledge-base/multi-app-composition.md +92 -0
  150. package/catalog/frontmcp-guides/examples/example-knowledge-base/vector-search-and-resources.md +135 -0
  151. package/catalog/frontmcp-guides/examples/example-task-manager/auth-and-crud-tools.md +135 -0
  152. package/catalog/frontmcp-guides/examples/example-task-manager/authenticated-e2e-tests.md +148 -0
  153. package/catalog/frontmcp-guides/examples/example-task-manager/redis-provider-with-di.md +129 -0
  154. package/catalog/frontmcp-guides/examples/example-weather-api/server-and-app-setup.md +75 -0
  155. package/catalog/frontmcp-guides/examples/example-weather-api/unit-and-e2e-tests.md +142 -0
  156. package/catalog/frontmcp-guides/examples/example-weather-api/weather-tool-with-schemas.md +74 -0
  157. package/catalog/frontmcp-guides/references/example-knowledge-base.md +15 -0
  158. package/catalog/frontmcp-guides/references/example-task-manager.md +30 -21
  159. package/catalog/frontmcp-guides/references/example-weather-api.md +18 -6
  160. package/catalog/frontmcp-observability/SKILL.md +144 -0
  161. package/catalog/frontmcp-observability/examples/structured-logging/stdout-logging.md +71 -0
  162. package/catalog/frontmcp-observability/examples/structured-logging/winston-integration.md +70 -0
  163. package/catalog/frontmcp-observability/examples/telemetry-api/agent-nested-tracing.md +86 -0
  164. package/catalog/frontmcp-observability/examples/telemetry-api/plugin-telemetry.md +93 -0
  165. package/catalog/frontmcp-observability/examples/telemetry-api/tool-custom-spans.md +72 -0
  166. package/catalog/frontmcp-observability/examples/testing-observability/test-custom-spans.md +90 -0
  167. package/catalog/frontmcp-observability/examples/testing-observability/test-log-correlation.md +104 -0
  168. package/catalog/frontmcp-observability/examples/tracing-setup/basic-tracing.md +82 -0
  169. package/catalog/frontmcp-observability/examples/tracing-setup/production-tracing.md +73 -0
  170. package/catalog/frontmcp-observability/examples/vendor-integrations/coralogix-setup.md +74 -0
  171. package/catalog/frontmcp-observability/references/structured-logging.md +114 -0
  172. package/catalog/frontmcp-observability/references/telemetry-api.md +155 -0
  173. package/catalog/frontmcp-observability/references/testing-observability.md +169 -0
  174. package/catalog/frontmcp-observability/references/tracing-setup.md +146 -0
  175. package/catalog/frontmcp-observability/references/vendor-integrations.md +164 -0
  176. package/catalog/frontmcp-production-readiness/SKILL.md +99 -0
  177. package/catalog/frontmcp-production-readiness/examples/common-checklist/caching-and-performance.md +102 -0
  178. package/catalog/frontmcp-production-readiness/examples/common-checklist/observability-setup.md +104 -0
  179. package/catalog/frontmcp-production-readiness/examples/common-checklist/security-hardening.md +95 -0
  180. package/catalog/frontmcp-production-readiness/examples/health-readiness-endpoints/basic-health-setup.md +81 -0
  181. package/catalog/frontmcp-production-readiness/examples/health-readiness-endpoints/custom-probes.md +136 -0
  182. package/catalog/frontmcp-production-readiness/examples/production-browser/browser-bundle-config.md +93 -0
  183. package/catalog/frontmcp-production-readiness/examples/production-browser/cross-platform-crypto.md +116 -0
  184. package/catalog/frontmcp-production-readiness/examples/production-browser/security-and-performance.md +128 -0
  185. package/catalog/frontmcp-production-readiness/examples/production-cli-binary/binary-build-config.md +109 -0
  186. package/catalog/frontmcp-production-readiness/examples/production-cli-binary/stdio-transport-error-handling.md +132 -0
  187. package/catalog/frontmcp-production-readiness/examples/production-cli-daemon/daemon-socket-config.md +82 -0
  188. package/catalog/frontmcp-production-readiness/examples/production-cli-daemon/graceful-shutdown-cleanup.md +107 -0
  189. package/catalog/frontmcp-production-readiness/examples/production-cli-daemon/security-and-permissions.md +119 -0
  190. package/catalog/frontmcp-production-readiness/examples/production-cloudflare/durable-objects-state.md +124 -0
  191. package/catalog/frontmcp-production-readiness/examples/production-cloudflare/workers-runtime-constraints.md +103 -0
  192. package/catalog/frontmcp-production-readiness/examples/production-cloudflare/wrangler-config.md +89 -0
  193. package/catalog/frontmcp-production-readiness/examples/production-lambda/cold-start-connection-reuse.md +122 -0
  194. package/catalog/frontmcp-production-readiness/examples/production-lambda/sam-template.md +107 -0
  195. package/catalog/frontmcp-production-readiness/examples/production-lambda/scaling-and-monitoring.md +138 -0
  196. package/catalog/frontmcp-production-readiness/examples/production-node-sdk/basic-sdk-lifecycle.md +85 -0
  197. package/catalog/frontmcp-production-readiness/examples/production-node-sdk/multi-instance-cleanup.md +110 -0
  198. package/catalog/frontmcp-production-readiness/examples/production-node-sdk/package-json-config.md +107 -0
  199. package/catalog/frontmcp-production-readiness/examples/production-node-server/docker-multi-stage.md +103 -0
  200. package/catalog/frontmcp-production-readiness/examples/production-node-server/graceful-shutdown.md +87 -0
  201. package/catalog/frontmcp-production-readiness/examples/production-node-server/redis-session-scaling.md +97 -0
  202. package/catalog/frontmcp-production-readiness/examples/production-vercel/cold-start-optimization.md +104 -0
  203. package/catalog/frontmcp-production-readiness/examples/production-vercel/stateless-serverless-design.md +91 -0
  204. package/catalog/frontmcp-production-readiness/examples/production-vercel/vercel-edge-config.md +78 -0
  205. package/catalog/frontmcp-production-readiness/references/common-checklist.md +175 -0
  206. package/catalog/frontmcp-production-readiness/references/health-readiness-endpoints.md +198 -0
  207. package/catalog/frontmcp-production-readiness/references/production-browser.md +56 -0
  208. package/catalog/frontmcp-production-readiness/references/production-cli-binary.md +71 -0
  209. package/catalog/frontmcp-production-readiness/references/production-cli-daemon.md +71 -0
  210. package/catalog/frontmcp-production-readiness/references/production-cloudflare.md +62 -0
  211. package/catalog/frontmcp-production-readiness/references/production-lambda.md +63 -0
  212. package/catalog/frontmcp-production-readiness/references/production-node-sdk.md +76 -0
  213. package/catalog/frontmcp-production-readiness/references/production-node-server.md +71 -0
  214. package/catalog/frontmcp-production-readiness/references/production-vercel.md +62 -0
  215. package/catalog/frontmcp-setup/SKILL.md +19 -14
  216. package/catalog/frontmcp-setup/examples/frontmcp-skills-usage/bundle-presets-scaffolding.md +61 -0
  217. package/catalog/frontmcp-setup/examples/frontmcp-skills-usage/install-and-search-skills.md +83 -0
  218. package/catalog/frontmcp-setup/examples/multi-app-composition/local-apps-with-shared-tools.md +87 -0
  219. package/catalog/frontmcp-setup/examples/multi-app-composition/per-app-auth-and-isolation.md +88 -0
  220. package/catalog/frontmcp-setup/examples/multi-app-composition/remote-and-esm-apps.md +81 -0
  221. package/catalog/frontmcp-setup/examples/nx-workflow/build-test-affected.md +77 -0
  222. package/catalog/frontmcp-setup/examples/nx-workflow/multi-server-deployment.md +93 -0
  223. package/catalog/frontmcp-setup/examples/nx-workflow/scaffold-and-generate.md +62 -0
  224. package/catalog/frontmcp-setup/examples/project-structure-nx/nx-generator-scaffolding.md +73 -0
  225. package/catalog/frontmcp-setup/examples/project-structure-nx/nx-workspace-with-apps.md +85 -0
  226. package/catalog/frontmcp-setup/examples/project-structure-nx/shared-library-usage.md +89 -0
  227. package/catalog/frontmcp-setup/examples/project-structure-standalone/dev-workflow-commands.md +64 -0
  228. package/catalog/frontmcp-setup/examples/project-structure-standalone/feature-folder-organization.md +111 -0
  229. package/catalog/frontmcp-setup/examples/project-structure-standalone/minimal-standalone-layout.md +73 -0
  230. package/catalog/frontmcp-setup/examples/readme-guide/node-server-readme.md +89 -0
  231. package/catalog/frontmcp-setup/examples/readme-guide/vercel-deployment-readme.md +90 -0
  232. package/catalog/frontmcp-setup/examples/setup-project/basic-node-server.md +99 -0
  233. package/catalog/frontmcp-setup/examples/setup-project/cli-scaffold-with-flags.md +77 -0
  234. package/catalog/frontmcp-setup/examples/setup-project/vercel-serverless-server.md +89 -0
  235. package/catalog/frontmcp-setup/examples/setup-redis/docker-redis-local-dev.md +88 -0
  236. package/catalog/frontmcp-setup/examples/setup-redis/hybrid-vercel-kv-with-pubsub.md +78 -0
  237. package/catalog/frontmcp-setup/examples/setup-redis/vercel-kv-serverless.md +78 -0
  238. package/catalog/frontmcp-setup/examples/setup-sqlite/basic-sqlite-setup.md +75 -0
  239. package/catalog/frontmcp-setup/examples/setup-sqlite/encrypted-sqlite-storage.md +55 -0
  240. package/catalog/frontmcp-setup/examples/setup-sqlite/unix-socket-daemon.md +70 -0
  241. package/catalog/frontmcp-setup/references/frontmcp-skills-usage.md +33 -9
  242. package/catalog/frontmcp-setup/references/multi-app-composition.md +15 -0
  243. package/catalog/frontmcp-setup/references/nx-workflow.md +15 -0
  244. package/catalog/frontmcp-setup/references/project-structure-nx.md +15 -0
  245. package/catalog/frontmcp-setup/references/project-structure-standalone.md +15 -0
  246. package/catalog/frontmcp-setup/references/readme-guide.md +235 -0
  247. package/catalog/frontmcp-setup/references/setup-project.md +16 -1
  248. package/catalog/frontmcp-setup/references/setup-redis.md +15 -0
  249. package/catalog/frontmcp-setup/references/setup-sqlite.md +15 -0
  250. package/catalog/frontmcp-testing/SKILL.md +41 -27
  251. package/catalog/frontmcp-testing/examples/setup-testing/fixture-based-e2e-test.md +70 -0
  252. package/catalog/frontmcp-testing/examples/setup-testing/jest-config-with-coverage.md +59 -0
  253. package/catalog/frontmcp-testing/examples/setup-testing/unit-test-tool-resource-prompt.md +115 -0
  254. package/catalog/frontmcp-testing/examples/test-auth/oauth-flow-test.md +78 -0
  255. package/catalog/frontmcp-testing/examples/test-auth/role-based-access-test.md +88 -0
  256. package/catalog/frontmcp-testing/examples/test-auth/token-factory-test.md +71 -0
  257. package/catalog/frontmcp-testing/examples/test-browser-build/browser-bundle-validation.md +58 -0
  258. package/catalog/frontmcp-testing/examples/test-browser-build/playwright-browser-test.md +69 -0
  259. package/catalog/frontmcp-testing/examples/test-cli-binary/binary-startup-test.md +77 -0
  260. package/catalog/frontmcp-testing/examples/test-cli-binary/js-bundle-import-test.md +56 -0
  261. package/catalog/frontmcp-testing/examples/test-direct-client/basic-create-test.md +74 -0
  262. package/catalog/frontmcp-testing/examples/test-direct-client/openai-claude-format-test.md +79 -0
  263. package/catalog/frontmcp-testing/examples/test-e2e-handler/basic-e2e-test.md +67 -0
  264. package/catalog/frontmcp-testing/examples/test-e2e-handler/manual-client-with-transport.md +72 -0
  265. package/catalog/frontmcp-testing/examples/test-e2e-handler/tool-call-and-error-e2e.md +73 -0
  266. package/catalog/frontmcp-testing/examples/test-tool-unit/basic-tool-test.md +69 -0
  267. package/catalog/frontmcp-testing/examples/test-tool-unit/schema-validation-test.md +82 -0
  268. package/catalog/frontmcp-testing/examples/test-tool-unit/tool-error-handling-test.md +92 -0
  269. package/catalog/frontmcp-testing/references/setup-testing.md +17 -0
  270. package/catalog/frontmcp-testing/references/test-auth.md +15 -0
  271. package/catalog/frontmcp-testing/references/test-browser-build.md +14 -0
  272. package/catalog/frontmcp-testing/references/test-cli-binary.md +14 -0
  273. package/catalog/frontmcp-testing/references/test-direct-client.md +14 -0
  274. package/catalog/frontmcp-testing/references/test-e2e-handler.md +15 -0
  275. package/catalog/frontmcp-testing/references/test-tool-unit.md +15 -0
  276. package/catalog/skills-manifest.json +2849 -32
  277. package/package.json +2 -2
  278. package/src/index.d.ts +1 -1
  279. package/src/index.js.map +1 -1
  280. package/src/loader.js +0 -1
  281. package/src/loader.js.map +1 -1
  282. package/src/manifest.d.ts +36 -1
  283. package/src/manifest.js +6 -1
  284. package/src/manifest.js.map +1 -1
@@ -0,0 +1,90 @@
1
+ ---
2
+ name: parallel-validation-pipeline
3
+ reference: create-workflow
4
+ level: intermediate
5
+ description: 'A workflow that validates multiple datasets in parallel, then conditionally merges results or notifies on failure.'
6
+ tags: [development, workflow, parallel, validation, pipeline]
7
+ features:
8
+ - 'Running steps in parallel by omitting `dependsOn` (no mutual dependencies)'
9
+ - 'Using `maxConcurrency` to limit how many steps run at the same time'
10
+ - 'Conditional steps with `condition` that check `.state` of previous steps'
11
+ - 'Fan-out/fan-in pattern: parallel validation steps converge into a merge step'
12
+ - 'Branching: separate success and failure notification paths'
13
+ ---
14
+
15
+ # Parallel Validation Pipeline with Conditional Steps
16
+
17
+ A workflow that validates multiple datasets in parallel, then conditionally merges results or notifies on failure.
18
+
19
+ ## Code
20
+
21
+ ```typescript
22
+ // src/workflows/data-validation.workflow.ts
23
+ import { Workflow } from '@frontmcp/sdk';
24
+
25
+ @Workflow({
26
+ name: 'data-validation-pipeline',
27
+ description: 'Validate data from multiple sources in parallel, then merge',
28
+ maxConcurrency: 3,
29
+ steps: [
30
+ // These three steps have no dependencies -- they run in parallel
31
+ {
32
+ id: 'validate-users',
33
+ jobName: 'validate-dataset',
34
+ input: { dataset: 'users', rules: ['no-nulls', 'email-format'] },
35
+ },
36
+ {
37
+ id: 'validate-orders',
38
+ jobName: 'validate-dataset',
39
+ input: { dataset: 'orders', rules: ['no-nulls', 'positive-amounts'] },
40
+ },
41
+ {
42
+ id: 'validate-products',
43
+ jobName: 'validate-dataset',
44
+ input: { dataset: 'products', rules: ['no-nulls', 'unique-sku'] },
45
+ },
46
+ // This step depends on all three -- runs after all complete
47
+ {
48
+ id: 'merge-results',
49
+ jobName: 'merge-validations',
50
+ dependsOn: ['validate-users', 'validate-orders', 'validate-products'],
51
+ condition: (steps) =>
52
+ steps.get('validate-users').state === 'completed' &&
53
+ steps.get('validate-orders').state === 'completed' &&
54
+ steps.get('validate-products').state === 'completed',
55
+ input: (steps) => ({
56
+ userReport: steps.get('validate-users').outputs,
57
+ orderReport: steps.get('validate-orders').outputs,
58
+ productReport: steps.get('validate-products').outputs,
59
+ }),
60
+ },
61
+ // Notify on any failure
62
+ {
63
+ id: 'notify-failure',
64
+ jobName: 'send-notification',
65
+ dependsOn: ['validate-users', 'validate-orders', 'validate-products'],
66
+ condition: (steps) =>
67
+ steps.get('validate-users').state === 'failed' ||
68
+ steps.get('validate-orders').state === 'failed' ||
69
+ steps.get('validate-products').state === 'failed',
70
+ input: {
71
+ channel: '#alerts',
72
+ message: 'Data validation pipeline encountered failures',
73
+ },
74
+ },
75
+ ],
76
+ })
77
+ class DataValidationPipeline {}
78
+ ```
79
+
80
+ ## What This Demonstrates
81
+
82
+ - Running steps in parallel by omitting `dependsOn` (no mutual dependencies)
83
+ - Using `maxConcurrency` to limit how many steps run at the same time
84
+ - Conditional steps with `condition` that check `.state` of previous steps
85
+ - Fan-out/fan-in pattern: parallel validation steps converge into a merge step
86
+ - Branching: separate success and failure notification paths
87
+
88
+ ## Related
89
+
90
+ - See `create-workflow` for the full DAG execution model, diamond dependencies, and `continueOnError`
@@ -0,0 +1,136 @@
1
+ ---
2
+ name: webhook-triggered-workflow
3
+ reference: create-workflow
4
+ level: advanced
5
+ description: 'A CI/CD workflow triggered by a webhook, featuring `continueOnError`, per-step conditions, and the `workflow()` function builder.'
6
+ tags: [development, workflow, webhook, triggered]
7
+ features:
8
+ - "Webhook trigger with `trigger: 'webhook'` and `webhook: { path, secret, methods }`"
9
+ - 'Using `continueOnError: true` to allow the workflow to proceed past non-critical step failures'
10
+ - 'Conditional branching: separate success and failure notification steps based on prior step state'
11
+ - 'Workflow-level `permissions` for access control'
12
+ - 'The `workflow()` function builder as a lighter alternative to the class pattern'
13
+ ---
14
+
15
+ # Webhook-Triggered Workflow with Error Resilience
16
+
17
+ A CI/CD workflow triggered by a webhook, featuring `continueOnError`, per-step conditions, and the `workflow()` function builder.
18
+
19
+ ## Code
20
+
21
+ ```typescript
22
+ // src/workflows/github-deploy.workflow.ts
23
+ import { Workflow } from '@frontmcp/sdk';
24
+
25
+ @Workflow({
26
+ name: 'github-deploy',
27
+ description: 'Deploy on GitHub push events',
28
+ trigger: 'webhook',
29
+ webhook: {
30
+ path: '/webhooks/github-deploy',
31
+ secret: process.env.WEBHOOK_SECRET,
32
+ methods: ['POST'],
33
+ },
34
+ timeout: 900000, // 15 minutes
35
+ maxConcurrency: 3,
36
+ permissions: {
37
+ actions: ['create', 'read', 'execute', 'list'],
38
+ roles: ['admin', 'ci-bot'],
39
+ },
40
+ steps: [
41
+ {
42
+ id: 'build',
43
+ jobName: 'build-project',
44
+ input: { branch: 'main' },
45
+ },
46
+ {
47
+ id: 'lint',
48
+ jobName: 'run-linter',
49
+ dependsOn: ['build'],
50
+ continueOnError: true, // lint failures are non-blocking
51
+ input: (steps) => ({
52
+ workDir: steps.get('build').outputs.workDir,
53
+ }),
54
+ },
55
+ {
56
+ id: 'test',
57
+ jobName: 'run-unit-tests',
58
+ dependsOn: ['build'],
59
+ input: (steps) => ({
60
+ workDir: steps.get('build').outputs.workDir,
61
+ coverage: true,
62
+ }),
63
+ },
64
+ {
65
+ id: 'deploy',
66
+ jobName: 'deploy-artifact',
67
+ dependsOn: ['lint', 'test'],
68
+ condition: (steps) => steps.get('test').state === 'completed' && steps.get('test').outputs.passed === true,
69
+ input: (steps) => ({
70
+ artifactUrl: steps.get('build').outputs.artifactUrl,
71
+ environment: 'staging',
72
+ }),
73
+ },
74
+ {
75
+ id: 'notify-success',
76
+ jobName: 'notify-team',
77
+ dependsOn: ['deploy'],
78
+ condition: (steps) => steps.get('deploy').state === 'completed',
79
+ input: (steps) => ({
80
+ channel: '#deployments',
81
+ message: `Deployed to ${steps.get('deploy').outputs.url}`,
82
+ }),
83
+ },
84
+ {
85
+ id: 'notify-failure',
86
+ jobName: 'notify-team',
87
+ dependsOn: ['test'],
88
+ condition: (steps) => steps.get('test').state === 'failed',
89
+ input: {
90
+ channel: '#alerts',
91
+ message: 'CI pipeline failed -- check test results',
92
+ },
93
+ },
94
+ ],
95
+ })
96
+ class GithubDeploy {}
97
+ ```
98
+
99
+ ```typescript
100
+ // src/workflows/quick-deploy.workflow.ts
101
+ import { workflow } from '@frontmcp/sdk';
102
+
103
+ // Function-style workflow for simpler cases
104
+ const QuickDeploy = workflow({
105
+ name: 'quick-deploy',
106
+ description: 'Simplified deployment workflow',
107
+ steps: [
108
+ {
109
+ id: 'build',
110
+ jobName: 'build-project',
111
+ input: { target: 'production' },
112
+ },
113
+ {
114
+ id: 'deploy',
115
+ jobName: 'deploy-to-env',
116
+ dependsOn: ['build'],
117
+ input: (steps) => ({
118
+ artifact: steps.get('build').outputs.artifactUrl,
119
+ environment: 'staging',
120
+ }),
121
+ },
122
+ ],
123
+ });
124
+ ```
125
+
126
+ ## What This Demonstrates
127
+
128
+ - Webhook trigger with `trigger: 'webhook'` and `webhook: { path, secret, methods }`
129
+ - Using `continueOnError: true` to allow the workflow to proceed past non-critical step failures
130
+ - Conditional branching: separate success and failure notification steps based on prior step state
131
+ - Workflow-level `permissions` for access control
132
+ - The `workflow()` function builder as a lighter alternative to the class pattern
133
+
134
+ ## Related
135
+
136
+ - See `create-workflow` for the full trigger types (manual, webhook, event), error handling, and registration
@@ -0,0 +1,145 @@
1
+ ---
2
+ name: agent-skill-job-workflow
3
+ reference: decorators-guide
4
+ level: advanced
5
+ description: 'Demonstrates the advanced decorator types: `@Agent` for autonomous AI agents, `@Skill` for knowledge packages, `@Job` for background tasks, and `@Workflow` for multi-step orchestration.'
6
+ tags: [development, decorators, agent, skill, job, workflow]
7
+ features:
8
+ - '`@Agent` with LLM config, input schema, and delegated tools for autonomous task execution'
9
+ - '`@Skill` with inline instructions and tool references for reusable knowledge packages'
10
+ - '`@Job` with retry policy, timeout, and typed input/output for background processing'
11
+ - '`@Workflow` with ordered steps, `dependsOn` for sequencing, and `condition` for conditional execution'
12
+ - 'Enabling jobs and skills at the server level via `jobs: { enabled: true }` and `skillsConfig: { enabled: true }`'
13
+ - 'All advanced decorators registered in a single `@App` module'
14
+ ---
15
+
16
+ # Agents, Skills, Jobs, and Workflows
17
+
18
+ Demonstrates the advanced decorator types: `@Agent` for autonomous AI agents, `@Skill` for knowledge packages, `@Job` for background tasks, and `@Workflow` for multi-step orchestration.
19
+
20
+ ## Code
21
+
22
+ ```typescript
23
+ // src/agents/research.agent.ts
24
+ import { Agent, AgentContext } from '@frontmcp/sdk';
25
+ import { z } from 'zod';
26
+
27
+ @Agent({
28
+ name: 'research_agent',
29
+ description: 'Researches topics and produces summaries',
30
+ llm: { model: 'claude-sonnet-4-20250514', provider: 'anthropic' },
31
+ inputSchema: {
32
+ topic: z.string().describe('Topic to research'),
33
+ },
34
+ tools: [WebSearchTool, SummarizeTool],
35
+ })
36
+ class ResearchAgent extends AgentContext {
37
+ async execute(input: { topic: string }) {
38
+ return this.run(`Research and summarize: ${input.topic}`);
39
+ }
40
+ }
41
+ ```
42
+
43
+ ```typescript
44
+ // src/skills/code-migration.skill.ts
45
+ import { Skill } from '@frontmcp/sdk';
46
+
47
+ @Skill({
48
+ name: 'code_migration',
49
+ description: 'Guides migration of code between frameworks',
50
+ instructions: `
51
+ 1. Analyze the source codebase structure
52
+ 2. Identify framework-specific patterns
53
+ 3. Generate migration plan
54
+ 4. Apply transformations using the provided tools
55
+ `,
56
+ tools: [AnalyzeTool, TransformTool, ValidateTool],
57
+ visibility: 'both',
58
+ })
59
+ class CodeMigrationSkill {}
60
+ ```
61
+
62
+ ```typescript
63
+ // src/jobs/sync-data.job.ts
64
+ import { Job, JobContext } from '@frontmcp/sdk';
65
+ import { z } from 'zod';
66
+
67
+ @Job({
68
+ name: 'sync_data',
69
+ description: 'Synchronize data from external sources',
70
+ inputSchema: z.object({ source: z.string().describe('Data source to sync') }),
71
+ outputSchema: z.object({ synced: z.number() }),
72
+ retry: { maxAttempts: 3, backoffMs: 1000, backoffMultiplier: 2, maxBackoffMs: 60_000 },
73
+ timeout: 300_000,
74
+ })
75
+ class SyncDataJob extends JobContext {
76
+ async execute(input: { source: string }) {
77
+ const count = await this.get(SyncService).runFullSync(input.source);
78
+ return { synced: count };
79
+ }
80
+ }
81
+ ```
82
+
83
+ ```typescript
84
+ // src/workflows/deploy-pipeline.workflow.ts
85
+ import { Workflow } from '@frontmcp/sdk';
86
+
87
+ @Workflow({
88
+ name: 'deploy_pipeline',
89
+ description: 'Full deployment pipeline',
90
+ trigger: 'webhook',
91
+ webhookConfig: {
92
+ path: '/hooks/deploy',
93
+ secret: process.env.WEBHOOK_SECRET!,
94
+ methods: ['POST'],
95
+ },
96
+ timeout: 600_000,
97
+ steps: [
98
+ { id: 'build', jobName: 'build_app', input: { env: 'production' } },
99
+ { id: 'test', jobName: 'run_tests', dependsOn: ['build'] },
100
+ {
101
+ id: 'deploy',
102
+ jobName: 'deploy_app',
103
+ dependsOn: ['test'],
104
+ condition: (steps) => steps.test.success,
105
+ },
106
+ ],
107
+ })
108
+ class DeployPipeline {}
109
+ ```
110
+
111
+ ```typescript
112
+ // src/server.ts
113
+ import { FrontMcp, App } from '@frontmcp/sdk';
114
+
115
+ @App({
116
+ name: 'platform',
117
+ agents: [ResearchAgent],
118
+ skills: [CodeMigrationSkill],
119
+ jobs: [SyncDataJob],
120
+ workflows: [DeployPipeline],
121
+ })
122
+ class PlatformApp {}
123
+
124
+ @FrontMcp({
125
+ info: { name: 'advanced-server', version: '1.0.0' },
126
+ apps: [PlatformApp],
127
+ jobs: { enabled: true },
128
+ skillsConfig: { enabled: true },
129
+ })
130
+ class MyServer {}
131
+ ```
132
+
133
+ ## What This Demonstrates
134
+
135
+ - `@Agent` with LLM config, input schema, and delegated tools for autonomous task execution
136
+ - `@Skill` with inline instructions and tool references for reusable knowledge packages
137
+ - `@Job` with retry policy, timeout, and typed input/output for background processing
138
+ - `@Workflow` with ordered steps, `dependsOn` for sequencing, and `condition` for conditional execution
139
+ - Enabling jobs and skills at the server level via `jobs: { enabled: true }` and `skillsConfig: { enabled: true }`
140
+ - All advanced decorators registered in a single `@App` module
141
+
142
+ ## Related
143
+
144
+ - See `decorators-guide` for the complete decorator hierarchy and all field definitions
145
+ - See `create-plugin-hooks` for attaching lifecycle hooks to any flow
@@ -0,0 +1,124 @@
1
+ ---
2
+ name: basic-server-with-app-and-tools
3
+ reference: decorators-guide
4
+ level: basic
5
+ description: 'Demonstrates the minimal decorator hierarchy to create a working FrontMCP server with one app containing a tool and a resource.'
6
+ tags: [development, decorators, app, tools]
7
+ features:
8
+ - 'The `@FrontMcp` -> `@App` -> `@Tool`/`@Resource`/`@Prompt` nesting hierarchy'
9
+ - 'Tool classes extend `ToolContext` and implement `execute()`'
10
+ - 'Resource classes extend `ResourceContext` and implement `read()`'
11
+ - 'Prompt classes extend `PromptContext` and implement `execute()`'
12
+ - 'Apps group related tools, resources, and prompts into logical modules'
13
+ ---
14
+
15
+ # Basic Server with @FrontMcp, @App, and @Tool
16
+
17
+ Demonstrates the minimal decorator hierarchy to create a working FrontMCP server with one app containing a tool and a resource.
18
+
19
+ ## Code
20
+
21
+ ```typescript
22
+ // src/tools/search-users.tool.ts
23
+ import { Tool, ToolContext } from '@frontmcp/sdk';
24
+ import { z } from 'zod';
25
+
26
+ @Tool({
27
+ name: 'search_users',
28
+ description: 'Search for users by name or email',
29
+ inputSchema: {
30
+ query: z.string().describe('Search query'),
31
+ limit: z.number().optional().default(10),
32
+ },
33
+ })
34
+ class SearchUsersTool extends ToolContext {
35
+ async execute(input: { query: string; limit: number }) {
36
+ const users = await this.get(UserService).search(input.query, input.limit);
37
+ return { users };
38
+ }
39
+ }
40
+ ```
41
+
42
+ ```typescript
43
+ // src/resources/app-config.resource.ts
44
+ import { Resource, ResourceContext } from '@frontmcp/sdk';
45
+
46
+ @Resource({
47
+ name: 'app_config',
48
+ uri: 'config://app/settings',
49
+ description: 'Current application settings',
50
+ mimeType: 'application/json',
51
+ })
52
+ class AppConfigResource extends ResourceContext {
53
+ async read() {
54
+ const config = await this.get(ConfigService).getAll();
55
+ return { contents: [{ uri: this.uri, text: JSON.stringify(config) }] };
56
+ }
57
+ }
58
+ ```
59
+
60
+ ```typescript
61
+ // src/prompts/code-review.prompt.ts
62
+ import { Prompt, PromptContext } from '@frontmcp/sdk';
63
+
64
+ @Prompt({
65
+ name: 'code_review',
66
+ description: 'Generate a code review for the given code',
67
+ arguments: [
68
+ { name: 'code', description: 'The code to review', required: true },
69
+ { name: 'language', description: 'Programming language' },
70
+ ],
71
+ })
72
+ class CodeReviewPrompt extends PromptContext {
73
+ async execute(args: { code: string; language?: string }) {
74
+ return {
75
+ messages: [
76
+ {
77
+ role: 'user' as const,
78
+ content: {
79
+ type: 'text' as const,
80
+ text: `Review this ${args.language ?? ''} code:\n\n${args.code}`,
81
+ },
82
+ },
83
+ ],
84
+ };
85
+ }
86
+ }
87
+ ```
88
+
89
+ ```typescript
90
+ // src/server.ts
91
+ import { FrontMcp, App } from '@frontmcp/sdk';
92
+ import { SearchUsersTool } from './tools/search-users.tool';
93
+ import { AppConfigResource } from './resources/app-config.resource';
94
+ import { CodeReviewPrompt } from './prompts/code-review.prompt';
95
+
96
+ @App({
97
+ name: 'analytics',
98
+ tools: [SearchUsersTool],
99
+ resources: [AppConfigResource],
100
+ prompts: [CodeReviewPrompt],
101
+ })
102
+ class AnalyticsApp {}
103
+
104
+ @FrontMcp({
105
+ info: { name: 'my-server', version: '1.0.0' },
106
+ apps: [AnalyticsApp],
107
+ transport: 'modern',
108
+ http: { port: 3000 },
109
+ })
110
+ class MyServer {}
111
+ ```
112
+
113
+ ## What This Demonstrates
114
+
115
+ - The `@FrontMcp` -> `@App` -> `@Tool`/`@Resource`/`@Prompt` nesting hierarchy
116
+ - Tool classes extend `ToolContext` and implement `execute()`
117
+ - Resource classes extend `ResourceContext` and implement `read()`
118
+ - Prompt classes extend `PromptContext` and implement `execute()`
119
+ - Apps group related tools, resources, and prompts into logical modules
120
+
121
+ ## Related
122
+
123
+ - See `decorators-guide` for the full decorator reference including all field options
124
+ - See `create-tool` for step-by-step tool creation patterns
@@ -0,0 +1,149 @@
1
+ ---
2
+ name: multi-app-with-plugins-and-providers
3
+ reference: decorators-guide
4
+ level: intermediate
5
+ description: 'Demonstrates a server with multiple `@App` modules, a `@Provider` for dependency injection, and a `@Plugin` for cross-cutting concerns.'
6
+ tags: [development, database, multi-app, decorators, multi, app]
7
+ features:
8
+ - 'Organizing a server into multiple `@App` modules (`analytics` and `admin`)'
9
+ - 'Using `@Provider` with `useFactory` to register a database client for dependency injection'
10
+ - 'Accessing injected dependencies via `this.get(DatabaseToken)` in tools and resources'
11
+ - 'Using `@ResourceTemplate` with URI parameters (`{dashboardId}`) for dynamic resources'
12
+ - 'Registering a `@Plugin` at the server level so it applies across all apps'
13
+ - 'Global plugins go in `@FrontMcp({ plugins })`, app-scoped providers go in `@App({ providers })`'
14
+ ---
15
+
16
+ # Multi-App Server with Plugins and Providers
17
+
18
+ Demonstrates a server with multiple `@App` modules, a `@Provider` for dependency injection, and a `@Plugin` for cross-cutting concerns.
19
+
20
+ ## Code
21
+
22
+ ```typescript
23
+ // src/providers/database.provider.ts
24
+ import { Provider } from '@frontmcp/sdk';
25
+
26
+ export const DatabaseToken = Symbol('Database');
27
+
28
+ @Provider({
29
+ name: 'database',
30
+ provide: DatabaseToken,
31
+ useFactory: () => new DatabaseClient(process.env.DB_URL),
32
+ })
33
+ class DatabaseProvider {}
34
+ ```
35
+
36
+ ```typescript
37
+ // src/plugins/audit.plugin.ts
38
+ import { Plugin } from '@frontmcp/sdk';
39
+
40
+ @Plugin({
41
+ name: 'audit-log',
42
+ providers: [AuditLogProvider],
43
+ contextExtensions: [installAuditExtension],
44
+ })
45
+ class AuditPlugin {}
46
+ ```
47
+
48
+ ```typescript
49
+ // src/tools/query.tool.ts
50
+ import { Tool, ToolContext } from '@frontmcp/sdk';
51
+ import { z } from 'zod';
52
+
53
+ @Tool({
54
+ name: 'run_query',
55
+ description: 'Run an analytics query',
56
+ inputSchema: {
57
+ sql: z.string().describe('SQL query to execute'),
58
+ },
59
+ })
60
+ class QueryTool extends ToolContext {
61
+ async execute(input: { sql: string }) {
62
+ const db = this.get(DatabaseToken);
63
+ const results = await db.query(input.sql);
64
+ return { rows: results };
65
+ }
66
+ }
67
+ ```
68
+
69
+ ```typescript
70
+ // src/tools/report.tool.ts
71
+ import { Tool, ToolContext } from '@frontmcp/sdk';
72
+ import { z } from 'zod';
73
+
74
+ @Tool({
75
+ name: 'generate_report',
76
+ description: 'Generate a formatted report from a dataset',
77
+ inputSchema: {
78
+ datasetId: z.string(),
79
+ format: z.enum(['csv', 'json', 'pdf']),
80
+ },
81
+ })
82
+ class ReportTool extends ToolContext {
83
+ async execute(input: { datasetId: string; format: string }) {
84
+ const db = this.get(DatabaseToken);
85
+ const data = await db.getDataset(input.datasetId);
86
+ return { report: `Report in ${input.format} format`, rows: data.length };
87
+ }
88
+ }
89
+ ```
90
+
91
+ ```typescript
92
+ // src/resources/dashboard.resource.ts
93
+ import { ResourceTemplate, ResourceContext } from '@frontmcp/sdk';
94
+
95
+ @ResourceTemplate({
96
+ name: 'dashboard',
97
+ uriTemplate: 'dashboards://{dashboardId}',
98
+ description: 'Dashboard data by ID',
99
+ mimeType: 'application/json',
100
+ })
101
+ class DashboardResource extends ResourceContext {
102
+ async read(uri: string, params: { dashboardId: string }) {
103
+ const db = this.get(DatabaseToken);
104
+ const data = await db.getDashboard(params.dashboardId);
105
+ return { contents: [{ uri, text: JSON.stringify(data) }] };
106
+ }
107
+ }
108
+ ```
109
+
110
+ ```typescript
111
+ // src/server.ts
112
+ import { FrontMcp, App } from '@frontmcp/sdk';
113
+
114
+ @App({
115
+ name: 'analytics',
116
+ tools: [QueryTool, ReportTool],
117
+ resources: [DashboardResource],
118
+ providers: [DatabaseProvider],
119
+ })
120
+ class AnalyticsApp {}
121
+
122
+ @App({
123
+ name: 'admin',
124
+ tools: [ManageUsersTool],
125
+ })
126
+ class AdminApp {}
127
+
128
+ @FrontMcp({
129
+ info: { name: 'multi-app-server', version: '1.0.0' },
130
+ apps: [AnalyticsApp, AdminApp],
131
+ plugins: [AuditPlugin],
132
+ http: { port: 3000 },
133
+ })
134
+ class MyServer {}
135
+ ```
136
+
137
+ ## What This Demonstrates
138
+
139
+ - Organizing a server into multiple `@App` modules (`analytics` and `admin`)
140
+ - Using `@Provider` with `useFactory` to register a database client for dependency injection
141
+ - Accessing injected dependencies via `this.get(DatabaseToken)` in tools and resources
142
+ - Using `@ResourceTemplate` with URI parameters (`{dashboardId}`) for dynamic resources
143
+ - Registering a `@Plugin` at the server level so it applies across all apps
144
+ - Global plugins go in `@FrontMcp({ plugins })`, app-scoped providers go in `@App({ providers })`
145
+
146
+ ## Related
147
+
148
+ - See `decorators-guide` for the complete list of all decorator fields and their types
149
+ - See `create-plugin-hooks` for adding lifecycle hooks to plugins