Skip to main content
Glama

list_algorithms

Discover available algorithms for media protection, watermarking, and AI content disruption. Filter by category or media type to identify valid algorithm IDs before execution.

Instructions

List available algorithms for media protection, watermarking, and AI content disruption. Returns algorithm IDs, names, supported media types, and descriptions. Use this to discover valid algorithm IDs before calling run_algorithm. Filter by category (open = research algorithms, proprietary = Sidearm bundles) or media_type (image, video, audio, text, pdf, gif).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
categoryNoFilter by algorithm category
media_typeNoFilter by supported media type

Implementation Reference

  • The handler function that executes the list_algorithms tool logic. It calls the API endpoint '/api/v1/algorithms' with optional category and media_type filters, then returns the JSON result or handles errors gracefully.
    async ({ category, media_type }) => {
      try {
        const result = await api.get("/api/v1/algorithms", {
          category,
          media_type,
        });
        return {
          content: [
            { type: "text" as const, text: JSON.stringify(result, null, 2) },
          ],
        };
      } catch (err) {
        return {
          content: [
            {
              type: "text" as const,
              text: `Error: ${err instanceof Error ? err.message : String(err)}`,
            },
          ],
          isError: true as const,
        };
      }
    },
  • The input schema definition for list_algorithms using Zod. Defines two optional parameters: 'category' (enum: 'open' or 'proprietary') and 'media_type' (enum: 'image', 'video', 'audio', 'text', 'pdf', 'gif').
    {
      category: z
        .enum(["open", "proprietary"])
        .optional()
        .describe("Filter by algorithm category"),
      media_type: z
        .enum(["image", "video", "audio", "text", "pdf", "gif"])
        .optional()
        .describe("Filter by supported media type"),
    },
  • The registration function that registers the list_algorithms tool with the MCP server. Includes the tool name, description, schema, and handler function.
    export function register(server: McpServer, api: ApiClient): void {
      server.tool(
        "list_algorithms",
        "List available algorithms for media protection, watermarking, and AI content disruption. " +
          "Returns algorithm IDs, names, supported media types, and descriptions. " +
          "Use this to discover valid algorithm IDs before calling run_algorithm. " +
          "Filter by category (open = research algorithms, proprietary = Sidearm bundles) " +
          "or media_type (image, video, audio, text, pdf, gif).",
        {
          category: z
            .enum(["open", "proprietary"])
            .optional()
            .describe("Filter by algorithm category"),
          media_type: z
            .enum(["image", "video", "audio", "text", "pdf", "gif"])
            .optional()
            .describe("Filter by supported media type"),
        },
        async ({ category, media_type }) => {
          try {
            const result = await api.get("/api/v1/algorithms", {
              category,
              media_type,
            });
            return {
              content: [
                { type: "text" as const, text: JSON.stringify(result, null, 2) },
              ],
            };
          } catch (err) {
            return {
              content: [
                {
                  type: "text" as const,
                  text: `Error: ${err instanceof Error ? err.message : String(err)}`,
                },
              ],
              isError: true as const,
            };
          }
        },
      );
  • src/index.ts:6-6 (registration)
    Import of the list_algorithms register function from the tools module.
    import { register as listAlgorithms } from "./tools/list-algorithms.js";
  • src/index.ts:40-40 (registration)
    Invocation of listAlgorithms to register the tool with the MCP server instance.
    listAlgorithms(server, api);
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively describes the tool's behavior: it returns algorithm IDs, names, supported media types, and descriptions, and supports filtering by category and media_type. However, it lacks details on response format (e.g., pagination, error handling) or performance aspects (e.g., rate limits), which are minor gaps given the tool's simple read-only nature.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the core purpose, followed by usage guidance and filtering details. Every sentence earns its place: the first states what it does and returns, the second provides usage context, and the third explains filtering options. It is appropriately sized with zero waste, making it easy for an agent to parse quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (simple read-only list with filtering), no annotations, and no output schema, the description is largely complete. It covers purpose, usage, parameters, and return data. However, without an output schema, it could benefit from more detail on the structure of returned algorithm information (e.g., fields like 'id', 'name'), but the mention of specific data points (IDs, names, etc.) mitigates this gap adequately.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, with both parameters well-documented via enums and descriptions. The description adds value by explaining the semantics of 'category' (open = research algorithms, proprietary = Sidearm bundles) and 'media_type' options, but this is largely redundant with the schema. Baseline 3 is appropriate as the schema does the heavy lifting, and the description provides only marginal additional context.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific verb ('List') and resource ('available algorithms for media protection, watermarking, and AI content disruption'), and distinguishes it from sibling tools by mentioning its role in discovering algorithm IDs before calling 'run_algorithm'. It explicitly differentiates from other tools like 'run_algorithm', 'protect_media', or 'list_media' by focusing on algorithm discovery rather than execution or media listing.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit guidance on when to use this tool ('Use this to discover valid algorithm IDs before calling run_algorithm') and includes filtering options (category and media_type) to refine results. It clearly positions this as a prerequisite step for 'run_algorithm', offering clear alternatives for different needs (e.g., use other tools for media operations).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other 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/sidearmDRM/mcp-server'

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