Skip to main content
Glama

list_models

Retrieve available image, video, and audio generation models with their type and pricing information for selection.

Instructions

List all available models for image, video, and audio generation with their type and pricing

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handleListModels function retrieves models by type and returns a formatted text output listing image, video, and audio models.
    export function handleListModels() {
      const imageModels = getModelsByType("image");
      const videoModels = getModelsByType("video");
      const audioModels = getModelsByType("audio");
    
      const formatModel = (m: (typeof models)[0]) => {
        let line = `  ${m.id} — ${m.name} [${m.free ? "FREE" : "PAID"}]`;
        if (m.price) line += ` (${m.price})`;
        if (m.description) line += ` — ${m.description}`;
        return line;
      };
    
      const text = [
        `IMAGE MODELS (${imageModels.length}):`,
        ...imageModels.map(formatModel),
        "",
        `VIDEO MODELS (${videoModels.length}):`,
        ...videoModels.map(formatModel),
        "",
        `AUDIO MODELS (${audioModels.length}):`,
        ...audioModels.map(formatModel),
      ].join("\n");
    
      return { content: [{ type: "text" as const, text }] };
    }
  • The listModelsSchema definition for the list_models tool.
    export const listModelsSchema = z.object({});

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/doctorm333/promptpilot-mcp-server'

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