@respira/wordpress-mcp-server 2.0.10 → 2.2.1
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 +43 -4
- package/dist/divi-context.d.ts +2 -2
- package/dist/divi-context.d.ts.map +1 -1
- package/dist/divi-context.js +31 -85
- package/dist/divi-context.js.map +1 -1
- package/dist/divi-prompts.d.ts +7 -0
- package/dist/divi-prompts.d.ts.map +1 -1
- package/dist/divi-prompts.js +57 -29
- package/dist/divi-prompts.js.map +1 -1
- package/dist/index.d.ts +5 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +20 -0
- package/dist/index.js.map +1 -1
- package/dist/server.d.ts +2 -0
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +228 -13
- package/dist/server.js.map +1 -1
- package/dist/types/index.d.ts +20 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/wordpress-client.d.ts +27 -1
- package/dist/wordpress-client.d.ts.map +1 -1
- package/dist/wordpress-client.js +154 -2
- package/dist/wordpress-client.js.map +1 -1
- package/package.json +11 -4
package/README.md
CHANGED
|
@@ -8,14 +8,16 @@
|
|
|
8
8
|
|
|
9
9
|
<p align="center">
|
|
10
10
|
<strong>The only WordPress MCP with page builder support.</strong><br>
|
|
11
|
-
Edit Divi, Elementor, Bricks &
|
|
11
|
+
Edit Divi, Elementor, Bricks & 8 more builders with Cursor, Claude Code & Windsurf.<br>
|
|
12
|
+
Add WooCommerce add-on abilities for products, orders, inventory, coupons, and sales reports.
|
|
12
13
|
</p>
|
|
13
14
|
|
|
14
15
|
<p align="center">
|
|
15
16
|
<a href="https://www.npmjs.com/package/@respira/wordpress-mcp-server"><img src="https://img.shields.io/npm/v/@respira/wordpress-mcp-server.svg?style=flat-square&color=blue" alt="npm version"></a>
|
|
16
17
|
<a href="https://www.npmjs.com/package/@respira/wordpress-mcp-server"><img src="https://img.shields.io/npm/dm/@respira/wordpress-mcp-server.svg?style=flat-square" alt="npm downloads"></a>
|
|
17
|
-
<img src="https://img.shields.io/badge/page%20builders-
|
|
18
|
+
<img src="https://img.shields.io/badge/page%20builders-11-green?style=flat-square" alt="11 Page Builders">
|
|
18
19
|
<img src="https://img.shields.io/badge/tools-60%2B-purple?style=flat-square" alt="60+ Tools">
|
|
20
|
+
<img src="https://img.shields.io/badge/WooCommerce%20add--on-20%2B%20tools-7F54B3?style=flat-square" alt="WooCommerce add-on tools">
|
|
19
21
|
<img src="https://img.shields.io/badge/TypeScript-100%25-blue?style=flat-square&logo=typescript&logoColor=white" alt="TypeScript">
|
|
20
22
|
<a href="https://respira.press"><img src="https://img.shields.io/badge/website-respira.press-orange?style=flat-square" alt="Website"></a>
|
|
21
23
|
</p>
|
|
@@ -37,7 +39,7 @@
|
|
|
37
39
|
|
|
38
40
|
| Feature | Respira | Other MCP Servers |
|
|
39
41
|
|---------|---------|-------------------|
|
|
40
|
-
| **Page Builder Support** |
|
|
42
|
+
| **Page Builder Support** | 11 builders | None |
|
|
41
43
|
| Edit Divi modules | 200+ module types | - |
|
|
42
44
|
| Edit Elementor widgets | Full support | - |
|
|
43
45
|
| Edit Bricks elements | Full support | - |
|
|
@@ -54,6 +56,11 @@
|
|
|
54
56
|
| **Multilingual** | | |
|
|
55
57
|
| WPML support | Yes | No |
|
|
56
58
|
| Menu translations | Yes | No |
|
|
59
|
+
| **WooCommerce Add-on** | | |
|
|
60
|
+
| Product management tools | Yes (add-on) | No |
|
|
61
|
+
| Order status and operations | Yes (add-on) | No |
|
|
62
|
+
| Inventory and stock tools | Yes (add-on) | No |
|
|
63
|
+
| Sales reports and coupons | Yes (add-on) | No |
|
|
57
64
|
|
|
58
65
|
### Supported Page Builders
|
|
59
66
|
|
|
@@ -75,6 +82,18 @@
|
|
|
75
82
|
- **Brizy** - Blocks and elements
|
|
76
83
|
- **Thrive Architect** - Elements and templates
|
|
77
84
|
|
|
85
|
+
### WooCommerce Add-on Abilities
|
|
86
|
+
|
|
87
|
+
Respira MCP can expose WooCommerce tools when the WooCommerce add-on is installed and licensed:
|
|
88
|
+
|
|
89
|
+
- Product operations: list/get/create/update/duplicate, variations, categories
|
|
90
|
+
- Order operations: list/get/update status, safe order updates
|
|
91
|
+
- Inventory operations: stock status overview, stock quantity updates
|
|
92
|
+
- Commerce operations: coupons, customers, sales reports
|
|
93
|
+
- Add-on gating: tools auto-register only when add-on is active + licensed
|
|
94
|
+
|
|
95
|
+
WooCommerce add-on details: [respira.press/addons/woocommerce](https://respira.press/addons/woocommerce)
|
|
96
|
+
|
|
78
97
|
---
|
|
79
98
|
|
|
80
99
|
## Quick Start (3 Minutes)
|
|
@@ -185,6 +204,15 @@ Unlike other MCP servers that edit live pages directly, Respira:
|
|
|
185
204
|
2. **Preserves the original** untouched
|
|
186
205
|
3. **Lets you preview** changes before going live
|
|
187
206
|
4. **Approve in WordPress** when ready
|
|
207
|
+
5. **Returns the approvals URL** in mutation responses (`respira_approvals_url`) so assistants can direct users to:
|
|
208
|
+
`https://your-site.com/wp-admin/admin.php?page=respira-approvals`
|
|
209
|
+
|
|
210
|
+
### Divi Safety Contract
|
|
211
|
+
|
|
212
|
+
- Every `wordpress_inject_builder_content` call for `builder=\"divi\"` must include `diviVersion`:
|
|
213
|
+
- `\"4\"` for Divi 4 shortcode format
|
|
214
|
+
- `\"5\"` for Divi 5 block format
|
|
215
|
+
- If omitted, MCP returns a confirmation-required response instead of injecting.
|
|
188
216
|
|
|
189
217
|
Your live site is never at risk.
|
|
190
218
|
|
|
@@ -220,7 +248,7 @@ wp mcp-adapter serve respira-press --user=admin
|
|
|
220
248
|
|
|
221
249
|
---
|
|
222
250
|
|
|
223
|
-
## 60+ Tools
|
|
251
|
+
## 60+ Core Tools + WooCommerce Add-on Tools
|
|
224
252
|
|
|
225
253
|
### Page Builder Tools
|
|
226
254
|
| Tool | What it does |
|
|
@@ -256,6 +284,17 @@ wp mcp-adapter serve respira-press --user=admin
|
|
|
256
284
|
| `wordpress_analyze_aeo` | AI search engine optimization check |
|
|
257
285
|
| `wordpress_analyze_readability` | Flesch score, sentence analysis |
|
|
258
286
|
|
|
287
|
+
### WooCommerce Add-on Tools (License-gated)
|
|
288
|
+
| Tool | What it does |
|
|
289
|
+
|------|-------------|
|
|
290
|
+
| `woocommerce_list_products` / `woocommerce_get_product` | Browse and inspect products |
|
|
291
|
+
| `woocommerce_create_product` / `woocommerce_update_product` | Create and update products |
|
|
292
|
+
| `woocommerce_duplicate_product` | Duplicate products safely before edits |
|
|
293
|
+
| `woocommerce_list_orders` / `woocommerce_get_order` | List and inspect orders |
|
|
294
|
+
| `woocommerce_update_order_status` | Update order status with WooCommerce flows |
|
|
295
|
+
| `woocommerce_get_stock_status` / `woocommerce_update_stock` | Inventory and stock management |
|
|
296
|
+
| `woocommerce_sales_report` | Sales analytics and reporting |
|
|
297
|
+
|
|
259
298
|
### Media, Users, Taxonomies, Plugins
|
|
260
299
|
|
|
261
300
|
Full CRUD operations for all WordPress content types.
|
package/dist/divi-context.d.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Provides comprehensive Divi documentation for AI assistants.
|
|
5
5
|
*/
|
|
6
|
-
export declare const diviContext = "\nYou are editing a Divi Builder page. Divi
|
|
6
|
+
export declare const diviContext = "\nYou are editing a Divi Builder page. Divi has two storage formats you must handle safely:\n- Divi 5: block-based layout using `divi/*` blocks in post content\n- Divi 4: legacy shortcode layout using `et_pb_*`\n\n## Divi 5 Structure (Primary)\n\n- **Sections (`divi/section`)**: Top-level containers\n- **Rows (`divi/row`)**: Layout containers inside sections\n- **Columns/Groups (`divi/column`, `divi/group`)**: Nested containers\n- **Modules (`divi/*`)**: Text, button, image, CTA, and other content blocks\n\n## Divi 4 Structure (Legacy)\n\n- **Sections (`et_pb_section`)**\n- **Rows (`et_pb_row`)**\n- **Modules (`et_pb_text`, `et_pb_image`, `et_pb_button`, etc.)**\n\n## Editing Contract\n\n- Use structured nodes: `{ type, attributes, children, content }`\n- Preserve unknown attributes exactly\n- Do not rewrite entire trees for small edits\n- Keep non-Divi blocks and legacy shortcode wrapper blocks unless explicitly asked to remove\n- Treat legacy wrappers as opaque: move/delete allowed, deep edits discouraged\n\n## Important Rules\n\n1. Prefer Divi 5 block edits (`divi/*`) when present\n2. Keep Divi 4 shortcode edits only for legacy pages\n3. Preserve parent/child nesting and ordering\n4. Preserve all existing attributes unless explicitly changed\n5. Use hex colors and full URLs where relevant\n6. Avoid lossy conversion between Divi 4 and Divi 5 formats\n7. For every Divi inject operation, ask for explicit confirmation: Divi 4 or Divi 5\n";
|
|
7
7
|
export declare const diviAttributeHelp: {
|
|
8
8
|
colors: string;
|
|
9
9
|
spacing: string;
|
|
@@ -11,5 +11,5 @@ export declare const diviAttributeHelp: {
|
|
|
11
11
|
fonts: string;
|
|
12
12
|
urls: string;
|
|
13
13
|
};
|
|
14
|
-
export declare const diviValidationRules = "\nCRITICAL Divi Rules:\n1.
|
|
14
|
+
export declare const diviValidationRules = "\nCRITICAL Divi Rules:\n1. If Divi 5 blocks exist, keep output in block format (`divi/*`)\n2. Preserve `attributes` and `children` unless explicitly changed\n3. Keep legacy shortcode-wrapper blocks opaque\n4. Never overwrite a Divi 5 page with Divi 4 shortcodes\n5. Preserve module structure and ordering\n6. Always use proper attribute formats\n7. Ask user to confirm Divi 4 vs Divi 5 before every Divi inject\n";
|
|
15
15
|
//# sourceMappingURL=divi-context.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"divi-context.d.ts","sourceRoot":"","sources":["../src/divi-context.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,eAAO,MAAM,WAAW,
|
|
1
|
+
{"version":3,"file":"divi-context.d.ts","sourceRoot":"","sources":["../src/divi-context.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,eAAO,MAAM,WAAW,y7CAmCvB,CAAC;AAEF,eAAO,MAAM,iBAAiB;;;;;;CAM7B,CAAC;AAEF,eAAO,MAAM,mBAAmB,iaAS/B,CAAC"}
|
package/dist/divi-context.js
CHANGED
|
@@ -4,95 +4,40 @@
|
|
|
4
4
|
* Provides comprehensive Divi documentation for AI assistants.
|
|
5
5
|
*/
|
|
6
6
|
export const diviContext = `
|
|
7
|
-
You are editing a Divi Builder page. Divi
|
|
7
|
+
You are editing a Divi Builder page. Divi has two storage formats you must handle safely:
|
|
8
|
+
- Divi 5: block-based layout using \`divi/*\` blocks in post content
|
|
9
|
+
- Divi 4: legacy shortcode layout using \`et_pb_*\`
|
|
8
10
|
|
|
9
|
-
## Divi Structure
|
|
11
|
+
## Divi 5 Structure (Primary)
|
|
10
12
|
|
|
11
|
-
- **Sections (
|
|
12
|
-
- **Rows (
|
|
13
|
-
- **
|
|
13
|
+
- **Sections (\`divi/section\`)**: Top-level containers
|
|
14
|
+
- **Rows (\`divi/row\`)**: Layout containers inside sections
|
|
15
|
+
- **Columns/Groups (\`divi/column\`, \`divi/group\`)**: Nested containers
|
|
16
|
+
- **Modules (\`divi/*\`)**: Text, button, image, CTA, and other content blocks
|
|
14
17
|
|
|
15
|
-
##
|
|
18
|
+
## Divi 4 Structure (Legacy)
|
|
16
19
|
|
|
17
|
-
|
|
18
|
-
- **
|
|
19
|
-
- **
|
|
20
|
+
- **Sections (\`et_pb_section\`)**
|
|
21
|
+
- **Rows (\`et_pb_row\`)**
|
|
22
|
+
- **Modules (\`et_pb_text\`, \`et_pb_image\`, \`et_pb_button\`, etc.)**
|
|
20
23
|
|
|
21
|
-
|
|
22
|
-
- **et_pb_text**: Text content module for paragraphs and headings
|
|
23
|
-
- Attributes: content (HTML), text_color (hex), background_color (hex), font_size (px/em)
|
|
24
|
-
- **et_pb_image**: Image module
|
|
25
|
-
- Attributes: src (URL), alt (text), url (link URL), align (left/center/right)
|
|
26
|
-
- **et_pb_button**: Button module
|
|
27
|
-
- Attributes: button_text (text), button_url (URL), button_alignment (left/center/right), button_bg_color (hex)
|
|
28
|
-
- **et_pb_cta**: Call to action module with heading, text, and button
|
|
29
|
-
- Attributes: title (text), content (HTML), button_text (text), button_url (URL)
|
|
30
|
-
- **et_pb_blurb**: Icon with text module
|
|
31
|
-
- Attributes: title (text), content (HTML), image (URL), url (link URL)
|
|
32
|
-
- **et_pb_video**: Video module
|
|
33
|
-
- Attributes: src (URL - YouTube, Vimeo, or direct video), image_src (thumbnail URL)
|
|
34
|
-
- **et_pb_html_content**: Custom HTML content module (supports scripts)
|
|
35
|
-
- Attributes: content (HTML - can include scripts)
|
|
36
|
-
- **et_pb_code**: Custom HTML/CSS/JS module
|
|
37
|
-
- Attributes: content (base64 encoded)
|
|
24
|
+
## Editing Contract
|
|
38
25
|
|
|
39
|
-
|
|
40
|
-
-
|
|
41
|
-
-
|
|
42
|
-
-
|
|
43
|
-
-
|
|
44
|
-
- **et_pb_contact_form**: Contact form
|
|
45
|
-
- **et_pb_gallery**: Image gallery
|
|
46
|
-
- **et_pb_accordion**: Accordion/toggle content
|
|
47
|
-
- **et_pb_tabs**: Tabbed content
|
|
48
|
-
- **et_pb_blog**: Blog posts display
|
|
49
|
-
- **et_pb_portfolio**: Portfolio display
|
|
50
|
-
|
|
51
|
-
## Common Attributes (Available on Most Modules)
|
|
52
|
-
|
|
53
|
-
- **admin_label**: Label shown in builder for identification
|
|
54
|
-
- **module_id**: Unique CSS ID for the module
|
|
55
|
-
- **module_class**: Custom CSS class
|
|
56
|
-
- **disabled_on**: Hide module on devices (format: "off|off|off" for desktop|tablet|phone)
|
|
57
|
-
- **custom_css**: Custom CSS for this module
|
|
58
|
-
- **background_color**: Background color (hex format: #FFFFFF)
|
|
59
|
-
- **text_color**: Text color (hex format: #000000)
|
|
60
|
-
- **padding**: Padding (format: "10px|20px|10px|20px" for top|right|bottom|left)
|
|
61
|
-
- **margin**: Margin (same format as padding)
|
|
62
|
-
|
|
63
|
-
## Format Specifications
|
|
64
|
-
|
|
65
|
-
- **Colors**: Always use hex format (e.g., #0000FF for blue, #FFFFFF for white)
|
|
66
|
-
- **Spacing**: Use format "10px|20px|10px|20px" (top|right|bottom|left)
|
|
67
|
-
- **Sizing**: Use px, em, rem, %, or vw units
|
|
68
|
-
- **Fonts**: Font names from Google Fonts or system fonts
|
|
69
|
-
- **URLs**: Full URLs including https://
|
|
70
|
-
|
|
71
|
-
## Common Tasks
|
|
72
|
-
|
|
73
|
-
### Change Text Color
|
|
74
|
-
Find the et_pb_text module and modify its text_color attribute to the desired hex color.
|
|
75
|
-
|
|
76
|
-
### Update Heading
|
|
77
|
-
Find the et_pb_text module containing the heading and modify its content attribute.
|
|
78
|
-
|
|
79
|
-
### Add Button
|
|
80
|
-
Create an et_pb_button module with button_text and button_url attributes.
|
|
81
|
-
|
|
82
|
-
### Change Background Color
|
|
83
|
-
Modify the background_color attribute of the section, row, or module.
|
|
84
|
-
|
|
85
|
-
### Update Image
|
|
86
|
-
Find the et_pb_image module and modify its src attribute to the new image URL.
|
|
26
|
+
- Use structured nodes: \`{ type, attributes, children, content }\`
|
|
27
|
+
- Preserve unknown attributes exactly
|
|
28
|
+
- Do not rewrite entire trees for small edits
|
|
29
|
+
- Keep non-Divi blocks and legacy shortcode wrapper blocks unless explicitly asked to remove
|
|
30
|
+
- Treat legacy wrappers as opaque: move/delete allowed, deep edits discouraged
|
|
87
31
|
|
|
88
32
|
## Important Rules
|
|
89
33
|
|
|
90
|
-
1.
|
|
91
|
-
2.
|
|
92
|
-
3.
|
|
93
|
-
4.
|
|
94
|
-
5.
|
|
95
|
-
6.
|
|
34
|
+
1. Prefer Divi 5 block edits (\`divi/*\`) when present
|
|
35
|
+
2. Keep Divi 4 shortcode edits only for legacy pages
|
|
36
|
+
3. Preserve parent/child nesting and ordering
|
|
37
|
+
4. Preserve all existing attributes unless explicitly changed
|
|
38
|
+
5. Use hex colors and full URLs where relevant
|
|
39
|
+
6. Avoid lossy conversion between Divi 4 and Divi 5 formats
|
|
40
|
+
7. For every Divi inject operation, ask for explicit confirmation: Divi 4 or Divi 5
|
|
96
41
|
`;
|
|
97
42
|
export const diviAttributeHelp = {
|
|
98
43
|
colors: 'Use hex format: #0000FF (no rgb() or color names)',
|
|
@@ -103,11 +48,12 @@ export const diviAttributeHelp = {
|
|
|
103
48
|
};
|
|
104
49
|
export const diviValidationRules = `
|
|
105
50
|
CRITICAL Divi Rules:
|
|
106
|
-
1.
|
|
107
|
-
2.
|
|
108
|
-
3.
|
|
109
|
-
4.
|
|
110
|
-
5. Preserve module structure
|
|
51
|
+
1. If Divi 5 blocks exist, keep output in block format (\`divi/*\`)
|
|
52
|
+
2. Preserve \`attributes\` and \`children\` unless explicitly changed
|
|
53
|
+
3. Keep legacy shortcode-wrapper blocks opaque
|
|
54
|
+
4. Never overwrite a Divi 5 page with Divi 4 shortcodes
|
|
55
|
+
5. Preserve module structure and ordering
|
|
111
56
|
6. Always use proper attribute formats
|
|
57
|
+
7. Ask user to confirm Divi 4 vs Divi 5 before every Divi inject
|
|
112
58
|
`;
|
|
113
59
|
//# sourceMappingURL=divi-context.js.map
|
package/dist/divi-context.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"divi-context.js","sourceRoot":"","sources":["../src/divi-context.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,MAAM,CAAC,MAAM,WAAW,GAAG
|
|
1
|
+
{"version":3,"file":"divi-context.js","sourceRoot":"","sources":["../src/divi-context.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,MAAM,CAAC,MAAM,WAAW,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmC1B,CAAC;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAG;IAC/B,MAAM,EAAE,mDAAmD;IAC3D,OAAO,EAAE,yDAAyD;IAClE,MAAM,EAAE,iCAAiC;IACzC,KAAK,EAAE,8CAA8C;IACrD,IAAI,EAAE,uCAAuC;CAC9C,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAG;;;;;;;;;CASlC,CAAC"}
|
package/dist/divi-prompts.d.ts
CHANGED
|
@@ -8,6 +8,13 @@ export interface DiviPrompt {
|
|
|
8
8
|
description: string;
|
|
9
9
|
template: string;
|
|
10
10
|
}
|
|
11
|
+
export declare const diviInjectPolicy = "\nBefore calling wordpress_inject_builder_content with builder=\"divi\", always set diviVersion explicitly:\n- \"4\" for Divi 4 shortcode format\n- \"5\" for Divi 5 block format\n";
|
|
12
|
+
export declare const diviMigrationCopilotDisclaimer = "Respira helps you plan and validate your Divi 5 migration. Divi\u2019s Migrator performs the actual conversion.";
|
|
13
|
+
export declare const diviMigrationCopilotPrompts: {
|
|
14
|
+
id: string;
|
|
15
|
+
title: string;
|
|
16
|
+
prompt: string;
|
|
17
|
+
}[];
|
|
11
18
|
export declare const diviPrompts: Record<string, DiviPrompt>;
|
|
12
19
|
export declare const diviCommonAttributes: string[];
|
|
13
20
|
export declare function getDiviPrompt(name: string): DiviPrompt | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"divi-prompts.d.ts","sourceRoot":"","sources":["../src/divi-prompts.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,eAAO,MAAM,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,UAAU,
|
|
1
|
+
{"version":3,"file":"divi-prompts.d.ts","sourceRoot":"","sources":["../src/divi-prompts.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,eAAO,MAAM,gBAAgB,wLAI5B,CAAC;AAEF,eAAO,MAAM,8BAA8B,oHACmE,CAAC;AAE/G,eAAO,MAAM,2BAA2B;;;;GA0BvC,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,UAAU,CAmFlD,CAAC;AAEF,eAAO,MAAM,oBAAoB,UAShC,CAAC;AAEF,wBAAgB,aAAa,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAElE;AAED,wBAAgB,gBAAgB,CAC9B,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAChC,MAAM,CAYR"}
|
package/dist/divi-prompts.js
CHANGED
|
@@ -3,26 +3,58 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Pre-built prompt expansions for common Divi editing tasks.
|
|
5
5
|
*/
|
|
6
|
+
export const diviInjectPolicy = `
|
|
7
|
+
Before calling wordpress_inject_builder_content with builder="divi", always set diviVersion explicitly:
|
|
8
|
+
- "4" for Divi 4 shortcode format
|
|
9
|
+
- "5" for Divi 5 block format
|
|
10
|
+
`;
|
|
11
|
+
export const diviMigrationCopilotDisclaimer = 'Respira helps you plan and validate your Divi 5 migration. Divi’s Migrator performs the actual conversion.';
|
|
12
|
+
export const diviMigrationCopilotPrompts = [
|
|
13
|
+
{
|
|
14
|
+
id: 'readiness_audit',
|
|
15
|
+
title: 'Migration readiness audit',
|
|
16
|
+
prompt: `Inventory all Divi pages/templates, identify Divi 4 vs Divi 5 vs mixed structures, and score migration risk by page. Include third-party module risk notes.\n\nDivi’s Migrator performs conversion. This plan helps you run it safely.`,
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
id: 'staging_backup_plan',
|
|
20
|
+
title: 'Staging + backup plan',
|
|
21
|
+
prompt: `Create an ordered staging migration runbook with backup checkpoints, rollback criteria, owner assignments, and sign-off gates.\n\nDivi’s Migrator performs conversion. This plan helps you run it safely.`,
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
id: 'compatibility_cleanup',
|
|
25
|
+
title: 'Compatibility Mode cleanup',
|
|
26
|
+
prompt: `Identify likely compatibility-mode pages, prioritize legacy module replacement, and propose performance-focused cleanup milestones.\n\nDivi’s Migrator performs conversion. This plan helps you run it safely.`,
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
id: 'post_migration_qa',
|
|
30
|
+
title: 'Post-migration QA',
|
|
31
|
+
prompt: `Generate a QA checklist for Divi Visual Builder open tests, frontend diffs, CSS regressions, and a clear definition of done.\n\nDivi’s Migrator performs conversion. This plan helps you run it safely.`,
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
id: 'modernize_layout',
|
|
35
|
+
title: 'Modernize this layout',
|
|
36
|
+
prompt: `For a selected migrated page, propose a modernization plan that replaces legacy islands with native Divi 5 modules where feasible while preserving design intent.\n\nDivi’s Migrator performs conversion. This plan helps you run it safely.`,
|
|
37
|
+
},
|
|
38
|
+
];
|
|
6
39
|
export const diviPrompts = {
|
|
7
40
|
createHeroSection: {
|
|
8
41
|
name: 'create_divi_hero',
|
|
9
|
-
description: 'Create a Divi hero section
|
|
10
|
-
template: `Create a Divi
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
[/et_pb_section]`,
|
|
42
|
+
description: 'Create a Divi hero section using structured nodes',
|
|
43
|
+
template: `Create a Divi 5 hero structure (or Divi 4 equivalent on legacy pages) using node format:
|
|
44
|
+
{
|
|
45
|
+
type: "divi/section",
|
|
46
|
+
attributes: { background_color: "{bg_color}", background_image: "{bg_url}" },
|
|
47
|
+
children: [
|
|
48
|
+
{
|
|
49
|
+
type: "divi/row",
|
|
50
|
+
attributes: {},
|
|
51
|
+
children: [
|
|
52
|
+
{ type: "divi/text", attributes: { text_orientation: "center" }, content: "<h1>{heading}</h1><p>{subheading}</p>" },
|
|
53
|
+
{ type: "divi/button", attributes: { button_url: "{url}", button_text: "{text}", button_alignment: "center" }, content: "" }
|
|
54
|
+
]
|
|
55
|
+
}
|
|
56
|
+
]
|
|
57
|
+
}`,
|
|
26
58
|
},
|
|
27
59
|
updateModuleStyle: {
|
|
28
60
|
name: 'update_divi_style',
|
|
@@ -38,8 +70,8 @@ Example: To make text blue, set text_color="#0000FF"`,
|
|
|
38
70
|
},
|
|
39
71
|
updateTextContent: {
|
|
40
72
|
name: 'update_divi_text',
|
|
41
|
-
description: 'Update text content in a Divi text
|
|
42
|
-
template: `Find the et_pb_text
|
|
73
|
+
description: 'Update text content in a Divi text node',
|
|
74
|
+
template: `Find the text node (Divi 5: divi/text, Divi 4: et_pb_text) and modify only its content field.
|
|
43
75
|
Content can include HTML tags like <h1>, <p>, <strong>, <em>, etc.
|
|
44
76
|
|
|
45
77
|
Example:
|
|
@@ -48,30 +80,26 @@ Example:
|
|
|
48
80
|
},
|
|
49
81
|
addButton: {
|
|
50
82
|
name: 'add_divi_button',
|
|
51
|
-
description: 'Add a button
|
|
52
|
-
template: `Create
|
|
83
|
+
description: 'Add a button node to a Divi page',
|
|
84
|
+
template: `Create a button node in structured format with:
|
|
53
85
|
- button_text: The button label
|
|
54
86
|
- button_url: The link URL
|
|
55
87
|
- button_alignment: left, center, or right
|
|
56
88
|
- button_bg_color: Background color (hex format)
|
|
57
89
|
- button_text_color: Text color (hex format)
|
|
58
90
|
|
|
59
|
-
Example:
|
|
60
|
-
|
|
61
|
-
[/et_pb_button]`,
|
|
91
|
+
Example node:
|
|
92
|
+
{ type: "divi/button", attributes: { button_text: "Click Here", button_url: "https://example.com", button_alignment: "center", button_bg_color: "#0000FF", button_text_color: "#FFFFFF" }, content: "" }`,
|
|
62
93
|
},
|
|
63
94
|
updateImage: {
|
|
64
95
|
name: 'update_divi_image',
|
|
65
96
|
description: 'Update an image in a Divi image module',
|
|
66
|
-
template: `Find the et_pb_image
|
|
97
|
+
template: `Find the image node (Divi 5: divi/image, Divi 4: et_pb_image) and modify:
|
|
67
98
|
- src: New image URL
|
|
68
99
|
- alt: Image alt text (for accessibility)
|
|
69
100
|
- url: Optional link URL if image should be clickable
|
|
70
101
|
- align: left, center, or right
|
|
71
|
-
|
|
72
|
-
Example:
|
|
73
|
-
[et_pb_image src="https://example.com/new-image.jpg" alt="Description" align="center"]
|
|
74
|
-
[/et_pb_image]`,
|
|
102
|
+
`,
|
|
75
103
|
},
|
|
76
104
|
changeColors: {
|
|
77
105
|
name: 'change_divi_colors',
|
package/dist/divi-prompts.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"divi-prompts.js","sourceRoot":"","sources":["../src/divi-prompts.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH,MAAM,CAAC,MAAM,WAAW,GAA+B;IACrD,iBAAiB,EAAE;QACjB,IAAI,EAAE,kBAAkB;QACxB,WAAW,EAAE,
|
|
1
|
+
{"version":3,"file":"divi-prompts.js","sourceRoot":"","sources":["../src/divi-prompts.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH,MAAM,CAAC,MAAM,gBAAgB,GAAG;;;;CAI/B,CAAC;AAEF,MAAM,CAAC,MAAM,8BAA8B,GACzC,4GAA4G,CAAC;AAE/G,MAAM,CAAC,MAAM,2BAA2B,GAAG;IACzC;QACE,EAAE,EAAE,iBAAiB;QACrB,KAAK,EAAE,2BAA2B;QAClC,MAAM,EAAE,wOAAwO;KACjP;IACD;QACE,EAAE,EAAE,qBAAqB;QACzB,KAAK,EAAE,uBAAuB;QAC9B,MAAM,EAAE,2MAA2M;KACpN;IACD;QACE,EAAE,EAAE,uBAAuB;QAC3B,KAAK,EAAE,4BAA4B;QACnC,MAAM,EAAE,gNAAgN;KACzN;IACD;QACE,EAAE,EAAE,mBAAmB;QACvB,KAAK,EAAE,mBAAmB;QAC1B,MAAM,EAAE,yMAAyM;KAClN;IACD;QACE,EAAE,EAAE,kBAAkB;QACtB,KAAK,EAAE,uBAAuB;QAC9B,MAAM,EAAE,8OAA8O;KACvP;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,WAAW,GAA+B;IACrD,iBAAiB,EAAE;QACjB,IAAI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ACjD,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,IAAI,MAAM,CAAC,MAAM,GAAG,KAAK,EAAE,GAAG,CAAC,EAAE,KAAK,CAAC,CAAC;IACtE,CAAC,CAAC,CAAC;IAEH,OAAO,QAAQ,CAAC;AAClB,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -3,6 +3,11 @@
|
|
|
3
3
|
* Respira WordPress MCP Server
|
|
4
4
|
* Entry point
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* Handle EPIPE (broken pipe) gracefully when the client disconnects.
|
|
8
|
+
* The MCP SDK writes to stdout; when Cursor/Claude/etc closes, writes throw EPIPE.
|
|
9
|
+
*/
|
|
10
|
+
declare function setupEpipeHandler(): void;
|
|
6
11
|
declare const args: string[];
|
|
7
12
|
declare const isSetupCommand: boolean;
|
|
8
13
|
declare const isStdioCommand: boolean;
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA;;;GAGG;AAEH;;;GAGG;AACH,iBAAS,iBAAiB,IAAI,IAAI,CAQjC;AAGD,QAAA,MAAM,IAAI,UAAwB,CAAC;AACnC,QAAA,MAAM,cAAc,SAQC,CAAC;AACtB,QAAA,MAAM,cAAc,SAA2B,CAAC;AAkBhD,iBAAe,cAAc,kBAoB5B;AAED,iBAAe,cAAc,kBAmD5B"}
|
package/dist/index.js
CHANGED
|
@@ -4,6 +4,19 @@
|
|
|
4
4
|
* Respira WordPress MCP Server
|
|
5
5
|
* Entry point
|
|
6
6
|
*/
|
|
7
|
+
/**
|
|
8
|
+
* Handle EPIPE (broken pipe) gracefully when the client disconnects.
|
|
9
|
+
* The MCP SDK writes to stdout; when Cursor/Claude/etc closes, writes throw EPIPE.
|
|
10
|
+
*/
|
|
11
|
+
function setupEpipeHandler() {
|
|
12
|
+
process.on('uncaughtException', (err) => {
|
|
13
|
+
if (err.code === 'EPIPE' || (err.message && err.message.includes('EPIPE'))) {
|
|
14
|
+
process.exit(0);
|
|
15
|
+
}
|
|
16
|
+
console.error('Uncaught exception:', err);
|
|
17
|
+
process.exit(1);
|
|
18
|
+
});
|
|
19
|
+
}
|
|
7
20
|
// Handle CLI flags before starting MCP server
|
|
8
21
|
const args = process.argv.slice(2);
|
|
9
22
|
const isSetupCommand = args.includes('--setup') ||
|
|
@@ -33,6 +46,7 @@ else {
|
|
|
33
46
|
startMcpServer();
|
|
34
47
|
}
|
|
35
48
|
async function startStdioMode() {
|
|
49
|
+
setupEpipeHandler();
|
|
36
50
|
const { parseStdioArgs } = await import('./transports/stdio.js');
|
|
37
51
|
const { RespiraWordPressServer } = await import('./server.js');
|
|
38
52
|
const { loadConfig } = await import('./config.js');
|
|
@@ -68,9 +82,15 @@ async function startMcpServer() {
|
|
|
68
82
|
if (process.env.NODE_ENV === 'development') {
|
|
69
83
|
return null;
|
|
70
84
|
}
|
|
85
|
+
// EPIPE when client disconnects is expected - don't report
|
|
86
|
+
const msg = event.exception?.values?.[0]?.value || '';
|
|
87
|
+
if (msg.includes('EPIPE') || msg.includes('broken pipe')) {
|
|
88
|
+
return null;
|
|
89
|
+
}
|
|
71
90
|
return event;
|
|
72
91
|
},
|
|
73
92
|
});
|
|
93
|
+
setupEpipeHandler();
|
|
74
94
|
try {
|
|
75
95
|
// Load configuration
|
|
76
96
|
const config = loadConfig();
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;AAEA;;;GAGG;AAEH,8CAA8C;AAC9C,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;AACnC,MAAM,cAAc,GAClB,IAAI,CAAC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AAC,CAAC;QAC5C,IAAI,UAAU,EAAE,CAAC;YACf,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC;QAC5B,CAAC;QAED,8BAA8B;QAC9B,MAAM,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;QAE/B,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC"}
|
package/dist/server.d.ts
CHANGED
|
@@ -11,6 +11,8 @@ export declare class RespiraWordPressServer {
|
|
|
11
11
|
constructor(siteConfigs: WordPressSiteConfig[]);
|
|
12
12
|
private setupHandlers;
|
|
13
13
|
private getTools;
|
|
14
|
+
private isWooCommerceAddonAvailable;
|
|
15
|
+
private getWooCommerceTools;
|
|
14
16
|
private handleToolCall;
|
|
15
17
|
run(): Promise<void>;
|
|
16
18
|
}
|
package/dist/server.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAUH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAE5D,qBAAa,sBAAsB;IACjC,OAAO,CAAC,MAAM,CAAS;IACvB,OAAO,CAAC,WAAW,CAAgC;IACnD,OAAO,CAAC,KAAK,CAA2C;gBAE5C,WAAW,EAAE,mBAAmB,EAAE;IA2B9C,OAAO,CAAC,aAAa;
|
|
1
|
+
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAUH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAE5D,qBAAa,sBAAsB;IACjC,OAAO,CAAC,MAAM,CAAS;IACvB,OAAO,CAAC,WAAW,CAAgC;IACnD,OAAO,CAAC,KAAK,CAA2C;gBAE5C,WAAW,EAAE,mBAAmB,EAAE;IA2B9C,OAAO,CAAC,aAAa;YAsGP,QAAQ;YA4jDR,2BAA2B;IAazC,OAAO,CAAC,mBAAmB;YAmJb,cAAc;IA6WtB,GAAG;CAKV"}
|