Skip to main content
Glama
LumabyteCo

Clarifyprompt-MCP

list_categories

Discover available prompt optimization categories with platform counts to select the right format for AI platforms like Midjourney, DALL-E, and ChatGPT.

Instructions

List all available prompt optimization categories with platform counts including custom platforms

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The 'list_categories' tool handler that executes the tool logic. It retrieves the platform registry, maps over CATEGORIES to build category info with platform counts (total, builtin, custom), and returns JSON formatted output.
    server.tool(
      "list_categories",
      "List all available prompt optimization categories with platform counts including custom platforms",
      {},
      async () => {
        const registry = getPlatformRegistry();
        const cats = await Promise.all(CATEGORIES.map(async c => {
          const allPlatforms = await registry.getPlatformsForCategory(c.id);
          return {
            id: c.id,
            label: c.label,
            description: c.description,
            has_platforms: c.hasPlatforms,
            platform_count: allPlatforms.length,
            builtin_count: c.platforms?.length ?? 0,
            custom_count: allPlatforms.filter(p => p.isCustom).length,
            default_platform: c.defaultPlatform ?? null,
            default_mode: c.defaultMode,
          };
        }));
        return { content: [{ type: "text" as const, text: JSON.stringify(cats, null, 2) }] };
      }
    );
  • Empty input schema `{}` for list_categories tool, indicating no parameters required.
    {},
  • PlatformRegistry.getPlatformsForCategory method used by the handler to fetch both built-in and custom platforms for each category.
    async getPlatformsForCategory(categoryId: Category): Promise<PlatformConfig[]> {
      await this.store.ensureLoaded();
      const builtIn = getBuiltInPlatforms(categoryId);
      const custom = this.store.getCustomPlatforms(categoryId).map(entry => ({
        id: entry.id,
        label: entry.label,
        description: entry.description,
        syntaxHints: entry.syntaxHints,
        instructions: entry.instructions,
        instructionsFile: entry.instructionsFile,
        isCustom: true as const,
      }));
      return [...builtIn, ...custom];
    }
  • CategoryConfig interface defining the structure of category data returned by list_categories, including id, label, description, platforms, defaultPlatform, defaultMode, and hasPlatforms.
    export interface CategoryConfig {
      id: Category;
      label: string;
      description: string;
      platforms?: PlatformConfig[];
      defaultPlatform?: string;
      defaultMode: Mode;
      hasPlatforms: boolean;
    }
  • CATEGORIES constant - the source data array containing all 7 category definitions (chat, image, voice, video, music, code, document) that the handler iterates over.
    export const CATEGORIES: CategoryConfig[] = [
      { id: 'chat', label: 'Chat', description: 'General conversation & Q&A', platforms: CHAT_PLATFORMS, defaultPlatform: 'claude', defaultMode: 'detailed', hasPlatforms: true },
      { id: 'image', label: 'Image', description: 'Image generation', platforms: IMAGE_PLATFORMS, defaultPlatform: 'midjourney', defaultMode: 'detailed', hasPlatforms: true },
      { id: 'voice', label: 'Voice', description: 'Voice & speech synthesis', platforms: VOICE_PLATFORMS, defaultPlatform: 'elevenlabs', defaultMode: 'detailed', hasPlatforms: true },
      { id: 'video', label: 'Video', description: 'Video generation', platforms: VIDEO_PLATFORMS, defaultPlatform: 'runway', defaultMode: 'detailed', hasPlatforms: true },
      { id: 'music', label: 'Music', description: 'Music generation', platforms: MUSIC_PLATFORMS, defaultPlatform: 'suno', defaultMode: 'detailed', hasPlatforms: true },
      { id: 'code', label: 'Code', description: 'Programming & development', platforms: CODE_PLATFORMS, defaultPlatform: 'claude', defaultMode: 'detailed', hasPlatforms: true },
      { id: 'document', label: 'Document', description: 'Writing & documents', platforms: DOCUMENT_PLATFORMS, defaultPlatform: 'claude', defaultMode: 'detailed', hasPlatforms: true },
    ];

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/LumabyteCo/clarifyprompt-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server