Skip to main content
Glama
Cicatriiz

Civitai MCP Server

search_models_by_creator

Discover AI models created by a specific user on Civitai. Filter results by username, limit the number of models, and sort by highest rated, most downloaded, or newest for targeted searches.

Instructions

Search for models by a specific creator

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoNumber of models to return (default: 20)
sortNoSort order for results
usernameYesCreator username to search for

Implementation Reference

  • MCP tool handler that executes the search_models_by_creator tool: calls client method, formats results into markdown text response.
    private async searchModelsByCreator(args: any) {
      const response = await this.client.searchModelsByCreator(args.username, args);
      const formatted = this.formatModelsResponse(response);
      
      return {
        content: [
          {
            type: 'text',
            text: `# Models by ${args.username}\\n\\n${formatted.models.map((model: any) => 
              `**${model.name}** (${model.type})\\n` +
              `Downloads: ${model.stats.downloads.toLocaleString()} | Rating: ${model.stats.rating.toFixed(1)}\\n` +
              `Tags: ${model.tags.join(', ')}\\n` +
              `${model.description}\\n\\n`
            ).join('---\\n')}`,
          },
        ],
      };
    }
  • Tool schema definition including input schema with required 'username' and optional limit/sort parameters.
    {
      name: 'search_models_by_creator',
      description: 'Search for models by a specific creator',
      inputSchema: {
        type: 'object',
        properties: {
          username: { type: 'string', description: 'Creator username to search for' },
          limit: { type: 'number', description: 'Number of models to return (default: 20)', minimum: 1, maximum: 100 },
          sort: { 
            type: 'string', 
            enum: ['Highest Rated', 'Most Downloaded', 'Newest'],
            description: 'Sort order for results'
          },
        },
        required: ['username'],
      },
    },
  • src/index.ts:71-72 (registration)
    Tool dispatching/registration in the CallToolRequest handler switch statement.
    case 'search_models_by_creator':
      return await this.searchModelsByCreator(args);
  • Client helper method that calls Civitai API's getModels with 'username' filter parameter.
    async searchModelsByCreator(username: string, options: Partial<ModelsParams> = {}): Promise<ModelsResponse> {
      return this.getModels({ username, ...options });
    }
Install Server

Other Tools

Related Tools

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/Cicatriiz/civitai-mcp-server'

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