@wplaunchify/ml-mcp-server 2.1.1 → 2.1.3

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.
@@ -277,8 +277,8 @@ export const fluentCommunityCoreTools = [
277
277
  // Spaces (4)
278
278
  { name: 'fc_list_spaces', description: 'List all spaces in FluentCommunity', inputSchema: { type: 'object', properties: listSpacesSchema.shape } },
279
279
  { name: 'fc_get_space', description: 'Get detailed information about a specific space', inputSchema: { type: 'object', properties: getSpaceSchema.shape } },
280
- { name: 'fc_create_space', description: 'Create a new space in FluentCommunity', inputSchema: { type: 'object', properties: createSpaceSchema.shape } },
281
- { name: 'fc_update_space', description: 'Update an existing space', inputSchema: { type: 'object', properties: updateSpaceSchema.shape } },
280
+ { name: 'fc_create_space', description: 'Create a new space in FluentCommunity. IMPORTANT: For logo/cover_photo, you MUST first use fc_sideload_media to upload the image - regular URLs will be silently ignored!', inputSchema: { type: 'object', properties: createSpaceSchema.shape } },
281
+ { name: 'fc_update_space', description: 'Update an existing space. IMPORTANT: For logo/cover_photo, you MUST first use fc_sideload_media to upload the image - regular URLs will be silently ignored!', inputSchema: { type: 'object', properties: updateSpaceSchema.shape } },
282
282
  // Comments (4)
283
283
  { name: 'fc_list_comments', description: 'List FluentCommunity comments', inputSchema: { type: 'object', properties: listCommentsSchema.shape } },
284
284
  { name: 'fc_create_comment', description: 'Create a new comment on a post', inputSchema: { type: 'object', properties: createCommentSchema.shape } },
@@ -341,6 +341,23 @@ export declare const fluentCommunityLearningHandlers: {
341
341
  }[];
342
342
  };
343
343
  }>;
344
+ fc_sideload_media: (args: any) => Promise<{
345
+ toolResult: {
346
+ content: {
347
+ type: string;
348
+ text: string;
349
+ }[];
350
+ isError?: undefined;
351
+ };
352
+ } | {
353
+ toolResult: {
354
+ isError: boolean;
355
+ content: {
356
+ type: string;
357
+ text: string;
358
+ }[];
359
+ };
360
+ }>;
344
361
  fc_search_giphy: (args: any) => Promise<{
345
362
  toolResult: {
346
363
  content: {
@@ -136,6 +136,10 @@ const uploadMediaSchema = z.object({
136
136
  file_url: z.string().describe('URL of file to upload'),
137
137
  file_name: z.string().optional().describe('File name')
138
138
  });
139
+ const sideloadMediaSchema = z.object({
140
+ url: z.string().describe('URL of image to download and upload to FluentCommunity. Use this to set space logo/cover_photo - FluentCommunity only accepts images from its own media system.'),
141
+ context: z.string().optional().default('space').describe('Context for the media (space, profile, post). Default: space')
142
+ });
139
143
  // Giphy
140
144
  const searchGiphySchema = z.object({
141
145
  query: z.string().describe('Search query for GIFs'),
@@ -187,9 +191,10 @@ export const fluentCommunityLearningTools = [
187
191
  { name: 'fc_create_quiz', description: 'Create a new quiz in a course', inputSchema: { type: 'object', properties: createQuizSchema.shape } },
188
192
  { name: 'fc_update_quiz', description: 'Update an existing quiz', inputSchema: { type: 'object', properties: updateQuizSchema.shape } },
189
193
  { name: 'fc_delete_quiz', description: 'Delete a quiz', inputSchema: { type: 'object', properties: deleteQuizSchema.shape } },
190
- // Media (2)
194
+ // Media (3)
191
195
  { name: 'fc_list_media', description: 'List media items', inputSchema: { type: 'object', properties: listMediaSchema.shape } },
192
196
  { name: 'fc_upload_media', description: 'Upload media file', inputSchema: { type: 'object', properties: uploadMediaSchema.shape } },
197
+ { name: 'fc_sideload_media', description: 'Download image from any URL and upload to FluentCommunity media system. REQUIRED for setting space logo/cover_photo - FluentCommunity only accepts images from its own media table. Returns URL that works with fc_update_space.', inputSchema: { type: 'object', properties: sideloadMediaSchema.shape } },
193
198
  // Giphy (1)
194
199
  { name: 'fc_search_giphy', description: 'Search Giphy for GIFs', inputSchema: { type: 'object', properties: searchGiphySchema.shape } },
195
200
  // Webhooks (3)
@@ -424,6 +429,15 @@ export const fluentCommunityLearningHandlers = {
424
429
  return { toolResult: { isError: true, content: [{ type: 'text', text: `Error: ${error.message}` }] } };
425
430
  }
426
431
  },
432
+ fc_sideload_media: async (args) => {
433
+ try {
434
+ const response = await makeWordPressRequest('POST', 'fc-manager/v1/media/sideload', args);
435
+ return { toolResult: { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] } };
436
+ }
437
+ catch (error) {
438
+ return { toolResult: { isError: true, content: [{ type: 'text', text: `Error: ${error.message}` }] } };
439
+ }
440
+ },
427
441
  // Giphy
428
442
  fc_search_giphy: async (args) => {
429
443
  try {
@@ -1007,6 +1007,23 @@ export declare const fluentCommunityHandlers: {
1007
1007
  }[];
1008
1008
  };
1009
1009
  }>;
1010
+ fc_sideload_media: (args: any) => Promise<{
1011
+ toolResult: {
1012
+ content: {
1013
+ type: string;
1014
+ text: string;
1015
+ }[];
1016
+ isError?: undefined;
1017
+ };
1018
+ } | {
1019
+ toolResult: {
1020
+ isError: boolean;
1021
+ content: {
1022
+ type: string;
1023
+ text: string;
1024
+ }[];
1025
+ };
1026
+ }>;
1010
1027
  fc_search_giphy: (args: any) => Promise<{
1011
1028
  toolResult: {
1012
1029
  content: {
@@ -347,6 +347,10 @@ const uploadMediaSchema = z.object({
347
347
  file_url: z.string().describe('URL of file to upload'),
348
348
  file_name: z.string().optional().describe('File name')
349
349
  });
350
+ const sideloadMediaSchema = z.object({
351
+ url: z.string().describe('URL of image to download and upload to FluentCommunity. Use this to set space logo/cover_photo - FluentCommunity only accepts images from its own media system.'),
352
+ context: z.string().optional().default('space').describe('Context for the media (space, profile, post). Default: space')
353
+ });
350
354
  // Giphy Schema
351
355
  const searchGiphySchema = z.object({
352
356
  query: z.string().describe('Search query for GIFs'),
@@ -473,12 +477,12 @@ export const fluentCommunityTools = [
473
477
  },
474
478
  {
475
479
  name: 'fc_create_space',
476
- description: 'Create a new space in FluentCommunity',
480
+ description: 'Create a new space in FluentCommunity. IMPORTANT: For logo/cover_photo, you MUST first use fc_sideload_media to upload the image - regular URLs will be silently ignored!',
477
481
  inputSchema: { type: 'object', properties: createSpaceSchema.shape }
478
482
  },
479
483
  {
480
484
  name: 'fc_update_space',
481
- description: 'Update an existing FluentCommunity space',
485
+ description: 'Update an existing FluentCommunity space. IMPORTANT: For logo/cover_photo, you MUST first use fc_sideload_media to upload the image - regular URLs will be silently ignored!',
482
486
  inputSchema: { type: 'object', properties: updateSpaceSchema.shape }
483
487
  },
484
488
  // ==================== COMMENTS TOOLS ====================
@@ -746,6 +750,11 @@ export const fluentCommunityTools = [
746
750
  description: 'Upload media file',
747
751
  inputSchema: { type: 'object', properties: uploadMediaSchema.shape }
748
752
  },
753
+ {
754
+ name: 'fc_sideload_media',
755
+ description: 'Download image from any URL and upload to FluentCommunity media system. REQUIRED for setting space logo/cover_photo - FluentCommunity only accepts images from its own media table. Returns URL that works with fc_update_space.',
756
+ inputSchema: { type: 'object', properties: sideloadMediaSchema.shape }
757
+ },
749
758
  // ==================== GIPHY ====================
750
759
  {
751
760
  name: 'fc_search_giphy',
@@ -1563,6 +1572,15 @@ export const fluentCommunityHandlers = {
1563
1572
  return { toolResult: { isError: true, content: [{ type: 'text', text: `Error: ${error.message}` }] } };
1564
1573
  }
1565
1574
  },
1575
+ fc_sideload_media: async (args) => {
1576
+ try {
1577
+ const response = await makeWordPressRequest('POST', 'fc-manager/v1/media/sideload', args);
1578
+ return { toolResult: { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] } };
1579
+ }
1580
+ catch (error) {
1581
+ return { toolResult: { isError: true, content: [{ type: 'text', text: `Error: ${error.message}` }] } };
1582
+ }
1583
+ },
1566
1584
  // ==================== GIPHY HANDLERS ====================
1567
1585
  fc_search_giphy: async (args) => {
1568
1586
  try {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wplaunchify/ml-mcp-server",
3
- "version": "2.1.1",
3
+ "version": "2.1.3",
4
4
  "description": "Universal MCP Server for WordPress + Fluent Suite (Community, CRM, Cart) + MinuteLaunch Plugins. Comprehensive tools for AI-powered WordPress management via Claude, Cursor, and other MCP clients.",
5
5
  "type": "module",
6
6
  "main": "./build/server.js",