@frontmcp/skills 0.0.1 → 1.0.0-beta.11
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 +58 -13
- package/catalog/frontmcp-config/SKILL.md +156 -0
- package/catalog/{auth/configure-auth/references/auth-modes.md → frontmcp-config/references/configure-auth-modes.md} +5 -0
- package/catalog/frontmcp-config/references/configure-auth.md +243 -0
- package/catalog/frontmcp-config/references/configure-elicitation.md +183 -0
- package/catalog/frontmcp-config/references/configure-http.md +210 -0
- package/catalog/frontmcp-config/references/configure-session.md +210 -0
- package/catalog/{config/configure-throttle/references/guard-config.md → frontmcp-config/references/configure-throttle-guard-config.md} +5 -0
- package/catalog/frontmcp-config/references/configure-throttle.md +234 -0
- package/catalog/{config/configure-transport/references/protocol-presets.md → frontmcp-config/references/configure-transport-protocol-presets.md} +5 -0
- package/catalog/frontmcp-config/references/configure-transport.md +200 -0
- package/catalog/frontmcp-config/references/setup-redis.md +9 -0
- package/catalog/frontmcp-config/references/setup-sqlite.md +9 -0
- package/catalog/frontmcp-deployment/SKILL.md +152 -0
- package/catalog/frontmcp-deployment/references/build-for-browser.md +143 -0
- package/catalog/frontmcp-deployment/references/build-for-cli.md +191 -0
- package/catalog/{deployment/build-for-sdk/SKILL.md → frontmcp-deployment/references/build-for-sdk.md} +66 -20
- package/catalog/frontmcp-deployment/references/deploy-to-cloudflare.md +218 -0
- package/catalog/{deployment/deploy-to-lambda/SKILL.md → frontmcp-deployment/references/deploy-to-lambda.md} +77 -59
- package/catalog/{deployment/deploy-to-node/references/Dockerfile.example → frontmcp-deployment/references/deploy-to-node-dockerfile.md} +18 -4
- package/catalog/{deployment/deploy-to-node/SKILL.md → frontmcp-deployment/references/deploy-to-node.md} +69 -36
- package/catalog/frontmcp-deployment/references/deploy-to-vercel-config.md +65 -0
- package/catalog/frontmcp-deployment/references/deploy-to-vercel.md +229 -0
- package/catalog/frontmcp-development/SKILL.md +126 -0
- package/catalog/frontmcp-development/references/create-adapter.md +170 -0
- package/catalog/{development/create-agent/references/llm-config.md → frontmcp-development/references/create-agent-llm-config.md} +10 -5
- package/catalog/{development/create-agent/SKILL.md → frontmcp-development/references/create-agent.md} +83 -40
- package/catalog/{development/create-job/SKILL.md → frontmcp-development/references/create-job.md} +62 -15
- package/catalog/{plugins/create-plugin-hooks/SKILL.md → frontmcp-development/references/create-plugin-hooks.md} +100 -7
- package/catalog/frontmcp-development/references/create-plugin.md +506 -0
- package/catalog/{development/create-prompt/SKILL.md → frontmcp-development/references/create-prompt.md} +65 -22
- package/catalog/{development/create-provider/SKILL.md → frontmcp-development/references/create-provider.md} +63 -23
- package/catalog/{development/create-resource/SKILL.md → frontmcp-development/references/create-resource.md} +148 -26
- package/catalog/{development/create-skill-with-tools/SKILL.md → frontmcp-development/references/create-skill-with-tools.md} +174 -20
- package/catalog/{development/create-skill/SKILL.md → frontmcp-development/references/create-skill.md} +114 -28
- package/catalog/{development/create-tool/references/tool-annotations.md → frontmcp-development/references/create-tool-annotations.md} +5 -0
- package/catalog/{development/create-tool/references/output-schema-types.md → frontmcp-development/references/create-tool-output-schema-types.md} +5 -0
- package/catalog/{development/create-tool/SKILL.md → frontmcp-development/references/create-tool.md} +172 -23
- package/catalog/{development/create-workflow/SKILL.md → frontmcp-development/references/create-workflow.md} +61 -14
- package/catalog/frontmcp-development/references/decorators-guide.md +754 -0
- package/catalog/frontmcp-development/references/official-adapters.md +199 -0
- package/catalog/{plugins/official-plugins/SKILL.md → frontmcp-development/references/official-plugins.md} +97 -27
- package/catalog/frontmcp-extensibility/SKILL.md +103 -0
- package/catalog/frontmcp-extensibility/references/vectoriadb.md +289 -0
- package/catalog/frontmcp-guides/SKILL.md +420 -0
- package/catalog/frontmcp-guides/references/example-knowledge-base.md +641 -0
- package/catalog/frontmcp-guides/references/example-task-manager.md +517 -0
- package/catalog/frontmcp-guides/references/example-weather-api.md +297 -0
- package/catalog/frontmcp-production-readiness/SKILL.md +98 -0
- package/catalog/frontmcp-production-readiness/references/common-checklist.md +156 -0
- package/catalog/frontmcp-production-readiness/references/production-browser.md +46 -0
- package/catalog/frontmcp-production-readiness/references/production-cli-binary.md +62 -0
- package/catalog/frontmcp-production-readiness/references/production-cli-daemon.md +61 -0
- package/catalog/frontmcp-production-readiness/references/production-cloudflare.md +52 -0
- package/catalog/frontmcp-production-readiness/references/production-lambda.md +53 -0
- package/catalog/frontmcp-production-readiness/references/production-node-sdk.md +66 -0
- package/catalog/frontmcp-production-readiness/references/production-node-server.md +61 -0
- package/catalog/frontmcp-production-readiness/references/production-vercel.md +52 -0
- package/catalog/frontmcp-setup/SKILL.md +132 -0
- package/catalog/frontmcp-setup/references/frontmcp-skills-usage.md +280 -0
- package/catalog/{setup/multi-app-composition/SKILL.md → frontmcp-setup/references/multi-app-composition.md} +66 -19
- package/catalog/{setup/nx-workflow/SKILL.md → frontmcp-setup/references/nx-workflow.md} +79 -17
- package/catalog/frontmcp-setup/references/project-structure-nx.md +251 -0
- package/catalog/frontmcp-setup/references/project-structure-standalone.md +217 -0
- package/catalog/frontmcp-setup/references/readme-guide.md +226 -0
- package/catalog/{setup/setup-project/SKILL.md → frontmcp-setup/references/setup-project.md} +63 -58
- package/catalog/{setup/setup-redis/SKILL.md → frontmcp-setup/references/setup-redis.md} +60 -82
- package/catalog/{setup/setup-sqlite/SKILL.md → frontmcp-setup/references/setup-sqlite.md} +65 -72
- package/catalog/frontmcp-testing/SKILL.md +135 -0
- package/catalog/{testing/setup-testing/SKILL.md → frontmcp-testing/references/setup-testing.md} +79 -63
- package/catalog/{testing/setup-testing → frontmcp-testing}/references/test-auth.md +5 -0
- package/catalog/{testing/setup-testing → frontmcp-testing}/references/test-browser-build.md +5 -0
- package/catalog/{testing/setup-testing → frontmcp-testing}/references/test-cli-binary.md +5 -0
- package/catalog/{testing/setup-testing → frontmcp-testing}/references/test-direct-client.md +5 -0
- package/catalog/{testing/setup-testing → frontmcp-testing}/references/test-e2e-handler.md +5 -0
- package/catalog/{testing/setup-testing → frontmcp-testing}/references/test-tool-unit.md +6 -0
- package/catalog/skills-manifest.json +337 -382
- 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 +15 -3
- package/src/manifest.js +3 -3
- package/src/manifest.js.map +1 -1
- package/catalog/adapters/create-adapter/SKILL.md +0 -127
- package/catalog/adapters/official-adapters/SKILL.md +0 -136
- package/catalog/auth/configure-auth/SKILL.md +0 -250
- package/catalog/auth/configure-session/SKILL.md +0 -201
- package/catalog/config/configure-elicitation/SKILL.md +0 -136
- package/catalog/config/configure-http/SKILL.md +0 -167
- package/catalog/config/configure-throttle/SKILL.md +0 -189
- package/catalog/config/configure-transport/SKILL.md +0 -151
- package/catalog/deployment/build-for-browser/SKILL.md +0 -95
- package/catalog/deployment/build-for-cli/SKILL.md +0 -100
- package/catalog/deployment/deploy-to-cloudflare/SKILL.md +0 -192
- package/catalog/deployment/deploy-to-vercel/SKILL.md +0 -196
- package/catalog/deployment/deploy-to-vercel/references/vercel.json.example +0 -60
- package/catalog/development/decorators-guide/SKILL.md +0 -598
- package/catalog/plugins/create-plugin/SKILL.md +0 -336
- package/catalog/setup/frontmcp-skills-usage/SKILL.md +0 -200
- package/catalog/setup/project-structure-nx/SKILL.md +0 -186
- package/catalog/setup/project-structure-standalone/SKILL.md +0 -153
|
@@ -1,186 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: project-structure-nx
|
|
3
|
-
description: Best practices for organizing a FrontMCP Nx monorepo -- apps, libs, servers, generators, and multi-app composition. Use when working with frontmcp create --nx or an Nx workspace.
|
|
4
|
-
tags: [project, structure, nx, monorepo, organization, best-practices]
|
|
5
|
-
priority: 8
|
|
6
|
-
visibility: both
|
|
7
|
-
license: Apache-2.0
|
|
8
|
-
metadata:
|
|
9
|
-
docs: https://docs.agentfront.dev/frontmcp/nx-plugin/overview
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
# Nx Monorepo Project Structure
|
|
13
|
-
|
|
14
|
-
When you scaffold with `frontmcp create --nx` or add FrontMCP to an existing Nx workspace, the recommended layout separates apps, shared libraries, and server entry points:
|
|
15
|
-
|
|
16
|
-
```
|
|
17
|
-
my-workspace/
|
|
18
|
-
├── apps/ # @App classes (one app per directory)
|
|
19
|
-
│ ├── billing/
|
|
20
|
-
│ │ ├── src/
|
|
21
|
-
│ │ │ ├── billing.app.ts
|
|
22
|
-
│ │ │ ├── tools/
|
|
23
|
-
│ │ │ ├── resources/
|
|
24
|
-
│ │ │ └── providers/
|
|
25
|
-
│ │ ├── project.json
|
|
26
|
-
│ │ └── tsconfig.json
|
|
27
|
-
│ └── crm/
|
|
28
|
-
│ ├── src/
|
|
29
|
-
│ │ ├── crm.app.ts
|
|
30
|
-
│ │ ├── tools/
|
|
31
|
-
│ │ └── resources/
|
|
32
|
-
│ ├── project.json
|
|
33
|
-
│ └── tsconfig.json
|
|
34
|
-
├── libs/ # Shared libraries
|
|
35
|
-
│ └── shared-utils/
|
|
36
|
-
│ ├── src/
|
|
37
|
-
│ │ └── index.ts
|
|
38
|
-
│ ├── project.json
|
|
39
|
-
│ └── tsconfig.json
|
|
40
|
-
├── servers/ # @FrontMcp servers composing apps
|
|
41
|
-
│ └── gateway/
|
|
42
|
-
│ ├── src/
|
|
43
|
-
│ │ └── main.ts # @FrontMcp default export
|
|
44
|
-
│ ├── project.json
|
|
45
|
-
│ └── tsconfig.json
|
|
46
|
-
├── nx.json
|
|
47
|
-
├── tsconfig.base.json
|
|
48
|
-
├── CLAUDE.md # AI config (auto-generated)
|
|
49
|
-
├── AGENTS.md
|
|
50
|
-
├── .mcp.json
|
|
51
|
-
└── .cursorrules
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
## Directory Roles
|
|
55
|
-
|
|
56
|
-
### apps/ -- Application Modules
|
|
57
|
-
|
|
58
|
-
Each directory under `apps/` contains a single `@App` class with its tools, resources, prompts, providers, and plugins:
|
|
59
|
-
|
|
60
|
-
```typescript
|
|
61
|
-
// apps/billing/src/billing.app.ts
|
|
62
|
-
import { App } from '@frontmcp/sdk';
|
|
63
|
-
import { CreateInvoiceTool } from './tools/create-invoice.tool';
|
|
64
|
-
import { InvoiceResource } from './resources/invoice.resource';
|
|
65
|
-
import { StripeProvider } from './providers/stripe.provider';
|
|
66
|
-
|
|
67
|
-
@App({
|
|
68
|
-
name: 'billing',
|
|
69
|
-
tools: [CreateInvoiceTool],
|
|
70
|
-
resources: [InvoiceResource],
|
|
71
|
-
providers: [StripeProvider],
|
|
72
|
-
})
|
|
73
|
-
export class BillingApp {}
|
|
74
|
-
```
|
|
75
|
-
|
|
76
|
-
Apps are self-contained and independently testable. They do not import from other apps -- shared code goes in `libs/`.
|
|
77
|
-
|
|
78
|
-
### libs/ -- Shared Libraries
|
|
79
|
-
|
|
80
|
-
Shared providers, utilities, types, and common logic live under `libs/`:
|
|
81
|
-
|
|
82
|
-
```typescript
|
|
83
|
-
// libs/shared-utils/src/index.ts
|
|
84
|
-
export { formatCurrency } from './format-currency';
|
|
85
|
-
export { DatabaseProvider } from './database.provider';
|
|
86
|
-
export type { AppConfig } from './app-config.interface';
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
Apps and servers import from libs using Nx path aliases configured in `tsconfig.base.json`:
|
|
90
|
-
|
|
91
|
-
```typescript
|
|
92
|
-
import { DatabaseProvider } from '@my-workspace/shared-utils';
|
|
93
|
-
```
|
|
94
|
-
|
|
95
|
-
### servers/ -- FrontMcp Entry Points
|
|
96
|
-
|
|
97
|
-
A server composes multiple apps into a single `@FrontMcp` entry point:
|
|
98
|
-
|
|
99
|
-
```typescript
|
|
100
|
-
// servers/gateway/src/main.ts
|
|
101
|
-
import { FrontMcp } from '@frontmcp/sdk';
|
|
102
|
-
import { BillingApp } from '@my-workspace/billing';
|
|
103
|
-
import { CrmApp } from '@my-workspace/crm';
|
|
104
|
-
|
|
105
|
-
@FrontMcp({
|
|
106
|
-
info: { name: 'gateway', version: '1.0.0' },
|
|
107
|
-
apps: [BillingApp, CrmApp],
|
|
108
|
-
})
|
|
109
|
-
class GatewayServer {}
|
|
110
|
-
|
|
111
|
-
export default GatewayServer;
|
|
112
|
-
```
|
|
113
|
-
|
|
114
|
-
You can have multiple servers composing different combinations of apps (e.g., a public-facing server and an internal admin server).
|
|
115
|
-
|
|
116
|
-
## Nx Generators
|
|
117
|
-
|
|
118
|
-
The `@frontmcp/nx-plugin` package provides generators for all entity types:
|
|
119
|
-
|
|
120
|
-
```bash
|
|
121
|
-
# Generate a new app
|
|
122
|
-
nx g @frontmcp/nx-plugin:app crm
|
|
123
|
-
|
|
124
|
-
# Generate entities within an app
|
|
125
|
-
nx g @frontmcp/nx-plugin:tool lookup-user --project=crm
|
|
126
|
-
nx g @frontmcp/nx-plugin:resource user-profile --project=crm
|
|
127
|
-
nx g @frontmcp/nx-plugin:prompt summarize --project=crm
|
|
128
|
-
nx g @frontmcp/nx-plugin:provider database --project=crm
|
|
129
|
-
nx g @frontmcp/nx-plugin:plugin logging --project=crm
|
|
130
|
-
nx g @frontmcp/nx-plugin:agent research --project=crm
|
|
131
|
-
nx g @frontmcp/nx-plugin:job cleanup --project=crm
|
|
132
|
-
|
|
133
|
-
# Generate a new server
|
|
134
|
-
nx g @frontmcp/nx-plugin:server gateway
|
|
135
|
-
|
|
136
|
-
# Generate a shared library
|
|
137
|
-
nx g @frontmcp/nx-plugin:lib shared-utils
|
|
138
|
-
```
|
|
139
|
-
|
|
140
|
-
## Build and Test Commands
|
|
141
|
-
|
|
142
|
-
```bash
|
|
143
|
-
# Build a specific server
|
|
144
|
-
nx build gateway
|
|
145
|
-
|
|
146
|
-
# Test a specific app
|
|
147
|
-
nx test billing
|
|
148
|
-
|
|
149
|
-
# Run all tests
|
|
150
|
-
nx run-many -t test
|
|
151
|
-
|
|
152
|
-
# Build all projects
|
|
153
|
-
nx run-many -t build
|
|
154
|
-
|
|
155
|
-
# Lint everything
|
|
156
|
-
nx run-many -t lint
|
|
157
|
-
```
|
|
158
|
-
|
|
159
|
-
Nx caches build and test results. Subsequent runs for unchanged projects are instant.
|
|
160
|
-
|
|
161
|
-
## AI Configuration Files
|
|
162
|
-
|
|
163
|
-
FrontMCP auto-generates AI configuration files at the workspace root:
|
|
164
|
-
|
|
165
|
-
| File | Purpose |
|
|
166
|
-
| -------------- | ---------------------------------------- |
|
|
167
|
-
| `CLAUDE.md` | Instructions for Claude Code / Claude AI |
|
|
168
|
-
| `AGENTS.md` | Instructions for agent-based AI tools |
|
|
169
|
-
| `.mcp.json` | MCP server configuration for AI IDEs |
|
|
170
|
-
| `.cursorrules` | Rules for Cursor AI editor |
|
|
171
|
-
|
|
172
|
-
These files are regenerated when you run generators or modify your workspace structure. They help AI tools understand your project layout and coding conventions.
|
|
173
|
-
|
|
174
|
-
## Dependency Graph
|
|
175
|
-
|
|
176
|
-
Nx enforces a clear dependency hierarchy:
|
|
177
|
-
|
|
178
|
-
```
|
|
179
|
-
servers/ --> apps/ --> libs/
|
|
180
|
-
```
|
|
181
|
-
|
|
182
|
-
- **servers** can import from **apps** and **libs**
|
|
183
|
-
- **apps** can import from **libs** only (never from other apps or servers)
|
|
184
|
-
- **libs** can import from other **libs** only
|
|
185
|
-
|
|
186
|
-
Use `nx graph` to visualize the dependency graph and ensure no circular imports exist.
|
|
@@ -1,153 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: project-structure-standalone
|
|
3
|
-
description: Best practices for organizing a standalone FrontMCP project -- file layout, naming conventions, and folder hierarchy. Use when scaffolding with frontmcp create or organizing an existing standalone project.
|
|
4
|
-
tags: [project, structure, standalone, organization, best-practices]
|
|
5
|
-
priority: 8
|
|
6
|
-
visibility: both
|
|
7
|
-
license: Apache-2.0
|
|
8
|
-
metadata:
|
|
9
|
-
docs: https://docs.agentfront.dev/frontmcp/getting-started/quickstart
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
# Standalone Project Structure
|
|
13
|
-
|
|
14
|
-
When you run `frontmcp create`, the CLI scaffolds a standalone project with the following layout:
|
|
15
|
-
|
|
16
|
-
```
|
|
17
|
-
my-project/
|
|
18
|
-
├── src/
|
|
19
|
-
│ ├── main.ts # @FrontMcp server entry (default export)
|
|
20
|
-
│ ├── my-app.app.ts # @App class
|
|
21
|
-
│ ├── tools/ # @Tool classes (*.tool.ts)
|
|
22
|
-
│ ├── resources/ # @Resource classes (*.resource.ts)
|
|
23
|
-
│ ├── prompts/ # @Prompt classes (*.prompt.ts)
|
|
24
|
-
│ ├── agents/ # @Agent classes (*.agent.ts)
|
|
25
|
-
│ ├── skills/ # @Skill classes or SKILL.md dirs
|
|
26
|
-
│ ├── providers/ # @Provider classes (*.provider.ts)
|
|
27
|
-
│ ├── plugins/ # @Plugin classes (*.plugin.ts)
|
|
28
|
-
│ └── jobs/ # @Job classes (*.job.ts)
|
|
29
|
-
├── e2e/ # E2E tests (*.e2e.spec.ts)
|
|
30
|
-
├── skills/ # Catalog skills (from --skills flag)
|
|
31
|
-
├── package.json
|
|
32
|
-
├── tsconfig.json
|
|
33
|
-
└── .env.example
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
## File Naming Conventions
|
|
37
|
-
|
|
38
|
-
Every entity type uses a consistent `<name>.<type>.ts` pattern:
|
|
39
|
-
|
|
40
|
-
| Entity | File Pattern | Example |
|
|
41
|
-
| -------- | --------------- | ---------------------------- |
|
|
42
|
-
| Tool | `*.tool.ts` | `fetch-weather.tool.ts` |
|
|
43
|
-
| Resource | `*.resource.ts` | `user-profile.resource.ts` |
|
|
44
|
-
| Prompt | `*.prompt.ts` | `summarize.prompt.ts` |
|
|
45
|
-
| Agent | `*.agent.ts` | `research.agent.ts` |
|
|
46
|
-
| Skill | `*.skill.ts` | `calendar.skill.ts` |
|
|
47
|
-
| Provider | `*.provider.ts` | `database.provider.ts` |
|
|
48
|
-
| Plugin | `*.plugin.ts` | `logging.plugin.ts` |
|
|
49
|
-
| Job | `*.job.ts` | `cleanup.job.ts` |
|
|
50
|
-
| Test | `*.spec.ts` | `fetch-weather.tool.spec.ts` |
|
|
51
|
-
| E2E Test | `*.e2e.spec.ts` | `api.e2e.spec.ts` |
|
|
52
|
-
|
|
53
|
-
**One class per file.** Keep each tool, resource, prompt, etc. in its own file.
|
|
54
|
-
|
|
55
|
-
## Entry Point: main.ts
|
|
56
|
-
|
|
57
|
-
`main.ts` default-exports the `@FrontMcp` server class. This is the file FrontMCP loads at startup:
|
|
58
|
-
|
|
59
|
-
```typescript
|
|
60
|
-
import { FrontMcp } from '@frontmcp/sdk';
|
|
61
|
-
import { MyApp } from './my-app.app';
|
|
62
|
-
|
|
63
|
-
@FrontMcp({
|
|
64
|
-
info: { name: 'my-project', version: '1.0.0' },
|
|
65
|
-
apps: [MyApp],
|
|
66
|
-
})
|
|
67
|
-
class MyServer {}
|
|
68
|
-
|
|
69
|
-
export default MyServer;
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
## App Class
|
|
73
|
-
|
|
74
|
-
The `@App` class groups tools, resources, prompts, plugins, and providers together:
|
|
75
|
-
|
|
76
|
-
```typescript
|
|
77
|
-
import { App } from '@frontmcp/sdk';
|
|
78
|
-
import { FetchWeatherTool } from './tools/fetch-weather.tool';
|
|
79
|
-
import { DatabaseProvider } from './providers/database.provider';
|
|
80
|
-
|
|
81
|
-
@App({
|
|
82
|
-
name: 'my-app',
|
|
83
|
-
tools: [FetchWeatherTool],
|
|
84
|
-
providers: [DatabaseProvider],
|
|
85
|
-
})
|
|
86
|
-
export class MyApp {}
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
## Development Workflow
|
|
90
|
-
|
|
91
|
-
### Start development server
|
|
92
|
-
|
|
93
|
-
```bash
|
|
94
|
-
frontmcp dev
|
|
95
|
-
```
|
|
96
|
-
|
|
97
|
-
Watches for file changes and restarts automatically.
|
|
98
|
-
|
|
99
|
-
### Build for production
|
|
100
|
-
|
|
101
|
-
```bash
|
|
102
|
-
frontmcp build --target node
|
|
103
|
-
frontmcp build --target bun
|
|
104
|
-
frontmcp build --target cloudflare-workers
|
|
105
|
-
```
|
|
106
|
-
|
|
107
|
-
The `--target` flag determines the output format and runtime optimizations.
|
|
108
|
-
|
|
109
|
-
### Run tests
|
|
110
|
-
|
|
111
|
-
```bash
|
|
112
|
-
# Unit tests
|
|
113
|
-
jest
|
|
114
|
-
|
|
115
|
-
# E2E tests
|
|
116
|
-
jest --config e2e/jest.config.ts
|
|
117
|
-
```
|
|
118
|
-
|
|
119
|
-
## Organizing by Feature
|
|
120
|
-
|
|
121
|
-
For larger standalone projects, group related entities into feature folders:
|
|
122
|
-
|
|
123
|
-
```
|
|
124
|
-
src/
|
|
125
|
-
├── main.ts
|
|
126
|
-
├── my-app.app.ts
|
|
127
|
-
├── billing/
|
|
128
|
-
│ ├── create-invoice.tool.ts
|
|
129
|
-
│ ├── invoice.resource.ts
|
|
130
|
-
│ └── billing.provider.ts
|
|
131
|
-
├── users/
|
|
132
|
-
│ ├── lookup-user.tool.ts
|
|
133
|
-
│ ├── user-profile.resource.ts
|
|
134
|
-
│ └── users.provider.ts
|
|
135
|
-
└── plugins/
|
|
136
|
-
└── logging.plugin.ts
|
|
137
|
-
```
|
|
138
|
-
|
|
139
|
-
Feature folders work well when your project has multiple related tools and resources that share a domain.
|
|
140
|
-
|
|
141
|
-
## Skills Directory
|
|
142
|
-
|
|
143
|
-
The top-level `skills/` directory (outside `src/`) holds catalog skills added via the `--skills` flag during `frontmcp create`. Each skill is a folder containing a `SKILL.md` file:
|
|
144
|
-
|
|
145
|
-
```
|
|
146
|
-
skills/
|
|
147
|
-
├── create-tool/
|
|
148
|
-
│ └── SKILL.md
|
|
149
|
-
└── setup-project/
|
|
150
|
-
└── SKILL.md
|
|
151
|
-
```
|
|
152
|
-
|
|
153
|
-
Skills inside `src/skills/` are `@Skill` classes that are part of your application code.
|