@wplaunchify/ml-mcp-server 1.0.1 → 1.0.2

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.
@@ -2,21 +2,13 @@ import { z } from 'zod';
2
2
  import { makeWordPressRequest } from '../wordpress.js';
3
3
  // ==================== ZOD SCHEMA DEFINITIONS ====================
4
4
  const getColorsSchema = z.object({
5
- mode: z.enum(['light', 'dark']).optional().default('light').describe('Color mode (light or dark)')
5
+ // No parameters needed - returns full color config
6
6
  });
7
7
  const updateColorsSchema = z.object({
8
- mode: z.enum(['light', 'dark']).optional().default('light').describe('Color mode (light or dark)'),
9
- colors: z.object({
10
- navbar_bg: z.string().optional().describe('Navbar background color (hex)'),
11
- navbar_text: z.string().optional().describe('Navbar text color (hex)'),
12
- sidebar_bg: z.string().optional().describe('Sidebar background color (hex)'),
13
- sidebar_text: z.string().optional().describe('Sidebar text color (hex)'),
14
- feed_bg: z.string().optional().describe('Feed background color (hex)'),
15
- button_primary: z.string().optional().describe('Primary button color (hex)'),
16
- button_secondary: z.string().optional().describe('Secondary button color (hex)'),
17
- link_color: z.string().optional().describe('Link color (hex)'),
18
- accent_color: z.string().optional().describe('Accent color (hex)')
19
- }).describe('Color values to update')
8
+ light_schema: z.enum(['default', 'ocean_blue', 'sky_blue', 'emerald_essence', 'sunset_sands', 'custom']).optional().describe('Light mode color schema preset'),
9
+ dark_schema: z.enum(['default', 'ocean_blue', 'sky_blue', 'emerald_essence', 'sunset_sands', 'custom']).optional().describe('Dark mode color schema preset'),
10
+ light_config: z.record(z.string()).optional().describe('Custom light mode colors (only used when light_schema is "custom")'),
11
+ dark_config: z.record(z.string()).optional().describe('Custom dark mode colors (only used when dark_schema is "custom")')
20
12
  });
21
13
  const updatePortalSettingsSchema = z.object({
22
14
  settings: z.object({
@@ -51,7 +43,7 @@ export const fluentCommunityDesignTools = [
51
43
  },
52
44
  {
53
45
  name: 'fc_update_colors',
54
- description: 'Update FluentCommunity color scheme for light or dark mode',
46
+ description: 'Update FluentCommunity color scheme. Use light_schema/dark_schema to select preset (default, ocean_blue, sky_blue, emerald_essence, sunset_sands, custom). Use light_config/dark_config to set custom colors when schema is "custom".',
55
47
  inputSchema: { type: 'object', properties: updateColorsSchema.shape }
56
48
  },
57
49
  {
@@ -90,10 +82,16 @@ export const fluentCommunityDesignHandlers = {
90
82
  fc_update_colors: async (args) => {
91
83
  try {
92
84
  // Use FluentCommunity's NATIVE color-config endpoint
93
- const data = {
94
- mode: args.mode || 'light',
95
- colors: args.colors
96
- };
85
+ // Pass light_schema, dark_schema, light_config, dark_config directly
86
+ const data = {};
87
+ if (args.light_schema)
88
+ data.light_schema = args.light_schema;
89
+ if (args.dark_schema)
90
+ data.dark_schema = args.dark_schema;
91
+ if (args.light_config)
92
+ data.light_config = args.light_config;
93
+ if (args.dark_config)
94
+ data.dark_config = args.dark_config;
97
95
  const response = await makeWordPressRequest('POST', 'fluent-community/v2/settings/color-config', data);
98
96
  return { toolResult: { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] } };
99
97
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wplaunchify/ml-mcp-server",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "Universal MCP Server for WordPress + Fluent Suite (Community, CRM, Cart) + MinuteLaunch Plugins. 146 tools for AI-powered WordPress management via Claude, Cursor, and other MCP clients.",
5
5
  "type": "module",
6
6
  "main": "./build/server.js",