Skip to main content
Glama
wave-av

WAVE MCP Server

Official
by wave-av

wave_moderate_chat

Moderate chat messages in live streams by blocking, flagging, or allowing them with a reason.

Instructions

Moderate a chat message in a live stream (block, flag, or allow)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
stream_idYesThe stream ID
message_idYesThe chat message ID to moderate
actionYesModeration action
reasonNoReason for moderation action

Implementation Reference

  • The async handler function that executes the moderate_chat logic. It calls waveFetch to POST to /api/v1/streams/{stream_id}/chat/{message_id}/moderate with action and reason.
    async ({ stream_id, message_id, action, reason }) => {
      const res = await waveFetch(
        `/api/v1/streams/${stream_id}/chat/${message_id}/moderate`,
        {
          method: "POST",
          body: JSON.stringify({ action, reason: reason ?? "" }),
        },
      );
      if (!res.ok) return errorContent(res.status, res.body);
      return textContent(res.body);
    },
  • Input schema for wave_moderate_chat: stream_id (uuid), message_id (string), action (enum: block/flag/allow), reason (optional string max 500 chars).
    {
      stream_id: z.string().uuid().describe("The stream ID"),
      message_id: z.string().describe("The chat message ID to moderate"),
      action: z.enum(["block", "flag", "allow"]).describe("Moderation action"),
      reason: z.string().max(500).optional().describe("Reason for moderation action"),
    },
  • The server.tool() call that registers 'wave_moderate_chat' with its description, schema, and handler.
    server.tool(
      "wave_moderate_chat",
      "Moderate a chat message in a live stream (block, flag, or allow)",
      {
        stream_id: z.string().uuid().describe("The stream ID"),
        message_id: z.string().describe("The chat message ID to moderate"),
        action: z.enum(["block", "flag", "allow"]).describe("Moderation action"),
        reason: z.string().max(500).optional().describe("Reason for moderation action"),
      },
      async ({ stream_id, message_id, action, reason }) => {
        const res = await waveFetch(
          `/api/v1/streams/${stream_id}/chat/${message_id}/moderate`,
          {
            method: "POST",
            body: JSON.stringify({ action, reason: reason ?? "" }),
          },
        );
        if (!res.ok) return errorContent(res.status, res.body);
        return textContent(res.body);
      },
    );
  • src/server.ts:24-24 (registration)
    Where registerProductionTools(server) is called to register the tool on the MCP server.
    registerProductionTools(server);
  • The waveFetch helper function used by the handler to make authenticated HTTP requests to the WAVE API.
    async function waveFetch(
      path: string,
      init?: RequestInit,
    ): Promise<{ ok: boolean; status: number; body: string }> {
      const url = `${getBaseUrl()}${path}`;
      const res = await fetch(url, {
        ...init,
        headers: {
          ...getAuthHeaders(),
          ...init?.headers,
        },
      });
      const body = await res.text();
      return { ok: res.ok, status: res.status, body };
    }
Behavior2/5

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

The description does not disclose behavioral traits beyond the basic action. For a moderation tool, critical information is missing: whether the action is reversible, if it notifies the user, permission requirements, or the effect on the chat. With no annotations provided, the description should cover these aspects, but it does not.

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

Conciseness4/5

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

The description is a single sentence that is front-loaded with the main action. It avoids unnecessary words. However, it could be slightly expanded to include usage notes without significant bloat.

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

Completeness2/5

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

The description does not mention the return value or success/failure behavior. For a tool with 4 parameters and no output schema, more context is needed, such as whether the message is returned or if the action is immediate. The current description is insufficient for an AI agent to fully understand the tool's effect.

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% parameter description coverage, so each parameter's meaning is already clear from the schema. The description adds no additional semantics beyond what the schema provides. Baseline score of 3 is appropriate.

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 tool's function: moderate a chat message with specific actions (block, flag, allow). This distinguishes it from sibling tools like wave_start_stream or wave_control_camera, which are about streaming operations.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus alternatives. There is no mention of prerequisites, such as needing the stream to be active, or when to choose one action over another. The description simply states the action without context.

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/wave-av/mcp-server'

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